{"id":"CVE-2026-119195","aliases":["AZL-111533","DEBIAN-CVE-2026-119195","EUVD-2026-113351","GHSA-9m75-vc3g-4x39","OESA-2026-4786","OESA-2026-4787","OESA-2026-4788","OESA-2026-4789","UBUNTU-CVE-2026-119195","USN-9011-1"],"status":"published","title":"pyasn1: Quadratic-time denial of service in constructed string and indefinite-length ANY decoding","description":"pyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, constructed string and indefinite-length ANY decoding repeatedly concatenates each fragment onto a growing bytes value. Attacker-controlled BER or CER data can use many constructed OCTET STRING or character-string fragments. DER rejects constructed OCTET STRING without a schema, but accepts its definite-length form when asn1Spec selects univ.OctetString; it also accepts constructed character strings such as UTF8String without a schema, even though those encodings are not valid DER. The separate indefinite-length ANY path is reachable in BER and CER when asn1Spec selects univ.Any; DER rejects indefinite lengths. OctetStringPayloadDecoder uses growing header concatenation and AnyPayloadDecoder.indefLenValueDecoder uses growing chunk concatenation, repeatedly copying an increasing prefix and causing quadratic work. A sufficiently fragmented value can occupy decoding workers and cause CPU exhaustion without confidentiality or integrity impact. This issue is fixed in version 0.6.5.","severity":{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","level":"high","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-12","score":0.00527,"percentile":0.45124,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-407"],"published":"2026-10-29T19:41:37Z","modified":"2026-11-11T12:45:11Z","fixes":[{"ecosystem":"PyPI","package":"pyasn1","fixed_in":["0.6.5"],"sources":["ghsa","osv"]},{"ecosystem":"Debian:14","package":"pyasn1","fixed_in":["0.6.5-1"],"sources":["osv"]},{"ecosystem":"Ubuntu:26.10","package":"pyasn1","fixed_in":["0.6.4-1ubuntu0.1"],"sources":["osv"]},{"ecosystem":"Ubuntu:26.04:LTS","package":"pyasn1","fixed_in":["0.6.3-1ubuntu0.2"],"sources":["osv"]}],"affected":[{"source":"ghsa","ecosystem":"PyPI","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"last_affected":"0.6.4"},{"fixed":"0.6.5"}]}]},{"source":"osv","ecosystem":"Azure Linux:3","package":"python-pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"last_affected":"0.4.8-3"}]}]},{"source":"osv","ecosystem":"Debian:12","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["0.4.8-3","0.4.8-3+deb12u1","0.4.8-3+deb12u2","0.4.8-3+deb12u3","0.4.8-4","0.5.1-1","0.6.0-1","0.6.1-1","0.6.2-1","0.6.2-1~bpo13+1","0.6.3-1","0.6.4-1","0.6.4-1~bpo13+1","0.6.5-1"]},{"source":"osv","ecosystem":"Debian:13","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["0.6.1-1","0.6.1-1+deb13u1","0.6.1-1+deb13u2","0.6.1-1+deb13u3","0.6.2-1","0.6.2-1~bpo13+1","0.6.3-1","0.6.4-1","0.6.4-1~bpo13+1","0.6.5-1"]},{"source":"osv","ecosystem":"Debian:14","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.6.5-1"}]}],"versions":["0.6.1-1","0.6.2-1","0.6.2-1~bpo13+1","0.6.3-1","0.6.4-1","0.6.4-1~bpo13+1"]},{"source":"osv","ecosystem":"PyPI","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.6.5"}]}],"versions":["0.0.10a","0.0.11a","0.0.12a","0.0.13","0.0.13a","0.0.13b","0.0.6a","0.0.9a","0.1.1","0.1.2","0.1.3","0.1.4","0.1.5","0.1.6","0.1.7","0.1.8","0.1.9","0.2.1","0.2.2","0.2.3","0.3.1","0.3.2","0.3.3","0.3.4","0.3.5","0.3.6","0.3.7","0.4.1","0.4.2","0.4.3","0.4.4","0.4.5","0.4.6","0.4.7","0.4.8","0.5.0","0.5.1","0.6.0","0.6.1","0.6.2","0.6.3","0.6.4"]},{"source":"osv","ecosystem":"openEuler:24.03-LTS-SP1","package":"python-pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.5.1-5.oe2403sp1"}]}],"bundled":4},{"source":"osv","ecosystem":"openEuler:24.03-LTS-SP3","package":"python-pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.5.1-5.oe2403sp3"}]}],"bundled":4},{"source":"osv","ecosystem":"openEuler:24.03-LTS-SP4","package":"python-pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.5.1-5.oe2403sp4"}]}],"bundled":4},{"source":"osv","ecosystem":"openEuler:22.03-LTS-SP4","package":"python-pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.4.8-8.oe2203sp4"}]}],"bundled":4},{"source":"osv","ecosystem":"Ubuntu:Pro:14.04:LTS","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["0.1.4-0ubuntu1","0.1.7-1ubuntu1","0.1.7-1ubuntu2","0.1.7-1ubuntu2.1","0.1.7-1ubuntu2.1+esm1","0.1.7-1ubuntu2.1+esm2"]},{"source":"osv","ecosystem":"Ubuntu:Pro:16.04:LTS","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["0.1.8-2","0.1.9-1","0.1.9-1ubuntu0.1~esm1","0.1.9-1ubuntu0.1~esm2"]},{"source":"osv","ecosystem":"Ubuntu:Pro:18.04:LTS","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["0.1.9-2","0.4.2-3","0.4.2-3ubuntu0.18.04.1~esm1","0.4.2-3ubuntu0.18.04.1~esm2"]},{"source":"osv","ecosystem":"Ubuntu:Pro:20.04:LTS","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["0.4.2-3","0.4.2-3build1","0.4.2-3ubuntu0.20.04.1~esm1","0.4.2-3ubuntu0.20.04.1~esm2"]},{"source":"osv","ecosystem":"Ubuntu:22.04:LTS","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["0.4.8-1","0.4.8-1ubuntu0.1","0.4.8-1ubuntu0.2","0.4.8-1ubuntu0.3","0.4.8-1ubuntu0.4"]},{"source":"osv","ecosystem":"Ubuntu:24.04:LTS","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["0.4.8-4","0.4.8-4ubuntu0.1","0.4.8-4ubuntu0.2","0.4.8-4ubuntu0.3","0.4.8-4ubuntu0.4"]},{"source":"osv","ecosystem":"Ubuntu:26.10","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.6.4-1ubuntu0.1"}]}],"versions":["0.6.3-1","0.6.4-1"]},{"source":"osv","ecosystem":"Ubuntu:26.04:LTS","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.6.3-1ubuntu0.2"}]}],"versions":["0.6.1-1","0.6.1-1build1","0.6.2-1","0.6.3-1","0.6.3-1ubuntu0.1"]},{"source":"osv","ecosystem":"Ubuntu:Pro:14.04:LTS","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.1.7-1ubuntu2.1+esm2"}]}],"versions":["0.1.4-0ubuntu1","0.1.7-1ubuntu1","0.1.7-1ubuntu2","0.1.7-1ubuntu2.1","0.1.7-1ubuntu2.1+esm1"],"bundled":7},{"source":"osv","ecosystem":"Ubuntu:Pro:16.04:LTS","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.1.9-1ubuntu0.1~esm2"}]}],"versions":["0.1.8-2","0.1.9-1","0.1.9-1ubuntu0.1~esm1"],"bundled":7},{"source":"osv","ecosystem":"Ubuntu:Pro:18.04:LTS","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.4.2-3ubuntu0.18.04.1~esm2"}]}],"versions":["0.1.9-2","0.4.2-3","0.4.2-3ubuntu0.18.04.1~esm1"],"bundled":7},{"source":"osv","ecosystem":"Ubuntu:Pro:20.04:LTS","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.4.2-3ubuntu0.20.04.1~esm2"}]}],"versions":["0.4.2-3","0.4.2-3build1","0.4.2-3ubuntu0.20.04.1~esm1"],"bundled":7},{"source":"osv","ecosystem":"Ubuntu:22.04:LTS","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.4.8-1ubuntu0.4"}]}],"versions":["0.4.8-1","0.4.8-1ubuntu0.1","0.4.8-1ubuntu0.2","0.4.8-1ubuntu0.3"],"bundled":7},{"source":"osv","ecosystem":"Ubuntu:24.04:LTS","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.4.8-4ubuntu0.4"}]}],"versions":["0.4.8-4","0.4.8-4ubuntu0.1","0.4.8-4ubuntu0.2","0.4.8-4ubuntu0.3"],"bundled":7},{"source":"osv","ecosystem":"Ubuntu:26.10","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.6.4-1ubuntu0.1"}]}],"versions":["0.6.3-1","0.6.4-1"],"bundled":7},{"source":"osv","ecosystem":"Ubuntu:26.04:LTS","package":"pyasn1","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.6.3-1ubuntu0.2"}]}],"versions":["0.6.1-1","0.6.1-1build1","0.6.2-1","0.6.3-1","0.6.3-1ubuntu0.1"],"bundled":7}],"products":[{"vendor":"pyasn1","product":"pyasn1"}],"references":[{"url":"https://github.com/pyasn1/pyasn1/security/advisories/GHSA-9m75-vc3g-4x39","tags":["x_refsource_CONFIRM","exploit","advisory","web","report"]},{"url":"https://github.com/pyasn1/pyasn1/pull/132","tags":["x_refsource_MISC","fix","web","report"]},{"url":"https://github.com/pyasn1/pyasn1/commit/4ce00797c594b59c1fd6b86d9ebc3ba87b7ec9f9","tags":["x_refsource_MISC","fix","web","report"]},{"url":"https://github.com/pyasn1/pyasn1/releases/tag/v0.6.5","tags":["x_refsource_MISC","web","report"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-119195","tags":["web","advisory"]},{"url":"https://github.com/advisories/GHSA-9m75-vc3g-4x39"},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/119xxx/CVE-2026-119195.json","tags":["advisory"]},{"url":"https://security-tracker.debian.org/tracker/CVE-2026-119195","tags":["advisory"]},{"url":"https://github.com/pyasn1/pyasn1","tags":["package"]},{"url":"https://www.openeuler.org/zh/security/security-bulletins/detail/?id=openEuler-SA-2026-4786","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-119194","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-119196","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-119197","tags":["advisory"]},{"url":"https://www.openeuler.org/zh/security/security-bulletins/detail/?id=openEuler-SA-2026-4787","tags":["advisory"]},{"url":"https://www.openeuler.org/zh/security/security-bulletins/detail/?id=openEuler-SA-2026-4788","tags":["advisory"]},{"url":"https://www.openeuler.org/zh/security/security-bulletins/detail/?id=openEuler-SA-2026-4789","tags":["advisory"]},{"url":"https://ubuntu.com/security/CVE-2026-119195","tags":["report"]},{"url":"https://www.cve.org/CVERecord?id=CVE-2026-119195","tags":["report"]},{"url":"https://ubuntu.com/security/notices/USN-9011-1","tags":["advisory"]},{"url":"https://ubuntu.com/security/CVE-2026-59884","tags":["report"]},{"url":"https://ubuntu.com/security/CVE-2026-59885","tags":["report"]},{"url":"https://ubuntu.com/security/CVE-2026-59886","tags":["report"]},{"url":"https://ubuntu.com/security/CVE-2026-119194","tags":["report"]},{"url":"https://ubuntu.com/security/CVE-2026-119196","tags":["report"]},{"url":"https://ubuntu.com/security/CVE-2026-119197","tags":["report"]}],"sources":{"cve":[{"id":"CVE-2026-119195","title":"pyasn1: Quadratic-time denial of service in constructed string and indefinite-length ANY decoding","description":"pyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, constructed string and indefinite-length ANY decoding repeatedly concatenates each fragment onto a growing bytes value. Attacker-controlled BER or CER data can use many constructed OCTET STRING or character-string fragments. DER rejects constructed OCTET STRING without a schema, but accepts its definite-length form when asn1Spec selects univ.OctetString; it also accepts constructed character strings such as UTF8String without a schema, even though those encodings are not valid DER. The separate indefinite-length ANY path is reachable in BER and CER when asn1Spec selects univ.Any; DER rejects indefinite lengths. OctetStringPayloadDecoder uses growing header concatenation and AnyPayloadDecoder.indefLenValueDecoder uses growing chunk concatenation, repeatedly copying an increasing prefix and causing quadratic work. A sufficiently fragmented value can occupy decoding workers and cause CPU exhaustion without confidentiality or integrity impact. This issue is fixed in version 0.6.5.","status":"published","published":"2026-10-29T19:41:37.352Z","modified":"2026-10-29T20:26:31.801Z","cvss":[{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","level":"high","assessor":"cna"}],"cwes":["CWE-407"],"updated_at":"2026-11-02T14:20:10.143031Z"}],"euvd":[{"id":"EUVD-2026-113351","description":"pyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, constructed string and indefinite-length ANY decoding repeatedly concatenates each fragment onto a growing bytes value. Attacker-controlled BER or CER data can use many constructed OCTET STRING or character-string fragments. DER rejects constructed OCTET STRING without a schema, but accepts its definite-length form when asn1Spec selects univ.OctetString; it also accepts constructed character strings such as UTF8String without a schema, even though those encodings are not valid DER. The separate indefinite-length ANY path is reachable in BER and CER when asn1Spec selects univ.Any; DER rejects indefinite lengths. OctetStringPayloadDecoder uses growing header concatenation and AnyPayloadDecoder.indefLenValueDecoder uses growing chunk concatenation, repeatedly copying an increasing prefix and causing quadratic work. A sufficiently fragmented value can occupy decoding workers and cause CPU exhaustion without confidentiality or integrity impact. This issue is fixed in version 0.6.5.","status":"published","published":"2026-10-29T19:41:37Z","modified":"2026-10-29T20:26:31Z","cvss":[{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","level":"high"}],"updated_at":"2026-11-02T16:59:14.591479Z"}],"ghsa":[{"id":"GHSA-9m75-vc3g-4x39","title":"pyasn1 has quadratic-time denial of service in constructed string and indefinite-length ANY decoding","description":"## Summary\n\nIn pyasn1 0.6.4 and earlier, decoding a constructed OCTET STRING or character string made of many fragments can spend disproportionate CPU time repeatedly copying the accumulated value. A separate indefinite-length `ANY` path has the same problem while collecting the encoded components. The work grows roughly quadratically with the number of fixed-size fragments, although the input and decoded value grow linearly. An application that lets an attacker supply such ASN.1 input to an affected decoder can suffer CPU exhaustion.\n\nThe affected string paths are available in BER and CER. The DER decoder also accepts certain *non-DER* constructed strings: a definite-length constructed OCTET STRING when an `asn1Spec` selects `univ.OctetString`, and constructed character strings such as UTF8String even without a schema. Indefinite-length `ANY` is affected in BER and CER when an `asn1Spec` selects `univ.Any`; DER rejects indefinite lengths.\n\nThis is a distinct decoder path from the OBJECT IDENTIFIER/RELATIVE-OID accumulation addressed by [CVE-2026-59885](https://github.com/advisories/GHSA-8ppf-4f7h-5ppj). It has the same complexity class, but the OID fix in 0.6.4 did not change these string or `ANY` loops.\n\n## Technical details\n\nIn the [v0.6.4 BER decoder](https://github.com/pyasn1/pyasn1/blob/v0.6.4/pyasn1/codec/ber/decoder.py), `OctetStringPayloadDecoder` appends each decoded fragment to a growing `bytes` value with `header += component` in both its [definite-length](https://github.com/pyasn1/pyasn1/blob/v0.6.4/pyasn1/codec/ber/decoder.py#L338-L351) and [indefinite-length](https://github.com/pyasn1/pyasn1/blob/v0.6.4/pyasn1/codec/ber/decoder.py#L368-L387) constructed forms. [`AnyPayloadDecoder.indefLenValueDecoder`](https://github.com/pyasn1/pyasn1/blob/v0.6.4/pyasn1/codec/ber/decoder.py#L1403-L1430) similarly uses `chunk += component`. In the exercised paths, each concatenation copies an increasingly large prefix. For `N` fixed-size fragments, the total copied data grows with `1 + 2 + ... + N`, or O(N²).\n\nThe OCTET STRING decoder is also the base class of the decoders for UTF8String, NumericString, PrintableString, TeletexString, VideotexString, IA5String, GraphicString, VisibleString, GeneralString, UniversalString, BMPString, ObjectDescriptor, GeneralizedTime, and UTCTime. These types inherit the same constructed-string reassembly path.\n\nThe [DER decoder's OCTET STRING restriction](https://github.com/pyasn1/pyasn1/blob/v0.6.4/pyasn1/codec/der/decoder.py#L15-L49) replaces the tag-driven decoder, but its schema-driven `TYPE_MAP` retains the BER-derived decoder. Thus `der.decode(data)` rejects a constructed OCTET STRING, while `der.decode(data, asn1Spec=univ.OctetString())` accepts its definite-length form and reaches the accumulation loop. DER does not replace the inherited character-string decoders, so a constructed UTF8String is also accepted without `asn1Spec`. These inputs violate [X.690's DER string-encoding rule](https://www.itu.int/rec/T-REC-X.690-202102-I/en) and should not be described as valid DER encodings.\n\nThe original short-fragment, definite-length OCTET STRING reproducer is valid BER. The CER decoder accepts it, but it is not a conforming CER string encoding: X.690 requires an indefinite-length outer constructed string and 1,000 contents octets per fragment except possibly the last. A conforming CER-shaped constructed OCTET STRING with those fragment sizes also reaches the loop and shows quadratic growth. The indefinite-length `ANY` reproducer below can represent a CER `SEQUENCE OF OCTET STRING` and reaches the separate `ANY` loop when decoded with an `ANY` schema.\n\nThe decoder's eight-octet length-field limit and nesting-depth limit do not bound the number of sibling fragments in these examples. The BER reproducer below uses only a three-octet outer length field; all fragments have shallow nesting. There is no per-message fragment-count cap in v0.6.4.\n\n## Impact\n\nIf an application passes attacker-controlled ASN.1 to the affected `decode()` or `StreamingDecoder` path without an adequate input or resource limit, a megabyte-scale value can occupy a decoding worker for seconds. Repeated inputs can exhaust available CPU. Whether this is reachable before authentication, or through a particular protocol, depends on the application; the library finding alone does not establish those conditions. No confidentiality or integrity impact is claimed.\n\n## Severity assessment (CVSS v3.1)\n\nThe 7.5 Base score assumes a reasonable application that automatically decodes attacker-supplied ASN.1 from unauthenticated network input. Valid BER and conforming CER inputs trigger the string-reassembly issue without special conditions, privileges, or user interaction. Repeated crafted inputs could occupy all available decoder workers and deny service while the attack continues. No confidentiality or integrity impact is demonstrated. This library-level score does not assert that every adopter has such an endpoint or loses all service; deployment-specific input limits and architecture may change the score. See [FIRST's library-scoring guidance](https://www.first.org/cvss/v3-1/user-guide).\n\nOn the official v0.6.4 tag, local CPU-time measurements with CPython 3.14.8 on macOS arm64 gave the following results. Times vary by machine and Python runtime; the input-size scaling is the relevant observation. “Fixed” means the local 0.6.5 decoder fix applied to the same inputs.\n\n| Decoder path and input | Fragments | v0.6.4 CPU | Fixed CPU |\n| --- | ---: | ---: | ---: |\n| BER constructed OCTET STRING, 0.40 MB | 100,000 × 2 payload bytes | 0.340 s | 0.160 s |\n| BER constructed OCTET STRING, 0.80 MB | 200,000 × 2 payload bytes | 0.886 s | 0.312 s |\n| BER constructed OCTET STRING, 1.60 MB | 400,000 × 2 payload bytes | 2.738 s | 0.623 s |\n| BER indefinite `ANY`, 0.30 MB | 100,000 × 1 payload byte | 0.459 s | 0.206 s |\n| BER indefinite `ANY`, 0.60 MB | 200,000 × 1 payload byte | 1.245 s | 0.412 s |\n| BER indefinite `ANY`, 1.20 MB | 400,000 × 1 payload byte | 3.980 s | 0.826 s |\n| CER constructed OCTET STRING, 1.00 MB, conforming fragment layout | 1,000 × 1,000 payload bytes | 0.0089 s | 0.0022 s |\n| CER constructed OCTET STRING, 2.01 MB, conforming fragment layout | 2,000 × 1,000 payload bytes | 0.0311 s | 0.0044 s |\n| CER constructed OCTET STRING, 4.02 MB, conforming fragment layout | 4,000 × 1,000 payload bytes | 0.1379 s | 0.0090 s |\n\nFor the same short-fragment layout, the original report measured up to 16.05 seconds for a 3.2 MB BER constructed OCTET STRING. An independent report on CPython 3.11.16/Linux measured 5.76 seconds for a 2.4 MB constructed OCTET STRING, versus about 0.005 seconds for a primitive OCTET STRING of comparable size. These are reporter measurements on different systems, not fixed performance guarantees.\n\n## Reproduction\n\nThis example uses public decoder APIs. Run it with pyasn1 0.6.4 and increase `n` to observe the scaling. The final two calls show the DER paths accepted by v0.6.4; their constructed encodings are not valid DER.\n\n```python\nimport time\n\nfrom pyasn1.codec.ber import decoder as ber\nfrom pyasn1.codec.cer import decoder as cer\nfrom pyasn1.codec.der import decoder as der\nfrom pyasn1.type import univ\n\n\ndef tlv(identifier, contents):\n    length = len(contents)\n    if length \u003c 128:\n        return bytes((identifier, length)) + contents\n    encoded = length.to_bytes((length.bit_length() + 7) // 8, \"big\")\n    return bytes((identifier, 0x80 | len(encoded))) + encoded + contents\n\n\ndef measure(label, decode, substrate, asn1Spec=None):\n    start = time.process_time()\n    _, rest = decode(substrate, asn1Spec=asn1Spec)\n    assert not rest\n    print(f\"{label}: {len(substrate)} input bytes, \"\n          f\"{time.process_time() - start:.3f} CPU seconds\")\n\n\nn = 100_000\noctet_fragments = b\"\\x04\\x02AA\" * n\nutf8_fragments = b\"\\x0c\\x02AA\" * n\n\nmeasure(\"BER constructed OCTET STRING\", ber.decode,\n        tlv(0x24, octet_fragments))\nmeasure(\"BER indefinite ANY\", ber.decode,\n        b\"\\x30\\x80\" + b\"\\x04\\x01A\" * n + b\"\\x00\\x00\",\n        univ.Any())\n\n# CER uses indefinite length and 1,000-content-octet primitive fragments.\ncer_fragment = tlv(0x04, b\"A\" * 1000)\nmeasure(\"CER constructed OCTET STRING\", cer.decode,\n        b\"\\x24\\x80\" + cer_fragment * 1000 + b\"\\x00\\x00\")\n\n# These constructed encodings are accepted by pyasn1 but are invalid DER.\nmeasure(\"DER OCTET STRING with schema\", der.decode,\n        tlv(0x24, octet_fragments), univ.OctetString())\nmeasure(\"DER UTF8String without schema\", der.decode,\n        tlv(0x2c, utf8_fragments))\n```\n\n## Patch\n\npyasn1 0.6.5 replaces the growing `bytes` accumulator with a list of fragments and joins them once after decoding in all three affected loops. The OCTET STRING base-class change also covers the inheriting character-string decoders. This removes the repeated copying while preserving the assembled decoded value.\n\n## Workaround\n\nUntil upgrading, enforce application-appropriate limits on the size of untrusted ASN.1 input *before* passing it to pyasn1, and limit the CPU resources available to decoding workers. Applications that require DER can also reject constructed string encodings before invoking the decoder. The appropriate byte limit depends on the protocol and expected valid values.\n\n## Credits and references\n\nReported by [alimony](https://github.com/alimony). Independently reported by [manus-pi](https://github.com/manus-pi), whose report identified the schema-driven DER route, inherited character-string decoders, and additional performance evidence.\n\n- [pyasn1 v0.6.4 affected decoder source](https://github.com/pyasn1/pyasn1/blob/v0.6.4/pyasn1/codec/ber/decoder.py)\n- [ITU-T X.690, CER and DER string-encoding rules](https://www.itu.int/rec/T-REC-X.690-202102-I/en)\n- [CVE-2026-59885, separate OID decoder issue](https://github.com/advisories/GHSA-8ppf-4f7h-5ppj)","status":"published","published":"2026-10-30T23:03:51Z","modified":"2026-10-30T23:03:54Z","cvss":[{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","level":"high"}],"cwes":["CWE-407"],"updated_at":"2026-11-02T14:41:42.013329Z"}],"nvd":[{"id":"CVE-2026-119195","description":"pyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, constructed string and indefinite-length ANY decoding repeatedly concatenates each fragment onto a growing bytes value. Attacker-controlled BER or CER data can use many constructed OCTET STRING or character-string fragments. DER rejects constructed OCTET STRING without a schema, but accepts its definite-length form when asn1Spec selects univ.OctetString; it also accepts constructed character strings such as UTF8String without a schema, even though those encodings are not valid DER. The separate indefinite-length ANY path is reachable in BER and CER when asn1Spec selects univ.Any; DER rejects indefinite lengths. OctetStringPayloadDecoder uses growing header concatenation and AnyPayloadDecoder.indefLenValueDecoder uses growing chunk concatenation, repeatedly copying an increasing prefix and causing quadratic work. A sufficiently fragmented value can occupy decoding workers and cause CPU exhaustion without confidentiality or integrity impact. This issue is fixed in version 0.6.5.","status":"published","published":"2026-10-29T20:17:30.633Z","modified":"2026-10-30T17:18:03.88Z","cvss":[{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","level":"high","assessor":"secondary"}],"cwes":["CWE-407"],"updated_at":"2026-11-02T14:13:04.940026Z"}],"osv":[{"id":"CVE-2026-119195","title":"pyasn1: Quadratic-time denial of service in constructed string and indefinite-length ANY decoding","description":"pyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, constructed string and indefinite-length ANY decoding repeatedly concatenates each fragment onto a growing bytes value. Attacker-controlled BER or CER data can use many constructed OCTET STRING or character-string fragments. DER rejects constructed OCTET STRING without a schema, but accepts its definite-length form when asn1Spec selects univ.OctetString; it also accepts constructed character strings such as UTF8String without a schema, even though those encodings are not valid DER. The separate indefinite-length ANY path is reachable in BER and CER when asn1Spec selects univ.Any; DER rejects indefinite lengths. OctetStringPayloadDecoder uses growing header concatenation and AnyPayloadDecoder.indefLenValueDecoder uses growing chunk concatenation, repeatedly copying an increasing prefix and causing quadratic work. A sufficiently fragmented value can occupy decoding workers and cause CPU exhaustion without confidentiality or integrity impact. This issue is fixed in version 0.6.5.","status":"published","published":"2026-10-29T19:41:37.352Z","modified":"2026-11-01T02:47:27.236976326Z","cvss":[{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","level":"high"}],"cwes":["CWE-407"],"updated_at":"2026-11-02T15:44:57.008854Z"},{"id":"DEBIAN-CVE-2026-119195","description":"pyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, constructed string and indefinite-length ANY decoding repeatedly concatenates each fragment onto a growing bytes value. Attacker-controlled BER or CER data can use many constructed OCTET STRING or character-string fragments. DER rejects constructed OCTET STRING without a schema, but accepts its definite-length form when asn1Spec selects univ.OctetString; it also accepts constructed character strings such as UTF8String without a schema, even though those encodings are not valid DER. The separate indefinite-length ANY path is reachable in BER and CER when asn1Spec selects univ.Any; DER rejects indefinite lengths. OctetStringPayloadDecoder uses growing header concatenation and AnyPayloadDecoder.indefLenValueDecoder uses growing chunk concatenation, repeatedly copying an increasing prefix and causing quadratic work. A sufficiently fragmented value can occupy decoding workers and cause CPU exhaustion without confidentiality or integrity impact. This issue is fixed in version 0.6.5.","status":"published","published":"2026-10-29T20:17:30.633Z","modified":"2026-11-03T10:00:20.075361034Z","cvss":[{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","level":"high"}],"updated_at":"2026-11-03T10:27:58.933618Z"},{"id":"GHSA-9m75-vc3g-4x39","title":"pyasn1 has quadratic-time denial of service in constructed string and indefinite-length ANY decoding","description":"## Summary\n\nIn pyasn1 0.6.4 and earlier, decoding a constructed OCTET STRING or character string made of many fragments can spend disproportionate CPU time repeatedly copying the accumulated value. A separate indefinite-length `ANY` path has the same problem while collecting the encoded components. The work grows roughly quadratically with the number of fixed-size fragments, although the input and decoded value grow linearly. An application that lets an attacker supply such ASN.1 input to an affected decoder can suffer CPU exhaustion.\n\nThe affected string paths are available in BER and CER. The DER decoder also accepts certain *non-DER* constructed strings: a definite-length constructed OCTET STRING when an `asn1Spec` selects `univ.OctetString`, and constructed character strings such as UTF8String even without a schema. Indefinite-length `ANY` is affected in BER and CER when an `asn1Spec` selects `univ.Any`; DER rejects indefinite lengths.\n\nThis is a distinct decoder path from the OBJECT IDENTIFIER/RELATIVE-OID accumulation addressed by [CVE-2026-59885](https://github.com/advisories/GHSA-8ppf-4f7h-5ppj). It has the same complexity class, but the OID fix in 0.6.4 did not change these string or `ANY` loops.\n\n## Technical details\n\nIn the [v0.6.4 BER decoder](https://github.com/pyasn1/pyasn1/blob/v0.6.4/pyasn1/codec/ber/decoder.py), `OctetStringPayloadDecoder` appends each decoded fragment to a growing `bytes` value with `header += component` in both its [definite-length](https://github.com/pyasn1/pyasn1/blob/v0.6.4/pyasn1/codec/ber/decoder.py#L338-L351) and [indefinite-length](https://github.com/pyasn1/pyasn1/blob/v0.6.4/pyasn1/codec/ber/decoder.py#L368-L387) constructed forms. [`AnyPayloadDecoder.indefLenValueDecoder`](https://github.com/pyasn1/pyasn1/blob/v0.6.4/pyasn1/codec/ber/decoder.py#L1403-L1430) similarly uses `chunk += component`. In the exercised paths, each concatenation copies an increasingly large prefix. For `N` fixed-size fragments, the total copied data grows with `1 + 2 + ... + N`, or O(N²).\n\nThe OCTET STRING decoder is also the base class of the decoders for UTF8String, NumericString, PrintableString, TeletexString, VideotexString, IA5String, GraphicString, VisibleString, GeneralString, UniversalString, BMPString, ObjectDescriptor, GeneralizedTime, and UTCTime. These types inherit the same constructed-string reassembly path.\n\nThe [DER decoder's OCTET STRING restriction](https://github.com/pyasn1/pyasn1/blob/v0.6.4/pyasn1/codec/der/decoder.py#L15-L49) replaces the tag-driven decoder, but its schema-driven `TYPE_MAP` retains the BER-derived decoder. Thus `der.decode(data)` rejects a constructed OCTET STRING, while `der.decode(data, asn1Spec=univ.OctetString())` accepts its definite-length form and reaches the accumulation loop. DER does not replace the inherited character-string decoders, so a constructed UTF8String is also accepted without `asn1Spec`. These inputs violate [X.690's DER string-encoding rule](https://www.itu.int/rec/T-REC-X.690-202102-I/en) and should not be described as valid DER encodings.\n\nThe original short-fragment, definite-length OCTET STRING reproducer is valid BER. The CER decoder accepts it, but it is not a conforming CER string encoding: X.690 requires an indefinite-length outer constructed string and 1,000 contents octets per fragment except possibly the last. A conforming CER-shaped constructed OCTET STRING with those fragment sizes also reaches the loop and shows quadratic growth. The indefinite-length `ANY` reproducer below can represent a CER `SEQUENCE OF OCTET STRING` and reaches the separate `ANY` loop when decoded with an `ANY` schema.\n\nThe decoder's eight-octet length-field limit and nesting-depth limit do not bound the number of sibling fragments in these examples. The BER reproducer below uses only a three-octet outer length field; all fragments have shallow nesting. There is no per-message fragment-count cap in v0.6.4.\n\n## Impact\n\nIf an application passes attacker-controlled ASN.1 to the affected `decode()` or `StreamingDecoder` path without an adequate input or resource limit, a megabyte-scale value can occupy a decoding worker for seconds. Repeated inputs can exhaust available CPU. Whether this is reachable before authentication, or through a particular protocol, depends on the application; the library finding alone does not establish those conditions. No confidentiality or integrity impact is claimed.\n\n## Severity assessment (CVSS v3.1)\n\nThe 7.5 Base score assumes a reasonable application that automatically decodes attacker-supplied ASN.1 from unauthenticated network input. Valid BER and conforming CER inputs trigger the string-reassembly issue without special conditions, privileges, or user interaction. Repeated crafted inputs could occupy all available decoder workers and deny service while the attack continues. No confidentiality or integrity impact is demonstrated. This library-level score does not assert that every adopter has such an endpoint or loses all service; deployment-specific input limits and architecture may change the score. See [FIRST's library-scoring guidance](https://www.first.org/cvss/v3-1/user-guide).\n\nOn the official v0.6.4 tag, local CPU-time measurements with CPython 3.14.8 on macOS arm64 gave the following results. Times vary by machine and Python runtime; the input-size scaling is the relevant observation. “Fixed” means the local 0.6.5 decoder fix applied to the same inputs.\n\n| Decoder path and input | Fragments | v0.6.4 CPU | Fixed CPU |\n| --- | ---: | ---: | ---: |\n| BER constructed OCTET STRING, 0.40 MB | 100,000 × 2 payload bytes | 0.340 s | 0.160 s |\n| BER constructed OCTET STRING, 0.80 MB | 200,000 × 2 payload bytes | 0.886 s | 0.312 s |\n| BER constructed OCTET STRING, 1.60 MB | 400,000 × 2 payload bytes | 2.738 s | 0.623 s |\n| BER indefinite `ANY`, 0.30 MB | 100,000 × 1 payload byte | 0.459 s | 0.206 s |\n| BER indefinite `ANY`, 0.60 MB | 200,000 × 1 payload byte | 1.245 s | 0.412 s |\n| BER indefinite `ANY`, 1.20 MB | 400,000 × 1 payload byte | 3.980 s | 0.826 s |\n| CER constructed OCTET STRING, 1.00 MB, conforming fragment layout | 1,000 × 1,000 payload bytes | 0.0089 s | 0.0022 s |\n| CER constructed OCTET STRING, 2.01 MB, conforming fragment layout | 2,000 × 1,000 payload bytes | 0.0311 s | 0.0044 s |\n| CER constructed OCTET STRING, 4.02 MB, conforming fragment layout | 4,000 × 1,000 payload bytes | 0.1379 s | 0.0090 s |\n\nFor the same short-fragment layout, the original report measured up to 16.05 seconds for a 3.2 MB BER constructed OCTET STRING. An independent report on CPython 3.11.16/Linux measured 5.76 seconds for a 2.4 MB constructed OCTET STRING, versus about 0.005 seconds for a primitive OCTET STRING of comparable size. These are reporter measurements on different systems, not fixed performance guarantees.\n\n## Reproduction\n\nThis example uses public decoder APIs. Run it with pyasn1 0.6.4 and increase `n` to observe the scaling. The final two calls show the DER paths accepted by v0.6.4; their constructed encodings are not valid DER.\n\n```python\nimport time\n\nfrom pyasn1.codec.ber import decoder as ber\nfrom pyasn1.codec.cer import decoder as cer\nfrom pyasn1.codec.der import decoder as der\nfrom pyasn1.type import univ\n\n\ndef tlv(identifier, contents):\n    length = len(contents)\n    if length \u003c 128:\n        return bytes((identifier, length)) + contents\n    encoded = length.to_bytes((length.bit_length() + 7) // 8, \"big\")\n    return bytes((identifier, 0x80 | len(encoded))) + encoded + contents\n\n\ndef measure(label, decode, substrate, asn1Spec=None):\n    start = time.process_time()\n    _, rest = decode(substrate, asn1Spec=asn1Spec)\n    assert not rest\n    print(f\"{label}: {len(substrate)} input bytes, \"\n          f\"{time.process_time() - start:.3f} CPU seconds\")\n\n\nn = 100_000\noctet_fragments = b\"\\x04\\x02AA\" * n\nutf8_fragments = b\"\\x0c\\x02AA\" * n\n\nmeasure(\"BER constructed OCTET STRING\", ber.decode,\n        tlv(0x24, octet_fragments))\nmeasure(\"BER indefinite ANY\", ber.decode,\n        b\"\\x30\\x80\" + b\"\\x04\\x01A\" * n + b\"\\x00\\x00\",\n        univ.Any())\n\n# CER uses indefinite length and 1,000-content-octet primitive fragments.\ncer_fragment = tlv(0x04, b\"A\" * 1000)\nmeasure(\"CER constructed OCTET STRING\", cer.decode,\n        b\"\\x24\\x80\" + cer_fragment * 1000 + b\"\\x00\\x00\")\n\n# These constructed encodings are accepted by pyasn1 but are invalid DER.\nmeasure(\"DER OCTET STRING with schema\", der.decode,\n        tlv(0x24, octet_fragments), univ.OctetString())\nmeasure(\"DER UTF8String without schema\", der.decode,\n        tlv(0x2c, utf8_fragments))\n```\n\n## Patch\n\npyasn1 0.6.5 replaces the growing `bytes` accumulator with a list of fragments and joins them once after decoding in all three affected loops. The OCTET STRING base-class change also covers the inheriting character-string decoders. This removes the repeated copying while preserving the assembled decoded value.\n\n## Workaround\n\nUntil upgrading, enforce application-appropriate limits on the size of untrusted ASN.1 input *before* passing it to pyasn1, and limit the CPU resources available to decoding workers. Applications that require DER can also reject constructed string encodings before invoking the decoder. The appropriate byte limit depends on the protocol and expected valid values.\n\n## Credits and references\n\nReported by [alimony](https://github.com/alimony). Independently reported by [manus-pi](https://github.com/manus-pi), whose report identified the schema-driven DER route, inherited character-string decoders, and additional performance evidence.\n\n- [pyasn1 v0.6.4 affected decoder source](https://github.com/pyasn1/pyasn1/blob/v0.6.4/pyasn1/codec/ber/decoder.py)\n- [ITU-T X.690, CER and DER string-encoding rules](https://www.itu.int/rec/T-REC-X.690-202102-I/en)\n- [CVE-2026-59885, separate OID decoder issue](https://github.com/advisories/GHSA-8ppf-4f7h-5ppj)","status":"published","published":"2026-10-30T23:03:51Z","modified":"2026-10-30T23:15:07.377922369Z","cvss":[{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","level":"high"}],"cwes":["CWE-407"],"updated_at":"2026-11-02T15:46:43.875515Z"},{"id":"OESA-2026-4786","title":"python-pyasn1 security update","description":"Abstract Syntax Notation One (ASN.1) is a technology for exchanging structured data in a universally understood, hardware agnostic way. Many industrial, security and telephony applications heavily rely on ASN.1. The pyasn1 library implements ASN.1 support in pure-Python.\r\n\r\nSecurity Fix(es):\n\npyasn1 is a generic ASN.1 library for Python. From 0.3.3 until 0.6.5, schemaless container decoding stores every decoded component\u0026apos;s TagSet in a growing set even though only one-versus-multiple tag types must be distinguished. Attacker-controlled BER, CER, or DER input contains many distinct long tag IDs whose TagSet hashes collide. Each later set insertion compares against an increasing number of earlier colliding tags in ConstructedPayloadDecoderBase._decodeComponentsSchemaless, producing quadratic CPU work while decoded values and order remain valid. Repeated inputs can exhaust decoder CPU and reduce service availability. This issue is fixed in version 0.6.5.(CVE-2026-119194)\n\npyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, constructed string and indefinite-length ANY decoding repeatedly concatenates each fragment onto a growing bytes value. Attacker-controlled BER or CER data can use many constructed OCTET STRING or character-string fragments. DER rejects constructed OCTET STRING without a schema, but accepts its definite-length form when asn1Spec selects univ.OctetString; it also accepts constructed character strings such as UTF8String without a schema, even though those encodings are not valid DER. The separate indefinite-length ANY path is reachable in BER and CER when asn1Spec selects univ.Any; DER rejects indefinite lengths. OctetStringPayloadDecoder uses growing header concatenation and AnyPayloadDecoder.indefLenValueDecoder uses growing chunk concatenation, repeatedly copying an increasing prefix and causing quadratic work. A sufficiently fragmented value can occupy decoding workers and cause CPU exhaustion without confidentiality or integrity impact. This issue is fixed in version 0.6.5.(CVE-2026-119195)\n\npyasn1 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.(CVE-2026-119196)\n\npyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, binary REAL decoding builds a large mantissa one octet at a time by shifting a growing integer and slicing the remaining byte string. Attacker-controlled ASN.1 includes a binary-encoded REAL with a large mantissa and reaches BER, CER, or DER decode(), with or without a schema containing REAL. RealPayloadDecoder.valueDecoder repeatedly performs a left shift, OR, and suffix copy for every mantissa octet, making decode time quadratic in mantissa length. A comparatively small REAL value can hold a decoding worker on one CPU core for seconds or longer and cause availability loss. This issue is fixed in version 0.6.5.(CVE-2026-119197)","status":"published","published":"2026-11-11T12:26:09Z","modified":"2026-11-11T12:45:11.084248728Z","cvss":[{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","level":"high"}],"updated_at":"2026-11-11T13:08:46.301371Z"},{"id":"OESA-2026-4787","title":"python-pyasn1 security update","description":"Abstract Syntax Notation One (ASN.1) is a technology for exchanging structured data in a universally understood, hardware agnostic way. Many industrial, security and telephony applications heavily rely on ASN.1. The pyasn1 library implements ASN.1 support in pure-Python.\r\n\r\nSecurity Fix(es):\n\npyasn1 is a generic ASN.1 library for Python. From 0.3.3 until 0.6.5, schemaless container decoding stores every decoded component\u0026apos;s TagSet in a growing set even though only one-versus-multiple tag types must be distinguished. Attacker-controlled BER, CER, or DER input contains many distinct long tag IDs whose TagSet hashes collide. Each later set insertion compares against an increasing number of earlier colliding tags in ConstructedPayloadDecoderBase._decodeComponentsSchemaless, producing quadratic CPU work while decoded values and order remain valid. Repeated inputs can exhaust decoder CPU and reduce service availability. This issue is fixed in version 0.6.5.(CVE-2026-119194)\n\npyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, constructed string and indefinite-length ANY decoding repeatedly concatenates each fragment onto a growing bytes value. Attacker-controlled BER or CER data can use many constructed OCTET STRING or character-string fragments. DER rejects constructed OCTET STRING without a schema, but accepts its definite-length form when asn1Spec selects univ.OctetString; it also accepts constructed character strings such as UTF8String without a schema, even though those encodings are not valid DER. The separate indefinite-length ANY path is reachable in BER and CER when asn1Spec selects univ.Any; DER rejects indefinite lengths. OctetStringPayloadDecoder uses growing header concatenation and AnyPayloadDecoder.indefLenValueDecoder uses growing chunk concatenation, repeatedly copying an increasing prefix and causing quadratic work. A sufficiently fragmented value can occupy decoding workers and cause CPU exhaustion without confidentiality or integrity impact. This issue is fixed in version 0.6.5.(CVE-2026-119195)\n\npyasn1 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.(CVE-2026-119196)\n\npyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, binary REAL decoding builds a large mantissa one octet at a time by shifting a growing integer and slicing the remaining byte string. Attacker-controlled ASN.1 includes a binary-encoded REAL with a large mantissa and reaches BER, CER, or DER decode(), with or without a schema containing REAL. RealPayloadDecoder.valueDecoder repeatedly performs a left shift, OR, and suffix copy for every mantissa octet, making decode time quadratic in mantissa length. A comparatively small REAL value can hold a decoding worker on one CPU core for seconds or longer and cause availability loss. This issue is fixed in version 0.6.5.(CVE-2026-119197)","status":"published","published":"2026-11-11T12:26:09Z","modified":"2026-11-11T12:45:03.182962994Z","cvss":[{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","level":"high"}],"updated_at":"2026-11-11T13:08:46.301371Z"},{"id":"OESA-2026-4788","title":"python-pyasn1 security update","description":"Abstract Syntax Notation One (ASN.1) is a technology for exchanging structured data in a universally understood, hardware agnostic way. Many industrial, security and telephony applications heavily rely on ASN.1. The pyasn1 library implements ASN.1 support in pure-Python.\r\n\r\nSecurity Fix(es):\n\npyasn1 is a generic ASN.1 library for Python. From 0.3.3 until 0.6.5, schemaless container decoding stores every decoded component\u0026apos;s TagSet in a growing set even though only one-versus-multiple tag types must be distinguished. Attacker-controlled BER, CER, or DER input contains many distinct long tag IDs whose TagSet hashes collide. Each later set insertion compares against an increasing number of earlier colliding tags in ConstructedPayloadDecoderBase._decodeComponentsSchemaless, producing quadratic CPU work while decoded values and order remain valid. Repeated inputs can exhaust decoder CPU and reduce service availability. This issue is fixed in version 0.6.5.(CVE-2026-119194)\n\npyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, constructed string and indefinite-length ANY decoding repeatedly concatenates each fragment onto a growing bytes value. Attacker-controlled BER or CER data can use many constructed OCTET STRING or character-string fragments. DER rejects constructed OCTET STRING without a schema, but accepts its definite-length form when asn1Spec selects univ.OctetString; it also accepts constructed character strings such as UTF8String without a schema, even though those encodings are not valid DER. The separate indefinite-length ANY path is reachable in BER and CER when asn1Spec selects univ.Any; DER rejects indefinite lengths. OctetStringPayloadDecoder uses growing header concatenation and AnyPayloadDecoder.indefLenValueDecoder uses growing chunk concatenation, repeatedly copying an increasing prefix and causing quadratic work. A sufficiently fragmented value can occupy decoding workers and cause CPU exhaustion without confidentiality or integrity impact. This issue is fixed in version 0.6.5.(CVE-2026-119195)\n\npyasn1 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.(CVE-2026-119196)\n\npyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, binary REAL decoding builds a large mantissa one octet at a time by shifting a growing integer and slicing the remaining byte string. Attacker-controlled ASN.1 includes a binary-encoded REAL with a large mantissa and reaches BER, CER, or DER decode(), with or without a schema containing REAL. RealPayloadDecoder.valueDecoder repeatedly performs a left shift, OR, and suffix copy for every mantissa octet, making decode time quadratic in mantissa length. A comparatively small REAL value can hold a decoding worker on one CPU core for seconds or longer and cause availability loss. This issue is fixed in version 0.6.5.(CVE-2026-119197)","status":"published","published":"2026-11-11T12:26:10Z","modified":"2026-11-11T12:45:06.691643578Z","cvss":[{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","level":"high"}],"updated_at":"2026-11-11T13:08:46.301371Z"},{"id":"OESA-2026-4789","title":"python-pyasn1 security update","description":"Abstract Syntax Notation One (ASN.1) is a technology for exchanging structured data in a universally understood, hardware agnostic way. Many industrial, security and telephony applications heavily rely on ASN.1. The pyasn1 library implements ASN.1 support in pure-Python.\r\n\r\nSecurity Fix(es):\n\npyasn1 is a generic ASN.1 library for Python. From 0.3.3 until 0.6.5, schemaless container decoding stores every decoded component\u0026apos;s TagSet in a growing set even though only one-versus-multiple tag types must be distinguished. Attacker-controlled BER, CER, or DER input contains many distinct long tag IDs whose TagSet hashes collide. Each later set insertion compares against an increasing number of earlier colliding tags in ConstructedPayloadDecoderBase._decodeComponentsSchemaless, producing quadratic CPU work while decoded values and order remain valid. Repeated inputs can exhaust decoder CPU and reduce service availability. This issue is fixed in version 0.6.5.(CVE-2026-119194)\n\npyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, constructed string and indefinite-length ANY decoding repeatedly concatenates each fragment onto a growing bytes value. Attacker-controlled BER or CER data can use many constructed OCTET STRING or character-string fragments. DER rejects constructed OCTET STRING without a schema, but accepts its definite-length form when asn1Spec selects univ.OctetString; it also accepts constructed character strings such as UTF8String without a schema, even though those encodings are not valid DER. The separate indefinite-length ANY path is reachable in BER and CER when asn1Spec selects univ.Any; DER rejects indefinite lengths. OctetStringPayloadDecoder uses growing header concatenation and AnyPayloadDecoder.indefLenValueDecoder uses growing chunk concatenation, repeatedly copying an increasing prefix and causing quadratic work. A sufficiently fragmented value can occupy decoding workers and cause CPU exhaustion without confidentiality or integrity impact. This issue is fixed in version 0.6.5.(CVE-2026-119195)\n\npyasn1 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.(CVE-2026-119196)\n\npyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, binary REAL decoding builds a large mantissa one octet at a time by shifting a growing integer and slicing the remaining byte string. Attacker-controlled ASN.1 includes a binary-encoded REAL with a large mantissa and reaches BER, CER, or DER decode(), with or without a schema containing REAL. RealPayloadDecoder.valueDecoder repeatedly performs a left shift, OR, and suffix copy for every mantissa octet, making decode time quadratic in mantissa length. A comparatively small REAL value can hold a decoding worker on one CPU core for seconds or longer and cause availability loss. This issue is fixed in version 0.6.5.(CVE-2026-119197)","status":"published","published":"2026-11-11T12:26:11Z","modified":"2026-11-11T12:45:06.747288033Z","cvss":[{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","level":"high"}],"updated_at":"2026-11-11T13:08:46.301371Z"},{"id":"UBUNTU-CVE-2026-119195","description":"pyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, constructed string and indefinite-length ANY decoding repeatedly concatenates each fragment onto a growing bytes value. Attacker-controlled BER or CER data can use many constructed OCTET STRING or character-string fragments. DER rejects constructed OCTET STRING without a schema, but accepts its definite-length form when asn1Spec selects univ.OctetString; it also accepts constructed character strings such as UTF8String without a schema, even though those encodings are not valid DER. The separate indefinite-length ANY path is reachable in BER and CER when asn1Spec selects univ.Any; DER rejects indefinite lengths. OctetStringPayloadDecoder uses growing header concatenation and AnyPayloadDecoder.indefLenValueDecoder uses growing chunk concatenation, repeatedly copying an increasing prefix and causing quadratic work. A sufficiently fragmented value can occupy decoding workers and cause CPU exhaustion without confidentiality or integrity impact. This issue is fixed in version 0.6.5.","status":"published","published":"2026-10-29T20:17:00Z","modified":"2026-11-11T09:37:13.447345524Z","cvss":[{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","level":"high"}],"updated_at":"2026-11-11T10:01:18.620522Z"},{"id":"AZL-111533","title":"CVE-2026-119195 affecting package python-pyasn1 0.4.8-3","description":"pyasn1 is a generic ASN.1 library for Python. Prior to 0.6.5, constructed string and indefinite-length ANY decoding repeatedly concatenates each fragment onto a growing bytes value. Attacker-controlled BER or CER data can use many constructed OCTET STRING or character-string fragments. DER rejects constructed OCTET STRING without a schema, but accepts its definite-length form when asn1Spec selects univ.OctetString; it also accepts constructed character strings such as UTF8String without a schema, even though those encodings are not valid DER. The separate indefinite-length ANY path is reachable in BER and CER when asn1Spec selects univ.Any; DER rejects indefinite lengths. OctetStringPayloadDecoder uses growing header concatenation and AnyPayloadDecoder.indefLenValueDecoder uses growing chunk concatenation, repeatedly copying an increasing prefix and causing quadratic work. A sufficiently fragmented value can occupy decoding workers and cause CPU exhaustion without confidentiality or integrity impact. This issue is fixed in version 0.6.5.","status":"published","published":"2026-10-29T20:17:30Z","modified":"2026-11-05T05:40:51Z","updated_at":"2026-11-05T16:41:18.705965Z"},{"id":"USN-9011-1","title":"pyasn1 vulnerabilities","description":"It was discovered that pyasn1 did not properly bound the size of long-form\ntag identifiers when parsing BER, CER, or DER encoded data. An attacker\ncould possibly use this issue to cause applications decoding untrusted\nASN.1 data to consume excessive CPU resources, resulting in a denial of\nservice. This issue only affected Ubuntu 14.04 LTS, Ubuntu 16.04 LTS,\nUbuntu 18.04 LTS, and Ubuntu 20.04 LTS. (CVE-2026-59884)\n\nIt was discovered that pyasn1 processed OBJECT IDENTIFIER and RELATIVE-OID\nvalues in quadratic time relative to the number of arcs. An attacker could\npossibly use this issue to cause applications decoding untrusted ASN.1 data\nto consume excessive CPU resources, resulting in a denial of service. This\nissue only affected Ubuntu 14.04 LTS, Ubuntu 16.04 LTS, Ubuntu 18.04 LTS,\nand Ubuntu 20.04 LTS. (CVE-2026-59885)\n\nIt was discovered that pyasn1 incorrectly handled conversion of decoded\nREAL values to Python float types. An attacker could possibly use this\nissue to cause applications decoding untrusted ASN.1 data to consume\nexcessive CPU and memory resources, resulting in a denial of service. This\nissue only affected Ubuntu 14.04 LTS, Ubuntu 16.04 LTS, Ubuntu 18.04 LTS,\nand Ubuntu 20.04 LTS. (CVE-2026-59886)\n\nIt was discovered that pyasn1 incorrectly handled tracking component types\nwhen decoding containers without a schema. An attacker could possibly use\nthis issue to cause applications decoding untrusted ASN.1 data to consume\nexcessive CPU resources, resulting in a denial of service. This issue only\naffected Ubuntu 18.04 LTS, Ubuntu 20.04 LTS, Ubuntu 22.04 LTS, Ubuntu 24.04\nLTS, Ubuntu 26.04 LTS, and Ubuntu 26.10. (CVE-2026-119194)\n\nIt was discovered that pyasn1 processed fragmented constructed strings and\nindefinite-length ANY values in quadratic time. An attacker could possibly\nuse this issue to cause applications decoding untrusted ASN.1 data to\nconsume excessive CPU resources, resulting in a denial of service. This\nissue was only addressed in Ubuntu 26.04 LTS and Ubuntu 26.10.\n(CVE-2026-119195)\n\nIt was discovered that pyasn1 processed fragmented constructed BIT STRING\nvalues in quadratic time. An attacker could possibly use this issue to\ncause applications decoding untrusted ASN.1 data to consume excessive CPU\nresources, resulting in a denial of service. (CVE-2026-119196)\n\nIt was discovered that pyasn1 processed binary-encoded REAL values with\nlarge mantissas in quadratic time. An attacker could possibly use this\nissue to cause applications decoding untrusted ASN.1 data to consume\nexcessive CPU resources, resulting in a denial of service.\n(CVE-2026-119197)","status":"published","published":"2026-11-09T16:15:14Z","modified":"2026-11-11T09:44:35.505565692Z","updated_at":"2026-11-10T03:21:46.325253Z"}]}}
