Create/Update AD User Object Orchestration Activity - Set userAccountControl
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-23-2018 08:21 AM
Hi all,
Currently I have a working workflow to create/update AD User Records based on updates or inserts of users on the sys_user table in SNOW.
Essentially, when a new user is added, or a user is updated on SNOW it prompts the workflow to Query AD > Create AD > Update AD and then fire off some notifications.
This all works correctly, however, my user is always (by default) added to AD with an userAccountControl value of 546 rather than the active indicator of 512.
I been trying to set that value the way I set my other attributes (through the object data*), however, I always get 1 of 2 errors (also attached):
- The server is unwilling to process the request...
- The attribute syntax specified to the directory service is invalid...
Is there a specific value I need to pass in instead? I tried the value directly, the hex values, other attributes, etc. But it either makes 0 changes or returns a 'Failure' result.
I read through most of the other threads but I can't seem to put it together; any advice is appreciated!
Thank you!
_________________________________________________________________________________________________
*Object Data:
{"givenName: current.name, "department", current.department, "sn": current.last_name, etc.} <- WORKS
{"givenName: current.name, "department", current.department, "userAccountControl": 512 <or some sort of variation> ,"sn": current.last_name, etc.} <- DOES NOT WORK
- Labels:
-
Workflow
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2018 07:51 AM
Hey All,
I was able to figure this one out, in case anyone ever encounters the same issue here is the EASY answer I happened to overlook all this time:
- Add the userPassword attribute on creation of the AD object.
- By adding the password you can then Reset AD User Password without a Policy Failure, make sure you understand the company's password requirements (special characters, length, etc.)
- Add an Enable AD User Account activity - this needs a password (of type 2, reversible) set in order to succeed
I had only the Reset AD and Enable AD set but never instantiated the userPassword attribute which was causing the error.
Be sure to check that you also have the correct permissions associated to your account on your initial setup as well!
Best Regards,
Han Jie