Link to home
Start Free TrialLog in
Avatar of petermolit
petermolit

asked on

VBscript to check computer account in AD for trusted for delegation?

How can we use vbscript to check for an computer account in AD for the trusted for delegation setting?

Avatar of ihenry
ihenry

Hi petermolit

try this script

Const ADS_UF_TRUSTED_FOR_DELEGATION = 524288
 
Set objUser = GetObject _
("LDAP://cn=xxx,ou=xxx,dc=xxx,dc=xxx")
intUAC = objUser.Get("userAccountControl")
 
objUser.Put "userAccountControl", intUAC OR ADS_UF_TRUSTED_FOR_DELEGATION
objUser.SetInfo
ASKER CERTIFIED SOLUTION
Avatar of ihenry
ihenry

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial