Findings

CVE-2025-12781

When passing data to the b64decode(), standard_b64decode(), and urlsafe_b64decode() functions in the "base64" module the characters "+/" will always be accepted, regardless of the

Published Jan 21, 2026 · corrected/updated Oct 16, 2026 · evidence confidence medium

When passing data to the b64decode(), standard_b64decode(), and urlsafe_b64decode() functions in the "base64" module the characters "+/" will always be accepted, regardless of the value of "altchars" parameter, typically used to establish an "alternative base64 alphabet" such as the URL safe alphabet. This behavior matches what is recommended in earlier base64 RFCs, but newer RFCs now recommend either dropping characters outside the specified base64 alphabet or raising an error. The old behavior has the possibility of causing data integrity issues. This behavior can only be insecure if your application uses an alternate base64 alphabet (without "+/"). If your application does not use the "altchars" parameter or the urlsafe_b64decode() function, then your application does not use an alternative base64 alphabet. The attached patches DOES NOT make the base64-decode behavior raise an error, as this would be a change in behavior and break existing programs. Instead, the patch deprecates the behavior which will be replaced with the newly recommended behavior in a future version of Python. Users are recommended to mitigate by verifying user-controlled inputs match the base64 alphabet they are expecting or verify that their application would not be affected if the b64decode() functions accepted "+" or "/" outside of altchars.

Grounded briefings

Catalog interpretations for three audiences. Each brief cites ingested metadata and the original advisories below. They are not independent research and they do not invent exploit steps.

Executive

CVE-2025-12781 is a medium public vulnerability record for this product. It is not currently listed in the CISA Known Exploited catalog. Check the linked vendor or CERT advisories for patch status. This summary is a catalog interpretation of the ingested metadata and cites the original advisories below.

System administrator

Identify whether this product is in your estate, then compare installed versions with the affected ranges. Affected packages or ranges on record: pypy3 (7.3.11+dfsg-2, 7.3.11+dfsg-2+deb12u1, 7.3.11+dfsg-2+deb12u2); python3.11 (3.11.2-6, 3.11.2-6+deb12u1, 3.11.2-6+deb12u2); pypy3 (7.3.19+dfsg-2, 7.3.20+dfsg-1, 7.3.20+dfsg-2); python3.13 (3.13.11-1, 3.13.12-1, 3.13.14-1). Check the linked vendor or CERT advisories for patch status. Prefer the vendor or distribution advisory linked in Sources before changing production systems. This is a catalog interpretation, not a runbook.

Security analyst

Signals on file: CVSS 5.3, EPSS 0.6%. It is not currently listed in the CISA Known Exploited catalog. Sources contributing to this record: epss, osv. Public exploit references, when present, are outbound links only and are not proof of active exploitation. This is a catalog interpretation of stored metadata.

Exploitation and remediation

  • Exploitation evidence

    Not listed as known exploited in CISA KEV. Not in the CISA KEV catalog.

  • Patch and remediation

    No required-action text is stored yet. Use the vendor or CERT links in Sources for patch availability.

  • Safe detection guidance

    Compare installed versions with the affected ranges below and verify the advisory from the original publisher. This site stores metadata and outbound links only; it does not ship exploit code or proof-of-concept payloads.

Technology hubs

Code

The project this record applies to. Exploit listings stay in References.

No public source repository is identified for this product.

Timeline

Detection, updates, and resolution for this record.

  1. Jan 21, 2026 · OSV.dev

    Detected

    When passing data to the b64decode(), standard_b64decode(), and urlsafe_b64decode() functions in the "base64" module the characters "+/" will always be accepted, regardless of the value of "altchars" parameter, typically used to establish an "alternative base64 alphabet" such as the URL safe alphabet. This behavior matches what is recommended in earlier base64 RFCs, but newer RFCs now recommend ei

  2. Oct 16, 2026 · OSV.dev

    Fix available

    python3.14 fixed in 3.14.2-1

  3. Oct 16, 2026 · OSV.dev

    Fix available

    python3.14 fixed in 3.14.2-1

  4. Oct 16, 2026 · OSV.dev

    Updated

    When passing data to the b64decode(), standard_b64decode(), and urlsafe_b64decode() functions in the "base64" module the characters "+/" will always be accepted, regardless of the value of "altchars" parameter, typically used to establish an "alternative base64 alphabet" such as the URL safe alphabet. This behavior matches what is recommended in earlier base64 RFCs, but newer RFCs now recommend ei

Affected

  • Debian:12 pypy37.3.11+dfsg-2, 7.3.11+dfsg-2+deb12u1, 7.3.11+dfsg-2+deb12u2
  • Debian:12 python3.113.11.2-6, 3.11.2-6+deb12u1, 3.11.2-6+deb12u2
  • Debian:13 pypy37.3.19+dfsg-2, 7.3.20+dfsg-1, 7.3.20+dfsg-2
  • Debian:13 python3.133.13.11-1, 3.13.12-1, 3.13.14-1
  • Debian:14 pypy37.3.19+dfsg-2, 7.3.20+dfsg-1, 7.3.20+dfsg-2
  • Debian:14 python3.133.13.11-1, 3.13.12-1, 3.13.14-1
  • Debian:14 python3.140 → 3.14.2-1

Sources

References