Tag: 亚当

为Ldap连接配置Spring安全性

我必须配置Spring安全性以通过LDAP对用户进行身份validation。 这是经理用户所在的子树: ldaps://vldp.floal:636/CN=Administration,CN=fdam,DC=fg,DC=local 这是用户所在的地方: ldaps://vldp.floal:636/CN=ProxyUsers,CN=fdam,DC=fg,DC=local 所以我使用这个设置: @Autowired public void configureGlobal(AuthenticationManagerBuilder auth) throws Exception{ auth.ldapAuthentication() .contextSource() .url(“ldaps://vldp.floal:636/DC=fg,DC=local”) .managerDn(“CN=A0XXX32,CN=Administration,CN=fdam,DC=fg,DC=local”) .managerPassword(password) .and() .userSearchBase(“CN=ProxyUsers,CN=fdam”) .userSearchFilter(“(CN={0})”) .ldapAuthoritiesPopulator(myAuthPopulator); } 当我尝试通过用户登录时,问题是exception抛出,我收到此错误: 2016-03-25 14:43:14 [http-nio-8086-exec-6] ERROR osswaUsernamePasswordAuthenticationFilter – An internal error occurred while trying to authenticate the user. org.springframework.security.authentication.InternalAuthenticationServiceException: [LDAP: error code 32 – 0000208D: NameErr: DSID-031522C9, problem 2001 (NO_OBJECT), data 0, best […]