![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
|
Welcome to Vista Forums we are your forum to discuss Windows Vista x64 and x86 systems. Whether you need help or just want to post an idea you have on Vista, this is the forum for you.
br> br> |
| |||||||
![]() |
| | Thread Tools | Display Modes |
| | #1 (permalink) |
| Guest | local groups I have a list of local users and I have text file that matches the local users with new passwords I would like to write a script that match the local user and then reset to the new password the text sample is jdoe,password Please let me know if that correct as well Thanks in advance |
My System Specs![]() |
| | #2 (permalink) |
| Guest | Re: local groups Here is the function to set password "frank" <frank@discussions.microsoft.com> wrote in message news:349906CA-F949-4EA2-89A1-6D329CE74472@microsoft.com... >I have a list of local users and I have text file that matches the local > users with new passwords > > I would like to write a script that match the local user and then reset to > the new password > > the text sample is jdoe,password > > Please let me know if that correct as well > > Thanks in advance |
My System Specs![]() |
| | #3 (permalink) |
| Guest | Re: local groups This is real post... Im on the bus and we hit a bump... and off the post went. ---------------------------------------------------------------------------- Here is a function to Reset local user password on Remote Machine function Reset-UserPassword{ # From: Brandon Shell # Purpose: To Reset User Password on Hosts Local SAM # Example: # -- # PS> Reset-UserPassword -user Jsmith -password H!Th3r3 -server myserver1 ################################################################# Param([string]$user,[string]$password,[string]$server) If(!($server)){$server = get-content env:COMPUTERNAME} $tUser = [ADSI]("WinNT://$server/$user,User") $tUser.SetPassword($password) } You can then do something like. I havent tested this as I am on the bus. $csv = get-content $UserCSVFile foreach($srv in $servers) { foreach($entry in $csv) { $usr = $entry.Split(",")[0] $pwd = $entry.Split(",")[1] Reset-UserPassword -user $usr -password $pwd -server $srv } } "frank" <frank@discussions.microsoft.com> wrote in message news:349906CA-F949-4EA2-89A1-6D329CE74472@microsoft.com... >I have a list of local users and I have text file that matches the local > users with new passwords > > I would like to write a script that match the local user and then reset to > the new password > > the text sample is jdoe,password > > Please let me know if that correct as well > > Thanks in advance |
My System Specs![]() |
![]() |
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Add local machine users to local admin group via GPO | Andrew | .NET General | 0 | 06-10-2008 10:43 PM |
| AD Domain Local Groups and Vista | James A. Buker | Vista account administration | 3 | 12-11-2007 07:25 PM |
| Local Users and Groups | UnknownTBeast | Vista General | 3 | 11-11-2007 06:32 PM |
| Can NOT find "Local users and groups" in Control Panel -> Management Tools -> Computer Management! | dave | Vista General | 3 | 06-30-2007 09:08 AM |
| Two Ethernet Cards, local shows as limited instead of as local | Deathwing00 | Vista networking & sharing | 10 | 06-15-2007 09:05 AM |