Java 使用Glassfish 3.1获取Active Directory域时出错

Java 使用Glassfish 3.1获取Active Directory域时出错,java,glassfish,ldap,glassfish-3,Java,Glassfish,Ldap,Glassfish 3,大家好,我在glass fish 3.1中尝试用配置Relam Ldap解决这个问题,但我遇到了这个错误 WARNING: SEC1106: Error during LDAP search with filter [uid=teuser]. WARNING: SEC1000: Caught exception. javax.naming.NamingException: [LDAP: error code 1 - 000004DC: LdapErr: DSID-0C0906E8, commen

大家好,我在glass fish 3.1中尝试用配置Relam Ldap解决这个问题,但我遇到了这个错误

WARNING: SEC1106: Error during LDAP search with filter [uid=teuser].
WARNING: SEC1000: Caught exception.
javax.naming.NamingException: [LDAP: error code 1 - 000004DC: LdapErr: DSID-0C0906E8, comment: In order to perform this operation a successful bind must be completed on the connection., data 0, v1db1]; remaining name= 'DC=dev,DC=tcs,DC=com'
WARNING: WEB9102: Web Login Failed: com.sun.enterprise.security.auth.login.common.LoginException: Login failed: javax.security.auth.login.LoginException: User MyUserName not found.
web.xml如下所示:

<security-constraint>
<display-name>Constraint1</display-name>
    <web-resource-collection>
        <web-resource-name>Simple Web Resource</web-resource-name>
        <description/>
        <url-pattern>*</url-pattern>
    </web-resource-collection>
</security-constraint>

<login-config>
    <auth-method>FORM</auth-method>
    <realm-name>ldapRealm</realm-name>
    <form-login-config>
        <form-login-page>/index.jsp</form-login-page>
        <form-error-page>/error.xhtml</form-error-page>
    </form-login-config>
</login-config>

约束1
简单网络资源
*
形式
ldapRealm
/index.jsp
/error.xhtml

glassfish目录中的domain.xml:

<auth-realm name="ldapRealm" classname="com.sun.enterprise.security.auth.realm.ldap.LDAPRealm">
      <property name="directory" value="ldap://10.0.???.???:389"></property>
      <property name="base-dn" value="DC=dev,DC=tcs,DC=com"></property>
      <property name="jaas-context" value="ldapRealm"></property>
    </auth-realm>


我需要知道那个错误是什么,是glassfish的配置问题还是什么?

当我没有为Active Directory服务器指定正确的凭据时,我遇到了这个问题。将凭据指定为其他域属性:

  • 搜索用户名
  • 搜索绑定密码以查找密码

  • 当我没有为Active Directory服务器指定正确的凭据时,我遇到了这个问题。将凭据指定为其他域属性:

  • 搜索用户名
  • 搜索绑定密码以查找密码