On this page (7 sections)

Ubuntu has published USN-9011-1, a security notice about pyasn1, a widely used Python library for parsing ASN.1 data. The notice describes denial-of-service weaknesses in which specially crafted BER, CER or DER input makes an application consume excessive CPU. Two of the issues are tracked as CVE-2026-59884 and CVE-2026-59885; the notice also describes a third issue involving REAL values.

If you run Python services that decode untrusted ASN.1 data (certificates, LDAP, SNMP, Kerberos and similar), or you manage older Ubuntu LTS servers, this is worth a quick check. The upstream project fixed all three issues in pyasn1 0.6.4, and the remedy is a package update.

What happened

The pyasn1 maintainers released version 0.6.4 as a security release on July 9, 2026. It fixes three resource-exhaustion problems. Ubuntu's notice, dated November 9, 2026 in our source data, describes these issues and says which Ubuntu releases were affected.

According to the upstream release notes, the three issues are: quadratic time in the OBJECT IDENTIFIER and RELATIVE-OID decoders (CVE-2026-59885), unbounded BER long-form tag IDs (CVE-2026-59884), and excessive memory and CPU use in the REAL-to-float conversion (listed upstream as CVE-2026-59886).

The Ubuntu notice text available to us was cut off. We cannot confirm which Ubuntu releases the REAL issue affected, nor the fixed package versions. Read USN-9011-1 directly for those details before deciding what to install.

Technical details in plain terms

The two CVEs described here belong to the same family: uncontrolled resource consumption (CWE-400). The parser does more work, or builds bigger numbers, than the input size would suggest, so a small message can keep a CPU busy for a long time. The advisories rate confidentiality and integrity impact as none; the impact is availability.

CVE-2026-59884: unbounded tag IDs

ASN.1 tags can be written in a long form that spans many bytes. The GitHub advisory explains that the decoder kept accumulating those bytes with no upper limit, so an attacker could force it to build an enormous integer. CPU cost grew quadratically: a roughly 1 MB input consumed over a minute of CPU. On Python 3.11 and later, the oversized value could also raise an unhandled ValueError while formatting an error message, which can slip past code that only catches the library's PyAsn1Error.

The fix caps long-form tag IDs at 20 octets (140 bits) and rejects anything larger with PyAsn1Error. The encoders and the native codec are not affected by this one.

CVE-2026-59885: OBJECT IDENTIFIER arcs

Per the advisory, the decoders handled OBJECT IDENTIFIER and RELATIVE-OID values in quadratic time relative to the number of arcs. A payload of tens of kilobytes could cost seconds of CPU per decode() call. The encoders show the same behavior when an application re-encodes attacker-supplied values it previously decoded. An earlier limit on the size of individual arcs does not help, because it bounds arc length, not arc count. Version 0.6.4 makes arc handling linear.

Who is realistically exposed

The risk depends on whether untrusted data reaches the decoder. A library in a virtualenv that only parses your own files is a low concern. A network-facing service that parses ASN.1 from outside is the real target.

  • Services that accept certificates, LDAP messages, SNMP data or Kerberos tokens from clients or the internet and parse them with Python.
  • Applications that use pyasn1 indirectly through other packages, so you may be exposed without ever importing it yourself.
  • Older Ubuntu LTS servers (14.04, 16.04, 18.04, 20.04) that Ubuntu lists as affected by the first two issues.
  • Background workers and APIs where a single stuck request can starve other traffic, since the attack burns CPU rather than crashing the process.
The CVSS rating is high mainly because exploitation needs no authentication and no user interaction. The advisories report an EPSS score of 0.616%, which estimates the chance of exploitation within 30 days. Neither the advisories nor the Ubuntu notice text we saw report active exploitation.

How to check your exposure

Start by finding which pyasn1 version each environment uses. This command prints the installed version in the active Python environment; anything below 0.6.4 is affected.

Show the pyasn1 version in the current Python environmentShell
pip show pyasn1

