CVE-2026-119196
pyasn1: Quadratic CPU consumption in constructed BIT STRING decoding
pyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, constructed BIT STRING decoding repeatedly shifts and copies the complete bit value accumulated from earlier fragments. Attacker-controlled BER or CER input contains many constructed BIT STRING fragments; schema-driven DER also accepts a definite-length constructed BIT STRING. BitStringPayloadDecoder repeatedly calls BitString.fromOctetString with the prior bitString as prepend, shifting an ever-growing SizedInteger for each fragment and causing quadratic work. Large fragmented values can exhaust CPU during decode() without requiring later conversion or formatting. This issue is fixed in version 0.6.5.
Fixes and workarounds
Fix
pyasn1 (PyPI): OSV reports a fixed version 0.6.5. Check the advisory for supported release branches.
Source: OSV GHSA-2qm8-x737-gmw5Affected products and versions
| Product | Versions | Authority |
|---|---|---|
| pyasn1 pyasn1 |
< 0.6.5 (affected) | CNA: GitHub_M |
pyasn1pyasn1
PyPI |
0.0.10a (affected, PyPI) 0.0.11a (affected, PyPI) 0.0.12a (affected, PyPI) 0.0.13 (affected, PyPI) 0.0.13a (affected, PyPI) 0.0.13b (affected, PyPI) 0.0.6a (affected, PyPI) 0.0.9a (affected, PyPI) 0.1.1 (affected, PyPI) 0.1.2 (affected, PyPI) 0.1.3 (affected, PyPI) 0.1.4 (affected, PyPI) 0.1.5 (affected, PyPI) 0.1.6 (affected, PyPI) 0.1.7 (affected, PyPI) 0.1.8 (affected, PyPI) 0.1.9 (affected, PyPI) 0.2.1 (affected, PyPI) 0.2.2 (affected, PyPI) 0.2.3 (affected, PyPI) 0.3.1 (affected, PyPI) 0.3.2 (affected, PyPI) 0.3.3 (affected, PyPI) 0.3.4 (affected, PyPI) 0.3.5 (affected, PyPI) 0.3.6 (affected, PyPI) 0.3.7 (affected, PyPI) 0.4.1 (affected, PyPI) 0.4.2 (affected, PyPI) 0.4.3 (affected, PyPI) 0.4.4 (affected, PyPI) 0.4.5 (affected, PyPI) 0.4.6 (affected, PyPI) 0.4.7 (affected, PyPI) 0.4.8 (affected, PyPI) 0.5.0 (affected, PyPI) 0.5.1 (affected, PyPI) 0.6.0 (affected, PyPI) 0.6.1 (affected, PyPI) 0.6.2 (affected, PyPI) 0.6.3 (affected, PyPI) 0.6.4 (affected, PyPI) Ecosystem version events: introduced 0; fixed 0.6.5 Source events (ECOSYSTEM)
Other versions: unaffected |
OSV GHSA-2qm8-x737-gmw5 |
Version ranges are source assertions. Check the vendor advisory and your installed configuration before determining exposure.
CVSS assessments
| Version / score | Vector | Authority |
|---|---|---|
| 3.1 / 7.5 high |
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | CNA: GitHub_M |
Exploit evidence
- https://github.com/pyasn1/pyasn1/security/advisories/GHSA-2qm8-x737-gmw5
exploit · ADP: CISA-ADP
References
- https://github.com/pyasn1/pyasn1/security/advisories/GHSA-2qm8-x737-gmw5CNA: GitHub_M · x_refsource_CONFIRM
- https://github.com/pyasn1/pyasn1/pull/132CNA: GitHub_M · x_refsource_MISC
- https://github.com/pyasn1/pyasn1/commit/73ba7b043cc7e92cb37f16f2c955bff93b0e6f6cCNA: GitHub_M · x_refsource_MISC
- https://github.com/pyasn1/pyasn1/releases/tag/v0.6.5CNA: GitHub_M · x_refsource_MISC
- https://github.com/pyasn1/pyasn1/security/advisories/GHSA-2qm8-x737-gmw5ADP: CISA-ADP · exploit
- https://github.com/advisories/GHSA-2qm8-x737-gmw5OSV / GitHub Security Advisories · advisory
- https://osv.dev/vulnerability/GHSA-2qm8-x737-gmw5OSV / GitHub Security Advisories · osv
For agents and automation
Read public disclosures for free as Markdown or JSON. Compatible browsers also expose native WebMCP tools to search disclosures, read this page, and discover API access.
Use the ontology-linked Cyber API with x402 pay per request, or a Y2 Pro or Elite API key with the intel:cyber scope.
Endpoints and access details
https://api.y2.dev/api/v2/cyber/cveshttps://api.y2.dev/api/v2/cyber/cves/{cveId}
A workspace owner or admin can create a Pro or Elite API key. Send Authorization: Bearer <Y2_API_KEY> from your trusted agent runtime.
For x402, omit Authorization and read the HTTP 402 payment challenge before signing a retry. Public browser tools do not make payments.