Active directory Active Directory LDAP中出现错误533

Active directory Active Directory LDAP中出现错误533,active-directory,Active Directory,我正在尝试配置Active Directory(AD LDS)以用于我的应用程序。我正在Weblogic app server中使用ForeignJNDIProvider来配置AD的设置。从基于Java的应用程序中,我在InitialContext上进行查找,如下所示: InitialContext iCtx = new InitialContext(); DirContext dir = (DirContext) iCtx.lookup(<JNDI name>); Initial

我正在尝试配置Active Directory(AD LDS)以用于我的应用程序。我正在Weblogic app server中使用ForeignJNDIProvider来配置AD的设置。从基于Java的应用程序中,我在InitialContext上进行查找,如下所示:

InitialContext iCtx = new InitialContext();
DirContext dir = (DirContext) iCtx.lookup(<JNDI name>);
InitialContext iCtx=newinitialcontext();
DirContext dir=(DirContext)iCtx.lookup();
上面的第二行代码失败,出现以下错误:

javax.naming.AuthenticationException: [LDAP: error code 49 - 8009030C: LdapErr: DSID-0C0903A9, comment: AcceptSecurityContext error, data 533, v1db1 ]
at com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:3067)
at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:3013)
at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2815)
at com.sun.jndi.ldap.LdapCtx.connect(LdapCtx.java:2729)
at com.sun.jndi.ldap.LdapCtx.<init>(LdapCtx.java:296)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURL(LdapCtxFactory.java:175)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURLs(LdapCtxFactory.java:193)
at com.sun.jndi.ldap.LdapCtxFactory.getLdapCtxInstance(LdapCtxFactory.java:136)
at com.sun.jndi.ldap.LdapCtxFactory.getInitialContext(LdapCtxFactory.java:66)
at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:667)
at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:288)
at javax.naming.InitialContext.init(InitialContext.java:223)
at javax.naming.InitialContext.<init>(InitialContext.java:197)
at weblogic.jndi.internal.ForeignOpaqueReference.getReferent(ForeignOpaqueReference.java:70)
at weblogic.jndi.internal.WLNamingManager.getObjectInstance(WLNamingManager.java:96)
at weblogic.jndi.internal.ServerNamingNode.resolveObject(ServerNamingNode.java:377)
at weblogic.jndi.internal.BasicNamingNode.resolveObject(BasicNamingNode.java:856)
at weblogic.jndi.internal.BasicNamingNode.lookup(BasicNamingNode.java:209)
at weblogic.jndi.internal.WLEventContextImpl.lookup(WLEventContextImpl.java:254)
at weblogic.jndi.internal.WLContextImpl.lookup(WLContextImpl.java:411)
at javax.naming.InitialContext.lookup(InitialContext.java:392)
javax.naming.AuthenticationException:[LDAP:错误代码49-8009030C:LDAPPER:DSID-0C09003A9,注释:AcceptSecurityContext错误,数据533,v1db1]
位于com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:3067)
位于com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:3013)
位于com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2815)
位于com.sun.jndi.ldap.LdapCtx.connect(LdapCtx.java:2729)
位于com.sun.jndi.ldap.LdapCtx.(LdapCtx.java:296)
位于com.sun.jndi.ldap.LdapCtxFactory.getUsingURL(LdapCtxFactory.java:175)
位于com.sun.jndi.ldap.LdapCtxFactory.getUsingURLs(LdapCtxFactory.java:193)
位于com.sun.jndi.ldap.LdapCtxFactory.getLdapCtxInstance(LdapCtxFactory.java:136)
位于com.sun.jndi.ldap.LdapCtxFactory.getInitialContext(LdapCtxFactory.java:66)
位于javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:667)
位于javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:288)
位于javax.naming.InitialContext.init(InitialContext.java:223)
位于javax.naming.InitialContext。(InitialContext.java:197)
在weblogic.jndi.internal.foreignopaqueryreference.getReferent(foreignopaqueryreference.java:70)
位于weblogic.jndi.internal.WLNamingManager.getObjectInstance(WLNamingManager.java:96)
位于weblogic.jndi.internal.ServerNamingNode.resolveObject(ServerNamingNode.java:377)
位于weblogic.jndi.internal.basicnamignode.resolveObject(basicnamignode.java:856)
位于weblogic.jndi.internal.basicnamignode.lookup(basicnamignode.java:209)
在weblogic.jndi.internal.WLEventContextImpl.lookup(WLEventContextImpl.java:254)上
位于weblogic.jndi.internal.WLContextImpl.lookup(WLContextImpl.java:411)
在javax.naming.InitialContext.lookup(InitialContext.java:392)中

我试着查找广告中533错误的含义。我得到的唯一答案是,它意味着“帐户禁用”。我不确定情况是否如此。如何修复此问题?

明白了…通过将属性msDS UserAccountDisabled的值更改为false,解决了此问题。默认情况下,创建广告帐户时将禁用。
资源:

对于我来说,错误出现在属性“userAccountControl”中。我不得不将它从546(ACCOUNTDISABLE | PASSWD | u NOTREQD | NORMAL | u ACCOUNT)更改为512(NORMAL | u ACCOUNT)。另请参见:

我刚刚从堆栈跟踪中查找了错误代码49,并在此处找到了一个链接:。我建议在apache的directory studio中测试LDAP相关的查询、连接等(我积极使用):嗨,apache的directory studio看起来非常酷,但它不会在我的AD LDS DN下显示目录项(我可以使用ADSI Edit看到)。有什么想法吗?