Navishkar Sadheo
asked on
Reset multiple AD accounts in an OU with different passwords?
Dear Experts
It is possible to reset the passwords of multiple AD accounts in a particular with a different password for each user? I can supply a password list in a CSV file or is there a way to have the system generate random passwords for each account and put those in a CSV. Appreciate any advice.
It is possible to reset the passwords of multiple AD accounts in a particular with a different password for each user? I can supply a password list in a CSV file or is there a way to have the system generate random passwords for each account and put those in a CSV. Appreciate any advice.
If you have a text file (d:\usernames.txt) with
--
user1
user2
...
--
then this one-liner Batch will do and create an outputfile with all randomly generated passwords
--
user1
user2
...
--
then this one-liner Batch will do and create an outputfile with all randomly generated passwords
for /f %a in (d:\usernames.txt) do net user %a /random /domain>>d:\out.txt
This question needs an answer!
Become an EE member today
7 DAY FREE TRIALMembers can start a 7-Day Free trial then enjoy unlimited access to the platform.
View membership options
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
An example here:
https://community.spiceworks.com/topic/370755-reset-passwords-using-a-utility-for-ad
CSV:
Open in new window
PowerShell script:Open in new window