Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

Disabling ServiceNow user if Active Directory user is disabled

juriggs
Kilo Expert

We would like to disable a ServiceNow account during the LDAP sync if the Active Directory user is disabled. Is this possible?

1 ACCEPTED SOLUTION

Ankur Bawiskar
Tera Patron
Tera Patron

Hi,

check below script and it should help:

https://docs.servicenow.com/bundle/geneva-servicenow-platform/page/integrate/ldap/task/t_SetDisabled...

Mark Correct if this solves your issue and also mark Helpful if you find my response worthy based on the impact.
Thanks
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

2 REPLIES 2

Ankur Bawiskar
Tera Patron
Tera Patron

Hi,

check below script and it should help:

https://docs.servicenow.com/bundle/geneva-servicenow-platform/page/integrate/ldap/task/t_SetDisabled...

Mark Correct if this solves your issue and also mark Helpful if you find my response worthy based on the impact.
Thanks
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Dilip Puligilla
Giga Guru

Hi, juriggs,

 

In LDAP, All the deactivate user should have moved to different OU.

 

Create a new OU Definition and create a transform Map,

 

For all deactivate users there is property u_useraccountcontrol is enabled.

 

Utilize this property in transform map and deactivate the user.

 

Please let me know if you have any questions 

 

Thanks

Dilip