CVE DatabaseCVE-2021-34527
한국어 권고문 →
CVE-2021-345278.8/HIGHCISA KEV

Microsoft Windows Print Spooler Remote Code Execution Vulnerability (PrintNightmare, CVE-2021-34527) Technical Advisory

⚡ Jump to Patch
Affected Vendors
microsoft
Affected Components
windows, windows_server
Published Date
2021-07-02
CVSS v3.1
8.8
HIGH
EPSS (30d)
99.8%
FIRST.org
CISA KEV
Exploited

Executive & SecOps Summary

SECOPS ASSESSMENT
Affected Scope

Windows 7, 8.1, 10, 11 and Windows Server 2008, 2012, 2016, 2019, 2022 with the Windows Print Spooler service enabled

Impact

An authenticated remote attacker can execute arbitrary code with SYSTEM privileges, potentially leading to full domain compromise

Mitigation

Apply official cumulative security updates immediately, disable the Print Spooler service where not required, and harden Point and Print registry configurations

Affected Products & Version Scope

All versions of Microsoft Windows and Windows Server where the Windows Print Spooler service is running and unpatched.

Remediation & Live Workaround Commands

PATCH & WORKAROUND

1. Official Patch & Version Upgrade Commands

Apply the latest cumulative security updates provided by Microsoft. You can force the installation of pending security updates using PowerShell.

powershell
# Install Windows Update module and apply all outstanding security patches
Install-Module PSWindowsUpdate -Force -Verbose
Get-WindowsUpdate -AcceptAll -Install -AutoReboot

2. Temporary Workaround & Hardening Configuration

If patching cannot be performed immediately, disable the Print Spooler service to mitigate the attack vector. Additionally, ensure that Point and Print registry settings are configured securely.

powershell
# Stop and disable the Print Spooler service
Stop-Service -Name 'Spooler' -Force
Set-Service -Name 'Spooler' -StartupType Disabled

# Harden Point and Print registry keys to prevent unauthorized driver installation
$RegistryPath = 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Printers\PointAndPrint'
if (-not (Test-Path $RegistryPath)) {
    New-Item -Path $RegistryPath -Force
}
New-ItemProperty -Path $RegistryPath -Name 'NoWarningNoElevationOnInstall' -Value 0 -PropertyType DWORD -Force
New-ItemProperty -Path $RegistryPath -Name 'UpdatePromptSettings' -Value 0 -PropertyType DWORD -Force

3. Log Audit & IoC Verification Commands

Use the following commands to verify the status of the Print Spooler service and inspect event logs for potential exploitation attempts.

powershell
# Check the current status of the Print Spooler service
Get-Service -Name 'Spooler'

# Query event logs for suspicious printer driver installation events (Event ID 316 or 808)
Get-WinEvent -LogName 'Microsoft-Windows-PrintService/Admin' -ErrorAction SilentlyContinue | 
    Where-Object { $_.Id -eq 316 -or $_.Id -eq 808 } | 
    Select-Object TimeCreated, Id, Message | Format-Table -AutoSize
Interactive SecOps Remediation Checklist
0/4 (0%)
Recommended Security Control & Mitigation Partner
SentinelOne Singularity AI EDR
Immediately disable the Print Spooler service on all Domain Controllers and critical servers, or apply the latest Microsoft cumulative security updates.

Block Kernel Privilege Escalation & Ransomware Payloads Before You Can Reboot

Protect unpatched Windows, Linux, and macOS workloads against in-memory exploitation and lateral movement with autonomous EDR.

100% MITRE ATT&CK Detection · 1-Click Rollback

Technical Root Cause & Exploitation Mechanics

1. Vulnerability Overview & Root Cause

This vulnerability (CVE-2021-34527, widely known as 'PrintNightmare') is a critical remote code execution (RCE) and privilege escalation flaw in the Windows Print Spooler service. The root cause lies in the improper validation of file paths and privilege checks within the RpcAddPrinterDriverEx() function. This logical flaw allows an authenticated user to bypass access controls and force the Spooler service to install and load arbitrary, untrusted printer drivers.

2. Exploitation Mechanics & Attack Scenario

