close to final rev
This commit is contained in:
@@ -34,12 +34,15 @@ if (-not ([Security.Principal.WindowsIdentity]::GetCurrent().Groups -contains 'S
|
|||||||
Remove-NetNeighbor -Confirm:$false > $null
|
Remove-NetNeighbor -Confirm:$false > $null
|
||||||
|
|
||||||
Write-Host "CLEARING ALL SAMBA CREDENTIALS"
|
Write-Host "CLEARING ALL SAMBA CREDENTIALS"
|
||||||
net use * /delete /y > $null
|
net use * /delete /y > $null 2> $null
|
||||||
|
|
||||||
Write-Host "RENEWING DHCP"
|
Write-Host "RENEWING DHCP"
|
||||||
ipconfig /releasen > $null
|
ipconfig /releasen > $null
|
||||||
ipconfig /renew > $null
|
ipconfig /renew > $null
|
||||||
|
|
||||||
|
Write-Host "UPDATING MALWARE SIGNATURES"
|
||||||
|
Update-MpSignature # update windows defender malware siggs
|
||||||
|
|
||||||
Write-Host "LAUNCHING WINDOWS MALICIOUS SOFTWARE REMOVAL TOOL (MRT, MAY TAKE A LONG TIME, WONT SHOW STATUS)"
|
Write-Host "LAUNCHING WINDOWS MALICIOUS SOFTWARE REMOVAL TOOL (MRT, MAY TAKE A LONG TIME, WONT SHOW STATUS)"
|
||||||
Start-Process -FilePath "MRT.exe" -ArgumentList "/F:Y /Q" -Wait # do full microsoft malicious software removal scan in background automatically removing anything found, wait to proceed
|
Start-Process -FilePath "MRT.exe" -ArgumentList "/F:Y /Q" -Wait # do full microsoft malicious software removal scan in background automatically removing anything found, wait to proceed
|
||||||
|
|
||||||
@@ -58,12 +61,12 @@ if (-not ([Security.Principal.WindowsIdentity]::GetCurrent().Groups -contains 'S
|
|||||||
Write-Host "SCHEDULING OFFLINE CHECK DISK AND REPAIR OF C: (CHKDSK)"
|
Write-Host "SCHEDULING OFFLINE CHECK DISK AND REPAIR OF C: (CHKDSK)"
|
||||||
echo y | chkdsk.exe /f /r C: # cmd checks C drive after reboot to waste time and fix errors (noninteractive via y ffuckery)
|
echo y | chkdsk.exe /f /r C: # cmd checks C drive after reboot to waste time and fix errors (noninteractive via y ffuckery)
|
||||||
|
|
||||||
Write-Host "SCHEDULING WINDOWS DEFENDER OFFLINE SCAN MAY REBOOT UNEXPECTEDLY"
|
|
||||||
Start-MpWDOScan # powershell starts Windows Defender Offline Scan after reboot
|
|
||||||
|
|
||||||
Write-Host "SCHEDULINMG OFFLINE MEMTEST"
|
Write-Host "SCHEDULINMG OFFLINE MEMTEST"
|
||||||
mdsched.exe /s # schedule offline memtest (noninteractive)
|
mdsched.exe /s # schedule offline memtest (noninteractive)
|
||||||
|
|
||||||
|
Write-Host "SCHEDULING WINDOWS DEFENDER OFFLINE SCAN MAY REBOOT UNEXPECTEDLY"
|
||||||
|
Start-MpWDOScan # powershell starts Windows Defender Offline Scan after reboot
|
||||||
|
|
||||||
Write-Host "`nREBOOTING IN 5 MINUTES MAX PROVBABLY SOONER`n"
|
Write-Host "`nREBOOTING IN 5 MINUTES MAX PROVBABLY SOONER`n"
|
||||||
shutdown.exe /r /t 300 # shutdown in 5 minutes as failsafe
|
shutdown.exe /r /t (60*5) # shutdown in 5 minutes as failsafe
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user