Class ChainAuthenticationProvider

  • All Implemented Interfaces:
    org.springframework.beans.factory.Aware, org.springframework.beans.factory.InitializingBean, org.springframework.context.ApplicationContextAware, org.springframework.security.authentication.AuthenticationProvider

    public class ChainAuthenticationProvider
    extends Object
    implements org.springframework.security.authentication.AuthenticationProvider, org.springframework.context.ApplicationContextAware, org.springframework.beans.factory.InitializingBean
    Implementation of AuthenticationProvider for Studio's authentication chain. Holds a list of authenticators initialized based on the main configuration.
    Since:
    4.0
    Author:
    joseross
    • Field Detail

      • appContext

        protected org.springframework.context.ApplicationContext appContext
      • providers

        protected List<org.springframework.security.authentication.AuthenticationProvider> providers
    • Method Detail

      • setApplicationContext

        public void setApplicationContext​(org.springframework.context.ApplicationContext applicationContext)
                                   throws org.springframework.beans.BeansException
        Specified by:
        setApplicationContext in interface org.springframework.context.ApplicationContextAware
        Throws:
        org.springframework.beans.BeansException
      • afterPropertiesSet

        public void afterPropertiesSet()
                                throws Exception
        Specified by:
        afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
        Throws:
        Exception
      • initLdapAuthenticationProvider

        protected org.springframework.security.authentication.AuthenticationProvider initLdapAuthenticationProvider​(org.apache.commons.configuration2.HierarchicalConfiguration<?> providerConfig)
      • initHeadersAuthenticationProvider

        protected org.springframework.security.authentication.AuthenticationProvider initHeadersAuthenticationProvider​(org.apache.commons.configuration2.HierarchicalConfiguration<?> providerConfig)
      • authenticate

        public org.springframework.security.core.Authentication authenticate​(org.springframework.security.core.Authentication authentication)
                                                                      throws org.springframework.security.core.AuthenticationException
        Specified by:
        authenticate in interface org.springframework.security.authentication.AuthenticationProvider
        Throws:
        org.springframework.security.core.AuthenticationException
      • supports

        public boolean supports​(Class<?> authentication)
        Specified by:
        supports in interface org.springframework.security.authentication.AuthenticationProvider