我使用Active Directory构建了CAS v.4.1.2,并在本地计算机上部署到tomcat 8。但是当我尝试登录时出现错误,我有下一个堆栈跟踪:
2015-11-26 23:45:48,071 DEBUG [org.jasig.cas.authentication.LdapAuthenticationHandler] - Attempting LDAP authentication for maksimov+password
2015-11-26 23:45:48,081 DEBUG [org.jasig.cas.authentication.LdapAuthenticationHandler] - LDAP response: [org.ldaptive.auth.AuthenticationResponse@588271304::authenticationResultCode=DN_RESOLUTION_FAILURE, ldapEntry=null, accountState=null, result=false, resultCode=null, message=DN cannot be null, controls=null]
2015-11-26 23:45:48,085 INFO [org.jasig.cas.authentication.PolicyBasedAuthenticationManager] - LdapAuthenticationHandler failed authenticating maksimov+password
2015-11-26 23:45:48,091 DEBUG [org.jasig.cas.authentication.PolicyBasedAuthenticationManager] - LdapAuthenticationHandler exception details: maksimov not found.
2015-11-26 23:45:48,095 DEBUG [org.jasig.cas.audit.spi.TicketOrCredentialPrincipalResolver] - Resolving argument [UsernamePasswordCredential] for audit
2015-11-26 23:45:48,100 INFO [org.jasig.inspektr.audit.support.Slf4jLoggingAuditTrailManager] - Audit trail record BEGIN
=============================================================
WHO: maksimov+password
WHAT: supplied credentials: [maksimov+password]
ACTION: AUTHENTICATION_FAILED
APPLICATION: CAS
WHEN: Thu Nov 26 23:45:48 YEKT 2015
CLIENT IP ADDRESS: 0:0:0:0:0:0:0:1
SERVER IP ADDRESS: 0:0:0:0:0:0:0:1
=============================================================
deployerConfigContext.xml里
答案 0 :(得分:1)
通过将searcfilter设置为sAMAccountName = {user}来解决问题。