geronimo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bert_nor <c...@mail.ru>
Subject Openejb: This principle is not authorized
Date Fri, 13 Apr 2007 14:07:32 GMT

Standalone application

login.config:
dw_realm {
    org.apache.geronimo.security.jaas.client.JaasLoginCoordinator required
    host="localhost"
    port="4242"
    realm="dw_realm";
}; 

LoginContext context = new LoginContext("dw_realm",...);
context.login();

Properties props = new Properties(); 
props.put("java.naming.factory.initial",
"org.apache.openejb.client.RemoteInitialContextFactory"); 
props.put("java.naming.factory.host", "127.0.0.1"); 
props.put("java.naming.factory.port", "4201"); 
props.put("java.naming.security.principal", ...); 
props.put("java.naming.security.credentials", ...);

Context remoteContext = remoteContext = new InitialContext(props);

javax.naming.AuthenticationException: This principle is not authorized.
	at org.apache.openejb.client.JNDIContext.authenticate(JNDIContext.java:144)
	at
org.apache.openejb.client.JNDIContext.getInitialContext(JNDIContext.java:116)
	at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:667)
	at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:247)
	at javax.naming.InitialContext.init(InitialContext.java:223)
	at javax.naming.InitialContext.<init>(InitialContext.java:197)

It's exception thrown from 
org.apache.geronimo.openejb.GeronimoSecurityService.login(String user,
String pass) {
  LoginContext context = new LoginContext("OpenEJB", new
UsernamePasswordCallbackHandler(user,
pass));-->javax.security.auth.login.LoginException: No LoginModules
configured for OpenEJB

Can be use realm for the current user?


-- 
View this message in context: http://www.nabble.com/Openejb%3A-This-principle-is-not-authorized-tf3571824s134.html#a9979641
Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.


Mime
View raw message