users@glassfish.java.net

Re: Programmatic Login - No Credential Exception

From: Kumar Jayanti <v.b.kumar.jayanti_at_oracle.com>
Date: Thu, 7 Apr 2011 08:11:47 +0530

On 07-Apr-2011, at 1:56 AM, forums_at_java.net wrote:

> Thank you for your answer. I'm using login.conf both in web in standalone
> mode, but I'm including it in my java code as shown below
>
> [php] System.setProperty("java.security.auth.login.config", "login.conf");
> [/php]
> and content of my login.conf file
>
> [php] default { com.sun.enterprise.security.auth.login.LDAPLoginModule
> required; } [/php]
> In my opinion loading login.conf is not the problem in my case. However in my
> standalone application I was able to load only default realm and I have no
> clue why. In web mode everything works perfectly fine.
> If you require more details, please see
> [link]http://www.java.net/forum/topic/glassfish/glassfish/gwt-development-mode-programmatic-login-problem[/link]
> I will greatly appreciate any suggestion that you will come up with. I'm
> looking forward to hearing from you again soon.


Please use the login.conf file that i suggested, that will make sure the credentials are populated in the right place in case of appclient/standalone app. What does the Standalone app do after that, does it invoke an EJB or a WebService ?.


>
>
> --
>
> [Message sent by forum member 'lhanusiak']
>
> View Post: http://forums.java.net/node/789029
>
>