LDAP OperationNotSupportedException:错误代码53-WILL_NOT_PERFORM [英] LDAP OperationNotSupportedException : error code 53 - WILL_NOT_PERFORM
问题描述
当我使用JNDI创建与活动目录进行通信的用户时,我现在得到LDAP Error 53 (WILL_NOT_PERFORM)
.
when I create a user using JNDI to communicate to active directory , I am now getting LDAP Error 53 (WILL_NOT_PERFORM)
.
我正在尝试为创建的用户设置密码.另外,我还禁用了用户必须在下次登录时更改密码"选项.
I'm trying set password for the created user. Also I've disabled the 'User must change password at next logon' option.
attrs.put("unicodePwd", "\"Test123\"".getBytes("UTF-16LE") );
String newValue = Integer.toString(-1);
ModificationItem mods[] = new ModificationItem[2];
mods[0] = new ModificationItem(DirContext.REMOVE_ATTRIBUTE,
new BasicAttribute("pwdLastSet"));
mods[1] = new ModificationItem(DirContext.ADD_ATTRIBUTE,
new BasicAttribute("pwdLastSet",
newValue));
ctx.modifyAttributes(userName, mods);
问题创建对象:
javax.naming.OperationNotSupportedException: [LDAP: error code 53 - 0000001F: SvcErr: DSID-031A0FC0, problem 5003 (WILL_NOT_PERFORM), data 0
关于我在做什么错了还是想念的任何想法?
Any ideas as to what I am doing wrong or missing?
推荐答案
您没有显示如何连接到Active Directory服务器,但是如果尝试通过连接设置密码,则会出现此错误不是SSL/TLS.
You don't show how you're connecting to the Active Directory server, but you will get this error if you try to set a password over a connection that is not SSL/TLS.
当前,您A/D服务器的URL可能如下所示:
Currently the URL to your A/D server probably looks like this:
ldap://(服务器地址):389
ldap://(server address):389
尝试将其更改为:
ldaps://(服务器地址):636
ldaps://(server address):636
这篇关于LDAP OperationNotSupportedException:错误代码53-WILL_NOT_PERFORM的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!