Windows: disable the Print Spooler service
Stop and disable the Print Spooler with PowerShell to reduce the attack surface.
The Windows Print Spooler service has been exposed to several critical vulnerabilities (the "PrintNightmare" family). On a server or workstation that does not print, the simple mitigation is to stop and disable the service. Reference: AskVG, security alert about the Print Spooler.
Disable the service (PowerShell, as administrator)
Stop-Service -Name Spooler -Force
Set-Service -Name Spooler -StartupType Disabled
To revert:
Set-Service -Name Spooler -StartupType Automatic
Start-Service -Name Spooler
Notes
- With the service disabled, no printing, local or network, is possible on the machine.
- The same setting is available in
services.msc("Print Spooler" service) or through Group Policy. - Also install the Microsoft security updates: disabling the service is a mitigation.