Class ConstructDnResolver

  • All Implemented Interfaces:
    DnResolver, java.io.Serializable

    public class ConstructDnResolver
    extends java.lang.Object
    implements DnResolver, java.io.Serializable
    ConstructDnResolver creates an LDAP DN using known information about the LDAP. Specifically it concatenates the first user field with the base DN.
    Version:
    $Revision: 1632 $ $Date: 2010-09-29 00:42:24 +0200 (Wed, 29 Sep 2010) $
    Author:
    Middleware Services
    See Also:
    Serialized Form
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected AuthenticatorConfig config
      Authentication configuration.
      protected org.apache.commons.logging.Log logger
      Log for this class.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void close()
      This will close any resources associated with this resolver.
      AuthenticatorConfig getAuthenticatorConfig()
      This returns the AuthenticatorConfig of the Authenticator.
      java.lang.String resolve​(java.lang.String user)
      Creates a LDAP DN by combining the userField and the base dn.
      void setAuthenticatorConfig​(AuthenticatorConfig authConfig)
      This will set the config parameters of this Authenticator.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • logger

        protected final org.apache.commons.logging.Log logger
        Log for this class.
    • Constructor Detail

      • ConstructDnResolver

        public ConstructDnResolver()
        Default constructor.
      • ConstructDnResolver

        public ConstructDnResolver​(AuthenticatorConfig authConfig)
        This will create a new ConstructDnResolver with the supplied AuthenticatorConfig.
        Parameters:
        authConfig - AuthenticatorConfig
    • Method Detail

      • setAuthenticatorConfig

        public void setAuthenticatorConfig​(AuthenticatorConfig authConfig)
        This will set the config parameters of this Authenticator.
        Specified by:
        setAuthenticatorConfig in interface DnResolver
        Parameters:
        authConfig - AuthenticatorConfig
      • resolve

        public java.lang.String resolve​(java.lang.String user)
                                 throws javax.naming.NamingException
        Creates a LDAP DN by combining the userField and the base dn.
        Specified by:
        resolve in interface DnResolver
        Parameters:
        user - String to find dn for
        Returns:
        String - user's dn
        Throws:
        javax.naming.NamingException - if the LDAP search fails
      • close

        public void close()
        This will close any resources associated with this resolver.
        Specified by:
        close in interface DnResolver