Class JAASLoginService


  • public class JAASLoginService
    extends LoginService
    JAASLoginService implements a LoginService that uses JAAS for authentication. JAASLoginService uses the server name as name of the configuration for JAAS.
    • Constructor Detail

      • JAASLoginService

        public JAASLoginService​(java.lang.String server)
        Constructor for JAASLoginService
        Parameters:
        server - server name that is also used for the JAAS config name
      • JAASLoginService

        public JAASLoginService()
        Default JavaBeans constructor
    • Method Detail

      • authenticate

        public boolean authenticate​(java.lang.String name,
                                    char[] password,
                                    java.lang.String server)
                             throws java.lang.Exception
        Description copied from class: LoginService
        This method is intended to be implemented by clients wishing to authenticate a user with a given password. Clients should implement the authentication in a manner that the authentication can be cancelled at any time.
        Specified by:
        authenticate in class LoginService
        Parameters:
        name - username
        password - password
        server - server (optional)
        Returns:
        true on authentication success
        Throws:
        java.lang.Exception