CVE-2021-1640

7.8 HIGH

📋 TL;DR

CVE-2021-1640 is a privilege escalation vulnerability in the Windows Print Spooler service that allows authenticated attackers to execute arbitrary code with SYSTEM privileges. This affects Windows systems with the Print Spooler service enabled. Attackers can exploit this to gain complete control over affected systems.

💻 Affected Systems

Products:
  • Microsoft Windows
Versions: Windows 10 versions 1809, 1909, 2004, 20H2; Windows Server 2019, 2022; Windows Server versions 1803, 1909, 2004, 20H2
Operating Systems: Windows 10, Windows Server 2019, Windows Server 2022
Default Config Vulnerable: ⚠️ Yes
Notes: Requires Print Spooler service to be running (default on most Windows systems). Print servers and workstations with shared printers are particularly vulnerable.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Full system compromise with SYSTEM privileges, enabling lateral movement, data theft, ransomware deployment, and persistent backdoor installation across the network.

🟠

Likely Case

Local privilege escalation from standard user to SYSTEM on individual workstations or servers, leading to credential harvesting, malware persistence, and local data access.

🟢

If Mitigated

Limited impact with proper network segmentation, least privilege enforcement, and Print Spooler service disabled on non-essential systems.

🌐 Internet-Facing: LOW
🏢 Internal Only: HIGH

🎯 Exploit Status

Public PoC: ⚠️ Yes
Weaponized: CONFIRMED
Unauthenticated Exploit: ✅ No
Complexity: LOW

Exploitation requires local authenticated access. Multiple proof-of-concept exploits are publicly available. The vulnerability has been actively exploited in the wild.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: January 2021 security updates (KB4598242 for Windows 10 2004/20H2, KB4598229 for Windows 10 1909, etc.)

Vendor Advisory: https://portal.msrc.microsoft.com/en-US/security-guidance/advisory/CVE-2021-1640

Restart Required: Yes

Instructions:

1. Apply the January 2021 Windows security updates through Windows Update. 2. For enterprise environments, deploy updates via WSUS, SCCM, or Intune. 3. Restart systems after patch installation.

🔧 Temporary Workarounds

Disable Print Spooler Service

windows

Stops the vulnerable service entirely. This will break printing functionality.

sc stop spooler
sc config spooler start= disabled

Restrict Spooler Directory Permissions

windows

Limits access to the spool directory to reduce attack surface.

icacls C:\Windows\System32\spool /deny "Users":(OI)(CI)F

🧯 If You Can't Patch

  • Disable Print Spooler service on all non-essential systems, especially servers and internet-facing systems.
  • Implement network segmentation to isolate print servers and restrict lateral movement from compromised systems.

🔍 How to Verify

Check if Vulnerable:

Check if Print Spooler service is running and system has not been patched with January 2021 updates.

Check Version:

systeminfo | findstr /B /C:"OS Name" /C:"OS Version"

Verify Fix Applied:

Verify Windows Update history shows January 2021 security updates installed and Print Spooler service version is updated.

📡 Detection & Monitoring

Log Indicators:

  • Event ID 7036 (service state change) for Print Spooler
  • Unexpected Print Spooler service restarts
  • Suspicious process creation from spoolsv.exe

Network Indicators:

  • Unusual RPC traffic to print spooler endpoints
  • Lateral movement attempts from print servers

SIEM Query:

EventID=7036 AND ServiceName="Spooler" | stats count by Computer, TimeGenerated

🔗 References

📤 Share & Export