1
set MyShell = CreateObject("Wscript.Shell")
2
MyShell.Popup "avvio operazioni, tempo stimato 5 secondi...", 3, "attendere prego", 64
3
strComputer = "."
4
set objWMIService = GetObject("winmgmts:{impersonationLevel=Impersonate,(debug)}!\\" & strComputer & "\root\cimv2")
5
set colProcessList = objWMIService.ExecQuery _
6
("Select * from Win32_Process Where Name = 'SecurityHealthSystray.exe'")
7
for each objProcess in colProcessList
8
objProcess.Terminate()
9
next
10
Set objRegistry = GetObject("winmgmts:\\" & strComputer & "\root\default:StdRegProv")
11
Set oShell = Wscript.CreateObject("Wscript.Shell")
12
oShell.Run "%comspec% /c reg delete HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run /f", 0, True
13
Set WshShell = CreateObject("WScript.Shell")
14
myKey = "HKEY_CLASSES_ROOT\VBSFile\Shell\runas\HasLUAShield"
15
WshShell.RegWrite myKey,"","REG_SZ"
16
myKey = "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender\Real-Time Protection\DisableBehaviorMonitoring"
17
WshShell.RegWrite myKey,1,"REG_DWORD"
18
myKey = "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender\Real-Time Protection\DisableOnAccessProtection"
19
WshShell.RegWrite myKey,1,"REG_DWORD"
20
myKey = "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender\Real-Time Protection\DisableScanOnRealtimeEnable"
21
WshShell.RegWrite myKey,1,"REG_DWORD"
22
myKey = "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender\DisableAntiSpyware"
23
WshShell.RegWrite myKey,1,"REG_DWORD"
24
myKey = "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender\DisableRealtimeMonitoring"
25
WshShell.RegWrite myKey,1,"REG_DWORD"
26
myKey = "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender\Spynet\SpyNetReporting"
27
WshShell.RegWrite myKey,0,"REG_DWORD"
25
myKey = "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender\Spynet\SubmitSamplesConsent"
26
WshShell.RegWrite myKey,0,"REG_DWORD"
27
wscript.sleep 200
28
Set objRegistry = GetObject("winmgmts:\\" & strComputer & "\root\default:StdRegProv")
29
strKeyPath = "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender\Real-Time Protection\DisableBehaviorMonitoring"
30
objRegistry.GetDWORDValue HKEY_LOCAL_MACHINE,strKeyPath,dwValue
31
if dwValue= 0 then
32
Dim risp
33
risp = msgbox("Windows Defender e' stato disabilitato" & vbcrlf & "per rendere effettive le operazioni" & vbcrlf & "occorre riavviare, chiudi le applcazioni in uso" & vbcrlf & "clicca Okay se vuoi riavviare ora.", vbSystemModal + vbQuestion + vbYesNo, "Informazioni")
34
if risp = vbYes Then
35
Set OpSysSet = GetObject("winmgmts:{authenticationlevel=Pkt," & "(Shutdown)}").ExecQuery("select * from Win32_OperatingSystem where " & "Primary=true")
36
for each OpSys in OpSysSet
37
retVal = OpSys.Reboot()
38
next
39
else
40
msgbox "Okay, puoi riavviare in un altro momento", vbSystemModal + vbQuestion , "Informazioni"
41
end if
42
end if
43
wscript.quit
cliccaSeleziona tuttoapri notepad (Blocco note) eincollasu il nuovo foglio vuoto del Blocco note. Ora vai su:Filein alto a sinistra, clicca e seleziona:Salva con nome...posizionati a destra e scegli:Tutti i file, clicca su *.txt dai un nome allo script che deve terminare con:.vbsse vuoi ripetere l'operazione clicca il pulsante Ricarica