quote:
shell '%COMSPEC% /C net user Administrator newpassword'
Correct me if I'm wrong - a fairly normal state - but the above would need to be run on the remote machine, which brings up a whole new set of questions.
cusrmgr.exe, which I think is in the Win2k Resource Kit, will do the task remotely: (the qoute tag mangles the formatting, hence the CODE tags)
code:
C:\>cusrmgr
CUsrMgr Ver 1.0 Jan98 by G.Zanzen (c) MCS Central Europe
Sets a random password to a user
usage: -u UserName [-m \\MachineName] \\ default LocalMachine
Resetting Password Function
-p Set to a random password
-P xxx Sets password to xxx
User Functions
-r xxx Renames user to xxx
-d xxx deletes user xxx
Group Functions
-rlg xxx yyy Renames local group xxx to yyy
-rgg xxx yyy Renames global group xxx to yyy
-alg xxx Add user (-u UserName) to local group xxx
-agg xxx Add user (-u UserName) to global group xxx
-dlg xxx deletes user (-u UserName) from local group xxx
-dgg xxx deletes user (-u UserName) from global group xxx
SetProperties Functions
-c xxx sets Comment to xxx
-f xxx sets Full Name to xxx
-U xxx sets UserProfile to xxx
-n xxx sets LogonScript to xxx
-h xxx sets HomeDir to xxx
-H x sets HomeDirDrive to x
+s xxxx sets property xxxx
-s xxxx resets property xxxx
where xxxx can be any of the following properties:
MustChangePassword
CanNotChangePassword
PasswordNeverExpires
AccountDisabled
AccountLockout
RASUser
returns 0 on success
I have used this in the past to rename and reset local admin passwords.
_________________________
Jim
--------------------