Archive for July, 2011

VBScript–Active Directory Account Attributes

Below is a script that will output a list of Active Directory account attributes (password never expires, user cannot change password, etc) for an individual account. Set objUser = GetObject(“LDAP://cn=UserName,ou=OUName,dc=dcprefix,dc=dcsuffix”) intUAC = objUser.Get(“userAccountControl”) Const ADS_UF_SCRIPT = &H1 Const ADS_UF_ACCOUNTDISABLE = &H2 Const ADS_UF_HOMEDIR_REQUIRED = &H8 Const ADS_UF_LOCKOUT = &H10 Const ADS_UF_PASSWD_NOTREQD = &H20 Const ADS_UF_PASSWD_CANT_CHANGE […]

Leave a comment