Thursday, March 31, 2011

How to setup JAAS (in jaas.conf) to use NTLoginModule?

I guess an example of jaas.conf file that uses the NTLoginModule for authentication would help.

From stackoverflow
  • I am not sure if that is what you mean, but I guess you could have:

    
    SomeName
    {
       com.sun.security.auth.module.NTLoginModule required;
    };
    
    

    and then you can use it:

    
    LoginContext lc = new LoginContext("SomeName", new SomeCallbackHandler());
    lc.login();
    
    

    The java.security.auth.login.config property should point to where the config file is located.

0 comments:

Post a Comment