#32405 - 2002-11-13 08:23 PM
admin rights stuff
|
SteveSG
Fresh Scripter
Registered: 2002-11-13
Posts: 6
|
I have been searching the forums for a couple days, and a lot of the stuff is either too confusing/advanced for a newbie like me or inapplicable.
I have a very simple machine inventory script composed of essentially two functions, WMIQuery and WriteLog2. WMI Query gathers the information, WriteLog writes it to a log file. This is set to run as a custom script for all users. If a user with Local Admin / Domain Admin rights logs in and runs the script, what is written to the log looks like this (sample from log file):
2002/11/11 13:38:01 - IBM 2658BPU / No Asset Information, S/N: ******* / *******, adminuser, 1.1.1.1, MachineName, NT 5.0.2195 : Service Pack 3
Where ******* are valid serial numbers, 1.1.1.1 is a valid IP, adminuser is the proper username, and MachineName is the correct client machine name.
If a user without such rights logs in (most of our employees), the same computer will write this to the log:
2002/11/12 09:17:30 - IBM___ TP-1M___ / , S/N: / , normaluser, 1.1.1.1, MachineName, NT 5.0.2195 : Service Pack 3
Here the Model is hidden as well as the serial number, the rest is correct (and not part of what WMIQuery pulls).
I can only assume that since the user logging in does not have admin rights on the machine it will not report the information. Thus I wish to know how to run the script under full local admin access so that even if Joe User logs in, the correct information is reported.
I'm not executing any external exe or vbs or anythingso I'm not sure taskscheduling is the thing for me, and I don't like the security problems with SU.exe.
The weird thing is, if I log in as Joe User and run wkix32.exe (I'm using scriptlogic) and the script, it works fine. But if I try to have the script do it during the logon process, it won't work unless the user has admin rights.
Very frustrating
|
|
Top
|
|
|
|
Moderator: Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart
|
0 registered
and 1619 anonymous users online.
|
|
|