CVE-2026-27205

Flask session does not add `Vary: Cookie` header when accessed in some ways

MEDIUM
4.3
CVSS Score
Published: February 21, 2026 at 05:21 AM UTC
Updated: June 17, 2026 at 10:26 AM UTC
2 products affected across 2 vendorsFlaskFlask

Using flask by pallets?

Get instant alerts when new vulnerabilities affect flask - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
MEDIUM4.3
Exploit prediction
EPSS 0.4%
SSVC
No known exploit

Description

Flask is a web server gateway interface (WSGI) web application framework. In versions 3.1.2 and below, when the session object is accessed, Flask should set the Vary: Cookie header., resulting in a Use of Cache Containing Sensitive Information vulnerability. The logic instructs caches not to cache the response, as it may contain information specific to a logged in user. This is handled in most cases, but some forms of access such as the Python in operator were overlooked. The severity and risk depend on the application being hosted behind a caching proxy that doesn't ignore responses with cookies, not setting a Cache-Control header to mark pages as private or non-cacheable, and accessing the session in a way that only touches keys without reading values or mutating the session. The issue has been fixed in version 3.1.3.

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

v < 3.1.3
Affected range stops below 3.1.3, so it looks safe — our inference, not a vendor statement

Remediation

No guide yet

No remediation guidance has been written for this CVE yet. What the record does show:

References (3)

x_refsource_CONFIRMVendor Advisory
Source: cverecord
https://github.com/pallets/flask/security/advisories/GHSA-68rp-wp8r-4726
x_refsource_MISCProductRelease Notes
Source: cverecord
https://github.com/pallets/flask/releases/tag/3.1.3

SSVC — Action Prioritization

SSVCNo known exploitNot automatablePartial impact

SSVC signals action urgency (what to patch first), separate from CVSS which measures severity.

CVSS

Attack Vector
NETWORK
Complexity
LOW
Privileges
NONE
User Interaction
REQUIRED
Scope
UNCHANGED
Confidentiality
LOW
Integrity
NONE
Availability
NONE
Vector?

Quick Info

StatusANALYZED
CWE
CWE-524

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card