Interface LdapGroupProcessor

  • All Known Implementing Classes:
    DefaultLdapGroupProcessor

    public interface LdapGroupProcessor
    Contract to allow the list of groups returned from LDAP to be transformed and appended to from other sources.
    Since:
    1.0
    Author:
    James Kleeh
    • Method Detail

      • process

        java.util.Set<java.lang.String> process​(java.lang.String attribute,
                                                LdapSearchResult result,
                                                SearchProvider groupResults)
                                         throws javax.naming.NamingException
        Processes groups returned from LDAP.
        Parameters:
        attribute - The group attribute in the context
        result - The search result of the user
        groupResults - The provider responsible for querying LDAP
        Returns:
        The groups to populate in the authentication
        Throws:
        javax.naming.NamingException - If the search provider fails
      • getAdditionalGroups

        default java.util.Set<java.lang.String> getAdditionalGroups​(LdapSearchResult result)
        Provides a way to add additional groups to the ldap group search.
        Parameters:
        result - The ldap search result
        Returns:
        Any additional groups that should be added to the authentication
      • processGroup

        default java.util.Optional<java.lang.String> processGroup​(java.lang.String group)
        Transform the group into the format required.
        Parameters:
        group - The group to process
        Returns:
        An optional modified group