Class AttributeMapping.Builder

    • Field Detail

      • ldapName

        private String ldapName
      • searchDn

        private String searchDn
      • recursiveSearch

        private boolean recursiveSearch
      • filter

        private String filter
      • reference

        private String reference
      • roleRecursionDepth

        private int roleRecursionDepth
      • roleRecursionName

        private String roleRecursionName
    • Constructor Detail

      • Builder

        public Builder()
    • Method Detail

      • extractRdn

        public AttributeMapping.Builder extractRdn​(String rdn)
        Set type of RDN, whose value will be used as identity attribute value. Use in case the attribute value is in DN form or when DN of entry is used
        Parameters:
        rdn - the name of type of RDN
        Returns:
        this builder
      • from

        public AttributeMapping.Builder from​(String ldapName)
        Set name of the attribute in LDAP from where the values are obtained.
        Parameters:
        ldapName - the name of the attribute in LDAP from where the values are obtained
        Returns:
        this builder
      • roleRecursionName

        public AttributeMapping.Builder roleRecursionName​(String roleRecursionName)
        Set name of the attribute in LDAP from where are {0} in role recursion obtained. Wildcard {0} is in filter replaced by user name usually. When role recursion is used, roles of roles are searched using the same filter, but {0} is replaced by role name - obtained from role entry attribute specified by this method. If not specified, attribute specified in from(String) is used.
        Parameters:
        roleRecursionName - the name of the attribute in LDAP which will replace {0} in filter while role recursion
        Returns:
        this builder
      • to

        public AttributeMapping.Builder to​(String name)
        Set name of identity attribute to which will be mapping done.
        Parameters:
        name - the name of identity attribute (not LDAP attribute)
        Returns:
        this builder
      • searchDn

        public AttributeMapping.Builder searchDn​(String searchDn)
        Set search DN of LDAP search for attribute entries. If not specified, search DN from identity mapping will be used.
        Parameters:
        searchDn - the name of the context (DN) to be used when executing the filter
        Returns:
        this builder
      • searchRecursively

        public AttributeMapping.Builder searchRecursively​(boolean recursiveSearch)
        Set whether LDAP search for attribute entries should be recursive. Enabled by default.
        Parameters:
        recursiveSearch - whether the LDAP search should be recursive
        Returns:
        this builder
      • roleRecursion

        public AttributeMapping.Builder roleRecursion​(int roleRecursionDepth)
        Set recursive search of filtered attribute (for recursive roles assignment and similar)
        Parameters:
        roleRecursionDepth - maximum depth of recursion, 0 by default (no recursion)
        Returns:
        this builder