This week's book giveaway is in the JavaScript forum.
We're giving away four copies of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js and have Paul Jensen on-line!
See this thread for details.
Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

LoginContext and Configuration problem  RSS feed

 
Lavanya gop
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
I am using Jdk1.3 and weblogic 6.1
1.I am creating new LoginContext("Test").javax.security.auth.login.LoginContext;
I have a class SecurityConfiguration subclassed from Configuration class.
I have made an entry for SecurityConfiguration line in java.security file as login.configuration.provider=com.webct.platform.framework.security.authentication.SecurityConfiguration
I have jaas.jar in jdk131/jre/lib/ext directory
When I create new LoginContext("Test") from a standalone application, it does work fine, it picks up the Configuration information from SecurityConfiguration file.
But the following error occurs, when I access through a jsp, which calls an ActionServlet, which inturn calls .java files, which
tries to create new LoginContext("Test").
java.lang.SecurityException: unable to instantiate LoginConfiguration
at javax.security.auth.login.Configuration.getConfiguration(Configuration.java:212)
at javax.security.auth.login.LoginContext$1.run(LoginContext.java:166)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.login.LoginContext.init(LoginContext.java:163)
at javax.security.auth.login.LoginContext.<init>(LoginContext.java:223)
at com.webct.platform.framework.security.authentication.AuthenticationLogic.getLoginContext(AuthenticationLogic.
java:41)
Any help is highly appreciated
Thanks in advance
Lavanya
 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You have to edit the security policy file of your web server instance to allow your code to access the needed APIs.
If your web server is an intranet, you might as well skip the complex configuration process and grant all to any class.
Cheers
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!