[英]Enabling an Active Directory account using JNDI
I have successfully created a disabled user in Active Directory via JNDI, but I am not sure how to enable it. 我已经通过JNDI在Active Directory中成功创建了一个禁用的用户,但是我不确定如何启用它。 Am I supposed to manipulate the userAccountControl attribute directly?
我应该直接操作userAccountControl属性吗? Thanks.
谢谢。
You are right. 你是对的。
Here are some values and the explanation how to use them : 以下是一些值及其用法说明 :
UF_TEMP_DUPLICATE_ACCOUNT 0x0100
UF_NORMAL_ACCOUNT 0x0200
UF_INTERDOMAIN_TRUST_ACCOUNT 0x0800
UF_WORKSTATION_TRUST_ACCOUNT 0x1000
UF_SERVER_TRUST_ACCOUNT 0x2000
UF_DONT_EXPIRE_PASSWD 0x10000
UF_SCRIPT 0x0001
UF_ACCOUNTDISABLE 0x0002
UF_HOMEDIR_REQUIRED 0x0008
UF_LOCKOUT 0x0010
UF_PASSWD_NOTREQD 0x0020
UF_PASSWD_CANT_CHANGE 0x0040
Exhaustive list of values here . 值的详尽列表 。
For example 例如
userAccountControl = 544
544 = 0x220 = UF_NORMAL_ACCOUNT | 544 = 0x220 = UF_NORMAL_ACCOUNT | UF_PASSWD_NOTREQD
UF_PASSWD_NOTREQD
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.