Skip to main content
VulnerabilityPublished

CVE-2025-67125: docopt.cpp · Integer Overflow or Wraparound

Affects docopt.cppSource CVE Database V5

0

Not known to be exploited · CVSS 4.4 Medium.

Data as of 26 Oct 2026, 12:55 UTC

CVSS 3.1 base score
4.4Medium
How severe the flaw is on the 0–10 CVSS scale.
EPSS
0.2% chance of exploitation in 30 days – higher than 14% of CVEsExploit Prediction Scoring System: the likelihood attackers will use this flaw soon.
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:L

Exploitation evidence

  1. Disclosed: evidence found.

    CVE published 23 Jan 2026

  2. Detectable: no evidence on record.

    No public nuclei template indexed

  3. Weaponised: no evidence on record.

    No public exploit code indexed in Metasploit or Exploit-DB

  4. Exploited in the wild: no evidence on record.

    Not in CISA KEV and no source reports exploitation

  5. Observed by OffSeq Mirage: no evidence on record.

    No attack traffic recorded by OffSeq Mirage sensors

A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 26 Oct 2026.

What to do

Affected software

ProductAffectedFixed in
GitHubdocopt/docopt.cpppkg:github/docopt/docopt.cppOther threatsAffected
  • =0.6.2
Fixed in–

Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.

AI-suggested

European organizations should first inventory their software to identify any usage of docopt.cpp version 0.6.2 or earlier. If found, they should upgrade to a patched or newer version of docopt that addresses the integer overflow. In the absence of an official patch, developers should implement input validation and sanitization on occurrence counters to prevent overflow conditions. Employ compiler flags and runtime sanitizers (e.g., UBSan) to detect overflows during testing and development. For hardened builds, prepare for potential process aborts by implementing robust monitoring and automatic recovery mechanisms to minimize downtime. Review and strengthen application logic that depends on occurrence counters to ensure they fail safely and do not allow bypasses. Additionally, consider implementing rate-limiting and safety toggles at multiple layers to reduce reliance on a single vulnerable component. Engage with software suppliers to confirm mitigation plans and monitor for official patches or advisories. Finally, conduct threat modeling and penetration testing focused on command-line argument parsing to identify and remediate similar issues.

Description

A signed integer overflow in docopt.cpp v0.6.2 (LeafPattern::match in docopt_private.h) when merging occurrence counters (e.g., default LONG_MAX + first user "-v/--verbose") can cause counter wrap (negative/unbounded semantics) and lead to logic/policy bypass in applications that rely on occurrence-based limits, rate-gating, or safety toggles. In hardened builds (e.g., UBSan or -ftrapv), the overflow may also result in process abort (DoS).

References

Community reviews

Loading reviews…