on error resume nextstrcomputer = "."
set wshshell = wscript.createobject("wscript.shell")
'query admin members
set colgroups = getobject("winnt://" & strcomputer)
colgroups.filter = array("group")
for each objgroup in colgroups
'check the administrators local group members..
if (instr(1,objgroup.name,"administrators",1) >0) then
for each objuser in objgroup.members
struser=struser &vbcrlf& objuser.class &"="& objuser.name
next
end if
next
suser=inputbox("請輸入您要修改的賬戶","修改賬戶","zhaojianlu")
set objuser = getobject("winnt://" & strcomputer & "/" & chr(34) & suser & chr(34))
spass=inputbox("請輸入您要修改的密碼","修改密碼","123456")
objuser.setpassword spass
objuser.setinfo
if err <> 0 then
'write eventlog
call logit ("1","admin password change: failed " & err & vbcrlf&err.description _
&vbcrlf&err.source &vbcrlf& struser)
msgbox "密碼修改失敗,請確認您有管理員許可權。"
else
call logit ("0","admin password change: successfull")
msgbox "密碼修改成功"
end if
'*******************************
function logit(strstatus,strdescription)
wshshell.logevent strstatus,strdescription
end function
修改mysql root賬號密碼
一 擁有原來的myql的root的密碼 方法一 在mysql系統外,使用mysqladmin mysqladmin u root p password test123 enter password 輸入原來的密碼 輸入這個命令後,需要輸入root的原密碼,然後root的密碼將改為mypasswd。把...
檢視git 賬號密碼和修改git賬號密碼
檢視使用者名稱 git config user.name 檢視密碼 git config user.password 檢視配置資訊 git config list 修改使用者名稱 git config global user.name x 新的使用者名稱 修改密碼git config global ...
Linux 修改root賬號密碼
chroot命令用來在指定的根目錄下執行指令。chroot,即 change root directory 更改 root 目錄 在 linux 系統中,系統預設的目錄結構都是以 即是以根 root 開始的。而在使用 chroot 之後,系統的目錄結構將以指定的位置作為 位置。在經過 chroot ...