Class SecurityHandlerFactory

  • All Implemented Interfaces:
    com.consol.citrus.common.InitializingPhase, org.springframework.beans.factory.FactoryBean<org.eclipse.jetty.security.SecurityHandler>

    public class SecurityHandlerFactory
    extends Object
    implements org.springframework.beans.factory.FactoryBean<org.eclipse.jetty.security.SecurityHandler>, com.consol.citrus.common.InitializingPhase
    Factory bean constructs a security handler for usage in Jetty servlet container. Security handler holds one to many constraints and a set of users known to a user login service for authentication.
    Since:
    1.3
    Author:
    Christoph Deppisch
    • Constructor Detail

      • SecurityHandlerFactory

        public SecurityHandlerFactory()
    • Method Detail

      • getObject

        public org.eclipse.jetty.security.SecurityHandler getObject()
                                                             throws Exception
        Construct new security handler for basic authentication.
        Specified by:
        getObject in interface org.springframework.beans.factory.FactoryBean<org.eclipse.jetty.security.SecurityHandler>
        Throws:
        Exception
      • initialize

        public void initialize()
        Specified by:
        initialize in interface com.consol.citrus.common.InitializingPhase
      • getObjectType

        public Class<?> getObjectType()
        Specified by:
        getObjectType in interface org.springframework.beans.factory.FactoryBean<org.eclipse.jetty.security.SecurityHandler>
      • isSingleton

        public boolean isSingleton()
        Specified by:
        isSingleton in interface org.springframework.beans.factory.FactoryBean<org.eclipse.jetty.security.SecurityHandler>
      • getUsers

        public List<User> getUsers()
        Gets the users.
        Returns:
        the users the users to get.
      • setUsers

        public void setUsers​(List<User> users)
        Sets the users.
        Parameters:
        users - the users to set
      • getRealm

        public String getRealm()
        Gets the realm.
        Returns:
        the realm the realm to get.
      • setRealm

        public void setRealm​(String realm)
        Sets the realm.
        Parameters:
        realm - the realm to set
      • getConstraints

        public Map<String,​org.eclipse.jetty.util.security.Constraint> getConstraints()
        Gets the constraints.
        Returns:
        the constraints the constraints to get.
      • setConstraints

        public void setConstraints​(Map<String,​org.eclipse.jetty.util.security.Constraint> constraints)
        Sets the constraints.
        Parameters:
        constraints - the constraints to set
      • getLoginService

        public org.eclipse.jetty.security.LoginService getLoginService()
        Gets the loginService.
        Returns:
        the loginService the loginService to get.
      • setLoginService

        public void setLoginService​(org.eclipse.jetty.security.LoginService loginService)
        Sets the loginService.
        Parameters:
        loginService - the loginService to set
      • getAuthenticator

        public org.eclipse.jetty.security.Authenticator getAuthenticator()
        Gets the authenticator.
        Returns:
        the authenticator the authenticator to get.
      • setAuthenticator

        public void setAuthenticator​(org.eclipse.jetty.security.Authenticator authenticator)
        Sets the authenticator.
        Parameters:
        authenticator - the authenticator to set