2 Replies Latest reply on Apr 30, 2008 11:23 AM by bshirley

    JAAS custom login module cannot get login Pricipal informati

    bshirley

      I am having problems obtaining the principal/credentials on a custom server-side login module.

      I can use a standard module, and my client is passing the credentials correctly via JNDI/InitialContext. I've

      @Override
       public boolean login() throws LoginException {
      
       userIdentity = SecurityAssociation.getPrincipal();
      
       Boolean success = super.login();
      
       if (debug)
       System.out.printf(this.getClass().getName() + ".login(): principal = " + userIdentity +
       "success = " + success);
      
       //if (userIdentity == null)
       // throw new LoginException("Principal was not found.");
      
       return success;
       }


      http://www.timfanelli.com/item/98 has been mostly useful in me getting this far, but I'm not sure why I can't access the principal/credentials at this point. (and the Sticky JAAS readme post has broken links)