Read the docs

CPython cookiejar lets expired Set-Cookie delete other cookies

Priority LOW 28CWE-346Published · Updated

Key facts

Attack vector
Network
Privileges required
None
User interaction
None
Attack complexity
Low
Attack requirements
Present
Impact type
Security bypass
Confidentiality · integrity · availability
None · Low · None
Fix status
Fixed

Attack profile from CVSS 4.0 · CNA. Fix status from CNA. Impact type from CWE-346.

Summary

CPython before 3.16.0a2 has an origin validation error (CWE-346) in http.cookiejar. CookieJar deletes a stored cookie when a response carries an already expired Set-Cookie header, without consulting the cookie policy. An unauthenticated remote server can therefore delete cookies belonging to other domains from a shared cookie jar, such as the one used by urllib's HTTPCookieProcessor.

Written with Claude Haiku 5.5 from the sources below · 2026-11-11

Description from the CNA

http.cookiejar.CookieJar deleted a stored cookie when a response carried an already expired Set-Cookie header for it, using the Domain and Path attributes from the header without consulting the cookie policy. A server could therefore delete cookies belonging to other domains from a shared cookie jar, such as the one used by urllib's HTTPCookieProcessor. The fix consults the cookie policy before an expired cookie may delete an existing one, as required by RFC 6265 section 5.3.

Why it matters now

Exploitation None reported CISA SSVC · not in CISA KEV
EPSS 0.00272 19th percentileScored 2026-11-16
Fix Fixed CPython (Python Software Foundation): 3.16.0a2

SSVC decision points

CISA ADP · SSVC 2.0.3

Exploitation
None
Automatable
No
Technical impact
Partial

The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.

Affected products

VendorProductAffected versionsFixed inStatusSource
Python Software FoundationCPythonbefore 3.16.0a23.16.0a2Patch availableCNA

CPE names Threatist (inferred) · 1

Inferred from how NVD named this product before; not given by a source.

CPEVersionsRoleVendor
cpe:2.3:a:python:python:*:*:*:*:*:*:*:*——python-pillow
  • cpe:2.3:a:python:python:*:*:*:*:*:*:*:* Versions — — ·python-pillow

Remediation

Upgrade CPython to 3.16.0a2, which consults the cookie policy before an expired cookie may delete an existing one.

Written with Claude Haiku 5.5 from the sources below · 2026-11-11

  • Fix · CNA CPython (Python Software Foundation) Fixed in 3.16.0a2

Fixed in the same release

Records fixed by the same vendor advisory or release, as the CNA lists them.

  • Release ·

    Python Software Foundation CPython 3.16.0a2

    2 records Highest priority Priority LOW 2 LOW

    Other records, highest priority first

    • TI-2026-87142 Missing identity check in CPython ssl.get_server_certificate with ca_certsPriority LOW 3

Timeline

  1. 2026-11-09 Threatist record created from CVE-2026-124249
  2. 2026-11-09 Alias added: GHSA-chc2-vx2q-cwqf
  3. 2026-11-10 3 new references · CNA
  4. 2026-11-11 Priority changed: MEDIUM → LOW
  5. 2026-11-11 Fix available: Python Software Foundation/[email protected] · CNA
  6. 2026-11-12 CISA SSVC decision points changed

References

  • TI-2024-07037 Quadratic complexity parsing cookies with backslashes CVSS 3.1HIGH 7.5
  • TI-2024-11791 Bypass extraction filter to modify file metadata outside extraction directory CVSS 3.1MEDIUM 5.3
  • TI-2024-00411 Quoted zip-bomb protection for zipfile CVSS 3.1MEDIUM 6.2
  • TI-2026-13296 `HTTPPasswordMgr` can send saved HTTPS credentials via HTTP because of incorrect scheme matching CVSS 4.0MEDIUM 6.0
  • TI-2024-06422 Email header injection due to unquoted newlines CVSS 3.1MEDIUM 5.5
  • TI-2026-04606 Possible to hijack modules in current working directory CVSS 4.0MEDIUM 5.6
See all 88 →

Sources