Kako kroz vbs login scriptu (ili kako uopste) useru koji je non-admin importovati registry key
npr
Code:
sUser="Administrator@domen"
sPass="123123"
sCmd="regedit /s \\server\file.reg"
rc=WshShell.Run("runas /user:" & sUser & " " & CHR(34) & sCmd & CHR(34), 2, FALSE)
Wscript.Sleep 30 'need to give time for window to open.
WshShell.AppActivate(WinPath) 'make sure we grab the right window to send password to
WshShell.SendKeys sPass 'send the password to the waiting window.
sUser="Administrator@domen"
sPass="123123"
sCmd="regedit /s \\server\file.reg"
rc=WshShell.Run("runas /user:" & sUser & " " & CHR(34) & sCmd & CHR(34), 2, FALSE)
Wscript.Sleep 30 'need to give time for window to open.
WshShell.AppActivate(WinPath) 'make sure we grab the right window to send password to
WshShell.SendKeys sPass 'send the password to the waiting window.
file.reg sadrzhi export HKEY_CURRENT_USER hivea (npr HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Cache)
Ovaj scenario bi trebao da odradi posao, međutim ako file.reg sadrži nešto iz HCU-a import se dešava na Administrator@domen profilu (Logicno)
Elem, jos jednom pitanje,
kako domenskom non-admin useru menjati registry prilikom logovanja ?
Poz i hvala unapred
--/tsw