Actively exploited in the wild. This CVE is on the CISA Known Exploited Vulnerabilities list — treat remediation as urgent. Federal remediation due by 27 Apr 2022.
Windows 10 2004Operating system · Microsoft

CVE-2021-31166

CRITICAL · 9.8 CVSS v3.1 Published 2021-05-11
Fix available
A fix is available. Upgrade to 10.0.19041.982 / 10.0.19042.982 or later.
See remediation →
100/100
Remediation priority · Urgent
In the wild High EPSS Public exploit Remotely reachable No privileges Zero-click Patch available

Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.

NVD · unedited
HTTP Protocol Stack Remote Code Execution Vulnerability

Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.

dbcve analysis · high confidence

Remote code execution vulnerability in the Windows HTTP Protocol Stack (http.sys), the kernel-mode driver that processes HTTP requests for IIS and other Windows HTTP services. The vulnerability allows unauthenticated attackers to execute arbitrary code via specially crafted HTTP requests.

MitigationApply Microsoft security updates released in May 2021 (KB5003171 and subsequent patches) to vulnerable Windows systems running HTTP Protocol Stack services.

Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.

Affected products & versions What the vendor confirmedThe version ranges the vendor confirmed as vulnerable. If your version sits inside a range here, treat yourself as exposed until you have upgraded.

NVD · CPE data
Windows 10 2004Operating system
Affected:< 10.0.19041.982
Windows 10 20h2Operating system
Affected:< 10.0.19042.982
Windows Server 2004Operating system
Affected:< 10.0.19041.982
Windows Server 20h2Operating system
Affected:< 10.0.19042.982

CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.

From the vector
Attack vector
Network
Complexity
Low
Privileges
None
User interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.

dbcve checks

Work through these to decide whether this CVE applies to you.

  1. Identify Windows version and build number
    Run 'winver' from the command line or check 'systeminfo | findstr /B /C:"OS Name" /C:"OS Version"' to get the exact Windows version and build number
    Affected if The system is running Windows 10 2004 (build 19041) or Windows 10 20H2 (build 19042), or Windows Server 2004/20H2 with a build number lower than 10.0.19041.982 or 10.0.19042.982 respectively
  2. Confirm HTTP.sys is in use
    Check if Internet Information Services (IIS) is installed and running: 'sc query IISADMIN' or 'Get-Service W3SVC' in PowerShell. Also verify if HTTP Server API is enabled by checking for httptest.exe or reviewing installed Windows features under 'HTTP Services'
    Affected if IIS, HTTP Server API, or any service utilizing the Windows HTTP Protocol Stack is enabled and running on the affected system
  3. Verify HTTP listener is exposed to network
    Run 'netsh http show servicestate' to view active HTTP listeners. Check if port 80 or 443 is bound and listening on external interfaces. Review IIS bindings via IIS Manager or 'appcmd list site'
    Affected if The HTTP service is bound to listening ports and accessible over the network, increasing exposure to remote exploitation

A system is affected if it runs Windows 10 2004/20H2 or Windows Server 2004/20H2 with a build below 10.0.19041.982/10.0.19042.982 AND has HTTP.sys (IIS or HTTP Server API) enabled and exposed to network requests.

Generated from the published advisory. Verify against your own configuration.

Check your environment

Paste your version and any relevant configuration and it will be compared against the affected criteria above. Do not include secrets or credentials.

AI-assisted, checked against the advisory. Informational, not a guarantee.

Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.

dbcve · scoped
Upgrade available Upgrade to 10.0.19041.982 / 10.0.19042.982 or later
Fixed in 10.0.19041.98210.0.19042.982
Interim mitigation

Apply Microsoft security updates released in May 2021 (KB5003171 and subsequent patches) to vulnerable Windows systems running HTTP Protocol Stack services.

Recommended fix High confidence

Windows 10 2004: Build 19041.982+ | Windows 10 20h2: Build 19042.982+ | Windows Server 2004: Build 19041.982+ | Windows Server 20h2: Build 19042.982+

  1. Open Settings on the Windows machine and navigate to Update & Security > Windows Update
  2. Click 'Check for updates' to see available updates
  3. Install the latest cumulative security update for your Windows version
  4. For Windows 10 2004/Windows Server 2004: Ensure update KB5001402 or later is installed (contains fix for 10.0.19041.982)
  5. For Windows 10 20h2/Windows Server 20h2: Ensure update KB5001402 or later is installed (contains fix for 10.0.19042.982)
  6. Restart the system after installing the update
  7. Verify the installed version by running 'winver' command - confirm build number is 19041.982 or higher for 2004, or 19042.982 or higher for 20h2

Generated from the published advisory — verify against the referenced sources before acting.

Fix this in Windows 10 2004 Exploited in the wild — priority engagement
  • Consultation2.0 h
  • Implementation4.0 h
  • Testing4.0 h
  • Review / QA2.0 h
12.0 hours of engineering $2,080
Get it fixed fast

An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $3,328.

Scan for this in your stack

Free · runs locally
dbcve dependency scanner

Check whether your project pulls in CVE-2021-31166 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.

References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.

Primary sources

Practitioner notes

Contributed

Peer-ranked notes from engineers who’ve handled CVE-2021-31166 in production — separate from our analysis above.

No notes yet

Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.

What this is

A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.

What belongs here
  • Verified mitigations, workarounds, and config changes
  • Version or environment caveats, and links to real fixes
  • No weaponised exploit code, or anything meant to cause harm
  • No spam, self-promotion, credentials, or personal data