JBoss says, principal is null eventhough I pass the environment variables.
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Jayaprakash_A
Posted On:   Wednesday, May 7, 2003 12:41 AM

I am trying to test the security features of JBoss. I have an EJB with security roles and constraints. My ejb-jar file has the following fragment. Echo users EchoBean2 echo In my client code, when I try to create the initial context, it throws a security exception. This is how I create the initial context. env.put( Context.SECURITY_PRINCIPAL, "test" ); env.put( Context.SECURITY_CREDENTIALS, "test" ); InitialContext iniCtx = new InitialContext(env); The exception says,    More>>

I am trying to test the security features of JBoss. I have an EJB with security roles and constraints.



My ejb-jar file has the following fragment.





Echo

users



EchoBean2

echo









In my client code, when I try to create the initial context, it throws a security exception. This is how I create the initial context.



env.put( Context.SECURITY_PRINCIPAL, "test" );

env.put( Context.SECURITY_CREDENTIALS, "test" );



InitialContext iniCtx = new InitialContext(env);



The exception says,




Insufficient method permissions, principal=null, method=echo, interface=REMOTE, requiredRoles=[users, Echo], principalRoles=[]




Does anyone know what's wrong?



Any help would be very much appreciated.

   <<Less
About | Sitemap | Contact