An attacker with low-privileged domain user credentials initiates a connection to the target system's Print Spooler service via RPC. The attacker hosts a malicious DLL payload on an external SMB share. By invoking the vulnerable RPC functions, the attacker instructs the target's Spooler service to copy the malicious DLL into the local driver directory (C:\Windows\System32\spool\drivers\...) and execute it. Because the Print Spooler service runs under the highly privileged NT AUTHORITY\SYSTEM context, the malicious DLL is executed with full system-level privileges.

3. Infrastructure & Business Impact

In an Active Directory (AD) environment, this vulnerability poses an existential threat. Domain Controllers (DCs) often run the Print Spooler service by default. An attacker with a compromised low-privilege domain account can exploit this vulnerability to gain immediate SYSTEM access on the DC, effectively achieving Domain Admin status. This allows for complete domain takeover, deployment of enterprise-wide ransomware, and persistent backdoors.

Official Vendor Advisories & References

NVD Original English Description

A remote code execution vulnerability exists when the Windows Print Spooler service improperly performs privileged file operations. An attacker who successfully exploited this vulnerability could run arbitrary code with SYSTEM privileges. An attacker could then install programs; view, change, or delete data; or create new accounts with full user rights. UPDATE July 7, 2021: The security update for Windows Server 2012, Windows Server 2016 and Windows 10, Version 1607 have been released. Please see the Security Updates table for the applicable update for your system. We recommend that you install these updates immediately. If you are unable to install these updates, see the FAQ and Workaround sections in this CVE for information on how to help protect your system from this vulnerability. In addition to installing the updates, in order to secure your system, you must confirm that the following registry settings are set to 0 (zero) or are not defined (Note: These registry keys do not exist by default, and therefore are already at the secure setting.), also that your Group Policy setting are correct (see FAQ): HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows NT\Printers\PointAndPrint NoWarningNoElevationOnInstall = 0 (DWORD) or not defined (default setting) UpdatePromptSettings = 0 (DWORD) or not defined (default setting) Having NoWarningNoElevationOnInstall set to 1 makes your system vulnerable by design. UPDATE July 6, 2021: Microsoft has completed the investigation and has released security updates to address this vulnerability. Please see the Security Updates table for the applicable update for your system. We recommend that you install these updates immediately. If you are unable to install these updates, see the FAQ and Workaround sections in this CVE for information on how to help protect your system from this vulnerability. See also KB5005010: Restricting installation of new printer drivers after applying the July 6, 2021 updates. Note that the security updates released on and after July 6, 2021 contain protections for CVE-2021-1675 and the additional remote code execution exploit in the Windows Print Spooler service known as “PrintNightmare”, documented in CVE-2021-34527.

Frequently Asked SecOps Questions (CVE-2021-34527)

FAQ

Q1. How critical is CVE-2021-34527 and is it actively exploited in the wild?

CVE-2021-34527 is rated CVSS 8.8 (HIGH) with a 30-day EPSS exploitation probability of 99.8%. It is listed in the CISA Known Exploited Vulnerabilities (KEV) catalog, requiring immediate emergency remediation.

Q2. Which vendors and products are affected by CVE-2021-34527?

Primary impacted vendors include microsoft across windows, windows_server. Scope summary: All versions of Microsoft Windows and Windows Server where the Windows Print Spooler service is running and unpatched.

Q3. What temporary mitigations or workarounds exist for CVE-2021-34527 before patching?

[Mitigation] Apply official cumulative security updates immediately, disable the Print Spooler service where not required, and harden Point and Print registry configurations Follow the CLI remediation commands and interactive SecOps checklist on this page to restrict exposure prior to your maintenance window.

SECOPS WORKBENCH INTEGRATION

Generate an Internal Engineering Notice or CISO Report for CVE-2021-34527

Instantly format this advisory into an executive CISO summary or engineering patch ticket.

Generate Report →

🔗 Related Advisories in Similar Stack (microsoft)

View Category →
SecOps Advisory Dispatch & RSS Feed

Subscribe to Daily Vulnerability Briefings & KEV Alerts

Concise morning briefings for SecOps, DevSecOps, and SRE teams covering newly exploited CVEs and mitigation priorities.

Slack / Teams / RSS Feed:
PatchKO
CVE-2021-34527 Microsoft Windows Print Spooler Remote Code Execution Vulnerability (PrintNightmare, CVE-2021-34527) Technical Advisory (CVSS 8.8) - Patch & Workaround | CVE Pulse