Stack-based Buffer OverflowWeakness · CWE-121

CVE-2017-20205

CRITICAL · 9.2 CVSS v4.0 Published 2025-10-15
Mitigation only
No fix yet — a mitigation exists. There is no fixed release. A documented workaround reduces exposure in the meantime.
See remediation →
100/100
Remediation priority · Urgent
Remotely reachable No privileges Zero-click

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
Valve's Source SDK (source-sdk-2013)'s ragdoll model parsing logic contains a stack-based buffer overflow vulnerability.The tokenizer function `nexttoken` copies characters from an input string into a fixed-size stack buffer without performing bounds checks. When `ParseKeyValue` processes a collisionpair rule longer than the destination buffer (256 bytes), an overflow of the stack buffer `szToken` can occur and overwrite the function return address. A remote attacker can trigger the vulnerable code by supplying a specially crafted ragdoll model which causes the oversized collisionpair rule to be parsed, resulting in remote code execution on affected clients or servers. Valve has addressed this issue in many of their Source games, but independently-developed games must manually apply patch.

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

A stack-based buffer overflow exists in the Source SDK 2013's ragdoll model parser. The `nexttoken` function copies collisionpair rule data into a fixed 256-byte stack buffer (`szToken`) without bounds checking. When ParseKeyValue processes a collisionpair rule exceeding 256 bytes, the overflow can overwrite the function return address, enabling remote code execution.

MitigationApply the bounds-checking patch to the `nexttoken` function in the ragdoll parsing code, or update to a Source SDK version that includes the official Valve patch. Verify all custom ragdoll models are from trusted sources.

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

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
Authentication
X
User interaction
None
Scope
X

CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X

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 Source SDK 2013 installation
    Locate the Source SDK 2013 installation directory (commonly in Steam/steamapps/common/SourceSDK or within a game's bin folder). Check for files named source_sdk_2013.exe or version.dll, and identify the build date/version from the file properties.
    Affected if Source SDK 2013 is present and no patch has been applied.
  2. Check Source SDK version
    Compare the installed Source SDK 2013 version against known patched versions. Look at the engine version info in the SDK launcher or the version.dll file properties. Unpatched versions will have older build dates predating the CVE disclosure.
    Affected if The installed version predates the Valve patch for CVE-2017-20205 or version information is unavailable.
  3. Inspect the nexttoken function code
    Locate the ragdoll parsing source file (typically ragdoll.cpp or similar in the source engine code). Search for the `nexttoken` function and verify whether bounds checking (e.g., length validation against 256 bytes) is present on the szToken buffer copy operation.
    Affected if The nexttoken function lacks bounds checking on the szToken buffer (256-byte fixed stack buffer).
  4. Examine custom ragdoll models for collisionpair rules
    If custom ragdoll .mdl files exist, inspect the model data or accompanying text files for collisionpair rules. Look for collisionpair entries with rule data exceeding 256 characters in length.
    Affected if Custom ragdoll models with collisionpair rules longer than 256 bytes are loaded in the environment.
  5. Verify game/mod uses ragdoll physics
    Check if the game or mod built on Source SDK 2013 utilizes ragdoll physics by reviewing the game configuration, map files, or model usage. Examine console logs or mod configuration for ragdoll-related loading messages.
    Affected if The environment loads and parses ragdoll models (the vulnerable code path is only triggered when ragdolls are processed).

A user is affected if Source SDK 2013 with an unpatched version is in use, the vulnerable nexttoken function lacks bounds checking, and the environment loads ragdoll models with collisionpair rules that could exceed 256 bytes.

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.

From vendor data
Mitigation available No clean upgrade yet — mitigate in the meantime
Mitigation

Apply the bounds-checking patch to the `nexttoken` function in the ragdoll parsing code, or update to a Source SDK version that includes the official Valve patch. Verify all custom ragdoll models are from trusted sources.

Have this fixed Scoped from the published advisory
  • Consultation6.0 h
  • Implementation4.0 h
  • Testing8.0 h
  • Review / QA4.0 h
22.0 hours of engineering $3,840
Get help mitigating

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

Scan for this in your stack

Free · runs locally
dbcve dependency scanner

Check whether your project pulls in CVE-2017-20205 — 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-2017-20205 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