2

このエラーが発生しました。どういう意味ですか?

org.springframework.ldap.NameNotFoundException: [LDAP: error code 32 - 0000208D: NameErr: DSID-031001A8, problem 2001 (NO_OBJECT), data 0, best match of:
    ''
]; nested exception is javax.naming.NameNotFoundException: [LDAP: error code 32 - 0000208D: NameErr: DSID-031001A8, problem 2001 (NO_OBJECT), data 0, best match of:
    ''
]; remaining name '/'
    org.springframework.ldap.support.LdapUtils.convertLdapException(LdapUtils.java:172)
    org.springframework.ldap.core.LdapTemplate.search(LdapTemplate.java:306)
    org.springframework.ldap.core.LdapTemplate.search(LdapTemplate.java:237)
    org.springframework.ldap.core.LdapTemplate.search(LdapTemplate.java:624)
    org.springframework.ldap.core.LdapTemplate.search(LdapTemplate.java:535)
    org.springframework.ldap.core.LdapTemplate.search(LdapTemplate.java:462)
    org.springframework.ldap.core.LdapTemplate.search(LdapTemplate.java:483)
    org.springframework.ldap.core.LdapTemplate.search(LdapTemplate.java:503)
    org.springframework.ldap.core.LdapTemplate.authenticate(LdapTemplate.java:1424)
    org.springframework.ldap.core.LdapTemplate.authenticate(LdapTemplate.java:1386)
    com.spsetia.iss.services.ISSServiceImpl.login(ISSServiceImpl.java:92)
    sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    java.lang.reflect.Method.invoke(Method.java:597)
    org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:307)
    org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
    org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
    org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
    org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
    org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
    $Proxy55.login(Unknown Source)
    sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    java.lang.reflect.Method.invoke(Method.java:597)
    org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:307)
    org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
    org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
    org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106)
    org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
    org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
    $Proxy56.login(Unknown Source)
    com.spsetia.iss.services.UserDetailsServiceImpl.loadUserByUsername(UserDetailsServiceImpl.java:70)
    com.spsetia.iss.services.UserDetailsAuthenticationProvider.retrieveUser(UserDetailsAuthenticationProvider.java:26)
    org.springframework.security.providers.dao.AbstractUserDetailsAuthenticationProvider.authenticate(AbstractUserDetailsAuthenticationProvider.java:121)
    org.springframework.security.providers.ProviderManager.doAuthentication(ProviderManager.java:188)
    org.springframework.security.AbstractAuthenticationManager.authenticate(AbstractAuthenticationManager.java:46)
    org.springframework.security.ui.webapp.AuthenticationProcessingFilter.attemptAuthentication(AuthenticationProcessingFilter.java:82)
    org.springframework.security.ui.AbstractProcessingFilter.doFilterHttp(AbstractProcessingFilter.java:258)
    org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)
    org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)
    org.springframework.security.context.HttpSessionContextIntegrationFilter.doFilterHttp(HttpSessionContextIntegrationFilter.java:235)
    org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)
    org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)
    org.springframework.security.util.FilterChainProxy.doFilter(FilterChainProxy.java:175)
    org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:236)
    org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:167)

私はこれをやろうとしています

 filter.and(new EqualsFilter("objectclass", "user")).and(new EqualsFilter("mail", username));
  return ldapTemplate.authenticate(DistinguishedName.EMPTY_PATH, filter.toString(), password);
4

2 に答える 2

2

1 つは Spring LDAP 1.2.1 を使用し、もう 1 つは 1.3.0 を使用しています。1.2.1 バージョンは機能しますが、1.3.0 バージョンでは上記のエラーが発生します。

2 つのバージョンには小さな違いがあります。バージョン 1.3.0 では、接続プールが無効になり、SingleContextSource が使用されます。( Active Directory でページングされた結果の取得を台無しにする LDAP 接続プーリングも避けてください)

1.3.0 でバグが発生したと思います。

于 2011-08-30T13:16:31.517 に答える
0

LDAP 32 は eDirectory -601 と AD のようなものです (ああ、コードを忘れてしまいました)。

基本的にオブジェクトが見つかりません。バインドするために提供した DN が正しくないのだろうか? 検索を行っているため、検索で見つからないオブジェクトは、実際には空の検索結果を返すだけです。

于 2010-07-30T02:11:49.257 に答える