On Debian and Ubuntu hosts, the system library ships as a distribution package. This lists it with its installed version, which you can compare against the version given in the Ubuntu notice.

Check the distribution package version (Debian/Ubuntu)Shell
apt list --installed 2>/dev/null | grep pyasn1

Remember that distributions often backport fixes into their own version numbers, so a system package can be patched even if its version string does not read 0.6.4. Use the version listed in USN-9011-1 for system packages, and 0.6.4 for pip installs.

What to do now

  1. Read USN-9011-1 to confirm whether your Ubuntu release is listed and which package version fixes it.
  2. Inventory every host, container image and virtualenv that includes pyasn1, directly or as a dependency.
  3. On Ubuntu servers, apply the pyasn1 update from the notice using the package manager.
  4. For pip-managed environments and container images, upgrade to pyasn1 0.6.4 or later and rebuild images.
  5. Restart long-running Python services so they load the patched library.
  6. Where you cannot patch yet, limit the size of untrusted input before passing it to decode(), as the maintainers recommend.
  7. Set request size limits and timeouts at your reverse proxy or load balancer for endpoints that carry ASN.1 data.
  8. Re-run your dependency audit afterwards to confirm no old copy remains.

This updates only the pyasn1 package on Debian or Ubuntu without upgrading unrelated packages. If no newer version is offered for your release, check the notice for the status of your release.

Upgrade the system pyasn1 package (Debian/Ubuntu)Shell
sudo apt-get update
sudo apt-get install --only-upgrade python3-pyasn1
Caution. Restarting services interrupts in-flight requests. Schedule restarts in a maintenance window for production systems, and test application behavior first if you also change pinned Python dependencies.

For a pip-managed environment, this upgrades the library to the fixed release. Run it inside the right virtualenv, then confirm with pip show pyasn1.

Upgrade pyasn1 to the fixed release (pip)Shell
pip install --upgrade "pyasn1>=0.6.4"
Tip. Pin a minimum version in your requirements file (for example pyasn1>=0.6.4) so a stale lockfile or base image cannot quietly bring the vulnerable version back.

Detection and monitoring

Because the attack burns CPU, the symptoms look like a performance problem rather than an intrusion. Watch for Python worker processes pinned at high CPU after handling a request, request timeouts on endpoints that parse certificates or directory data, and unexpected ValueError exceptions mentioning integer string conversion on Python 3.11 and later. Review your application logs for unusually large request bodies to those endpoints.

Uptime and response-time monitoring helps you notice a service being starved even when no alert fires from the application itself. Webforta Monitor tracks uptime, certificates, DNS and header changes, and our uptime monitoring guide explains how to set sensible thresholds. A firewall or rate limiting in front of the service can also reduce how often oversized requests reach your code; see what a WAF does for the basics. None of this replaces updating the library.

Timeline

Key dates from the sources
DateEvent
July 9, 2026pyasn1 0.6.4 released; GitHub advisories published
July 14, 2026CVE-2026-59884 and CVE-2026-59885 published by NVD
July 21, 2026Advisories reviewed and added to the GitHub Advisory Database
November 9, 2026Ubuntu publishes USN-9011-1 (date as given in the source metadata)

For more security news, including other recent Ubuntu notices, browse the Webforta security blog.

Sources

This article is based on the public sources below. Details can change as vendors and researchers publish more; check the original advisories before acting on version numbers.

  1. CVE-2026-59884 - GitHub Advisory Databasegithub.com
  2. Merge commit from fork · pyasn1/pyasn1@628e36egithub.com
  3. Release Release 0.6.4 · pyasn1/pyasn1github.com
  4. CVE-2026-59885 - GitHub Advisory Databasegithub.com
  5. Merge commit from fork · pyasn1/pyasn1@45bdb19github.com
  6. USN-9011-1: pyasn1 vulnerabilitiesubuntu.com ·
  • Ubuntu
  • pyasn1
  • Python
  • denial of service
  • USN