Class UserDetailsServiceLdapAuthoritiesPopulator

  • All Implemented Interfaces:
    LdapAuthoritiesPopulator

    public class UserDetailsServiceLdapAuthoritiesPopulator
    extends java.lang.Object
    implements LdapAuthoritiesPopulator
    Simple LdapAuthoritiesPopulator which delegates to a UserDetailsService, using the name which was supplied at login as the username.
    Since:
    2.0
    • Constructor Detail

      • UserDetailsServiceLdapAuthoritiesPopulator

        public UserDetailsServiceLdapAuthoritiesPopulator​(UserDetailsService userService)
    • Method Detail

      • getGrantedAuthorities

        public java.util.Collection<? extends GrantedAuthority> getGrantedAuthorities​(org.springframework.ldap.core.DirContextOperations userData,
                                                                                      java.lang.String username)
        Description copied from interface: LdapAuthoritiesPopulator
        Get the list of authorities for the user.
        Specified by:
        getGrantedAuthorities in interface LdapAuthoritiesPopulator
        Parameters:
        userData - the context object which was returned by the LDAP authenticator.
        Returns:
        the granted authorities for the given user.