CVEMETERBack to radar
OFFICIAL RECORD · Python packages

CVE-2023-30861

PUBLISHEDOfficial status check: verifiedCVSS 3.1: 7.5 · high

Flask vulnerable to possible disclosure of permanent session cookie due to missing Vary: Cookie header

Flask is a lightweight WSGI web application framework. When all of the following conditions are met, a response containing data intended for one client may be cached and subsequently sent by the proxy to other clients. If the proxy also caches `Set-Cookie` headers, it may send one client's `session` cookie to other clients. The severity depends on the application's use of the session and the proxy's behavior regarding cookies. The risk depends on all these conditions being met. 1. The application must be hosted behind a caching proxy that does not strip cookies or ignore responses with cookies. 2. The application sets `session.permanent = True` 3. The application does not access or modify the session at any point during a request. 4. `SESSION_REFRESH_EACH_REQUEST` enabled (the default). 5. The application does not set a `Cache-Control` header to indicate that a page is private or should not be cached. This happens because vulnerable versions of Flask only set the `Vary: Cookie` header when the session is accessed or modified, not when it is refreshed (re-sent to update the expiration) without being accessed or modified. This issue has been fixed in versions 2.3.2 and 2.2.5.

Exposure status: unknown. This page does not establish whether an installed system is affected or corrected.

Severity and exploitation evidence

EPSS: 1.250% · score date 2026-11-19. EPSS is an estimated probability over the next 30 days, not proof of exploitation.

CISA KEV: not included in the checked catalog; exploitation may still occur. Last checked: 2026-11-19T17:59:58.648Z. Public exploit availability is not used to set this status.

CVSS 3.1 · 7.5 · published by GitHub_M
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
Assessment source · checked 2026-11-19T12:56:54.604Z

Verification by field

FieldStatusChecked at (UTC)Source
kevverified2026-11-19T17:59:58.648ZCISA KEV
cvssverified2026-11-19T12:56:54.604ZCVE Program
epssverified2026-11-19T18:27:09.434ZFIRST EPSS
patchesverified2026-11-19T12:52:02.626ZOSV
affectedverified2026-11-19T12:56:54.604ZCVE Program
lifecycleverified2026-11-19T12:56:54.604ZCVE Program

Affected versions and configuration

pallets flask; default status: unknown: >= 2.3.0, < 2.3.2 [affected; scheme: unspecified]; < 2.2.5 [affected; scheme: unspecified]

Defaults, conditional configuration, package status and version schemes are retained below. A version range alone is not an exposure verdict.

CVE Program · cve-json · full conditions
{
  "affected": [
    {
      "vendor": "pallets",
      "product": "flask",
      "versions": [
        {
          "status": "affected",
          "version": ">= 2.3.0, < 2.3.2"
        },
        {
          "status": "affected",
          "version": "< 2.2.5"
        }
      ]
    }
  ],
  "additionalContainers": [
    {
      "title": "CVE Program Container",
      "references": [
        {
          "url": "https://github.com/pallets/flask/security/advisories/GHSA-m2qf-hxjv-5gpq",
          "name": "https://github.com/pallets/flask/security/advisories/GHSA-m2qf-hxjv-5gpq",
          "tags": [
            "x_refsource_CONFIRM",
            "x_transferred"
          ]
        },
        {
          "url": "https://github.com/pallets/flask/commit/70f906c51ce49c485f1d355703e9cc3386b1cc2b",
          "name": "https://github.com/pallets/flask/commit/70f906c51ce49c485f1d355703e9cc3386b1cc2b",
          "tags": [
            "x_refsource_MISC",
            "x_transferred"
          ]
        },
        {
          "url": "https://github.com/pallets/flask/commit/afd63b16170b7c047f5758eb910c416511e9c965",
          "name": "https://github.com/pallets/flask/commit/afd63b16170b7c047f5758eb910c416511e9c965",
          "tags": [
            "x_refsource_MISC",
            "x_transferred"
          ]
        },
        {
          "url": "https://github.com/pallets/flask/releases/tag/2.2.5",
          "name": "https://github.com/pallets/flask/releases/tag/2.2.5",
          "tags": [
            "x_refsource_MISC",
            "x_transferred"
          ]
        },
        {
          "url": "https://github.com/pallets/flask/releases/tag/2.3.2",
          "name": "https://github.com/pallets/flask/releases/tag/2.3.2",
          "tags": [
            "x_refsource_MISC",
            "x_transferred"
          ]
        },
        {
          "url": "https://www.debian.org/security/2023/dsa-5442",
          "tags": [
            "x_transferred"
          ]
        },
        {
          "url": "https://security.netapp.com/advisory/ntap-20230818-0006/",
          "tags": [
            "x_transferred"
          ]
        },
        {
          "url": "https://lists.debian.org/debian-lts-announce/2023/08/msg00024.html",
          "tags": [
            "x_transferred"
          ]
        }
      ],
      "providerMetadata": {
        "orgId": "af854a3a-2127-422b-91ae-364da2661108",
        "shortName": "CVE",
        "dateUpdated": "2024-08-02T14:37:15.503Z"
      }
    },
    {
      "title": "CISA ADP Vulnrichment",
      "metrics": [
        {
          "other": {
            "type": "ssvc",
            "content": {
              "id": "CVE-2023-30861",
              "role": "CISA Coordinator",
              "options": [
                {
                  "Exploitation": "none"
                },
                {
                  "Automatable": "no"
                },
                {
                  "Technical Impact": "partial"
                }
              ],
              "version": "2.0.3",
              "timestamp": "2025-01-30T16:29:21.702514Z"
            }
          }
        }
      ],
      "providerMetadata": {
        "orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
        "shortName": "CISA-ADP",
        "dateUpdated": "2025-01-30T16:29:41.159Z"
      }
    }
  ]
}
Archived source JSON
OSV · osv · full conditions
{
  "id": "GHSA-m2qf-hxjv-5gpq",
  "aliases": [
    "CVE-2023-30861",
    "PYSEC-2023-62"
  ],
  "affected": [
    {
      "ranges": [
        {
          "type": "ECOSYSTEM",
          "events": [
            {
              "introduced": "2.3.0"
            },
            {
              "fixed": "2.3.2"
            }
          ]
        }
      ],
      "package": {
        "name": "flask",
        "purl": "pkg:pypi/flask",
        "ecosystem": "PyPI"
      },
      "versions": [
        "2.3.0",
        "2.3.1"
      ],
      "database_specific": {
        "source": "https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2023/05/GHSA-m2qf-hxjv-5gpq/GHSA-m2qf-hxjv-5gpq.json"
      }
    },
    {
      "ranges": [
        {
          "type": "ECOSYSTEM",
          "events": [
            {
              "introduced": "0"
            },
            {
              "fixed": "2.2.5"
            }
          ]
        }
      ],
      "package": {
        "name": "flask",
        "purl": "pkg:pypi/flask",
        "ecosystem": "PyPI"
      },
      "versions": [
        "0.1",
        "0.10",
        "0.10.1",
        "0.11",
        "0.11.1",
        "0.12",
        "0.12.1",
        "0.12.2",
        "0.12.3",
        "0.12.4",
        "0.12.5",
        "0.2",
        "0.3",
        "0.3.1",
        "0.4",
        "0.5",
        "0.5.1",
        "0.5.2",
        "0.6",
        "0.6.1",
        "0.7",
        "0.7.1",
        "0.7.2",
        "0.8",
        "0.8.1",
        "0.9",
        "1.0",
        "1.0.1",
        "1.0.2",
        "1.0.3",
        "1.0.4",
        "1.1.0",
        "1.1.1",
        "1.1.2",
        "1.1.3",
        "1.1.4",
        "2.0.0",
        "2.0.0rc1",
        "2.0.0rc2",
        "2.0.1",
        "2.0.2",
        "2.0.3",
        "2.1.0",
        "2.1.1",
        "2.1.2",
        "2.1.3",
        "2.2.0",
        "2.2.1",
        "2.2.2",
        "2.2.3",
        "2.2.4"
      ],
      "database_specific": {
        "source": "https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2023/05/GHSA-m2qf-hxjv-5gpq/GHSA-m2qf-hxjv-5gpq.json"
      }
    }
  ],
  "severity": [
    {
      "type": "CVSS_V3",
      "score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N"
    },
    {
      "type": "CVSS_V4",
      "score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N"
    }
  ],
  "upstream": [],
  "withdrawn": null,
  "references": [
    {
      "url": "https://github.com/pallets/flask/security/advisories/GHSA-m2qf-hxjv-5gpq",
      "type": "WEB"
    },
    {
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2023-30861",
      "type": "ADVISORY"
    },
    {
      "url": "https://github.com/pallets/flask/commit/70f906c51ce49c485f1d355703e9cc3386b1cc2b",
      "type": "WEB"
    },
    {
      "url": "https://github.com/pallets/flask/commit/afd63b16170b7c047f5758eb910c416511e9c965",
      "type": "WEB"
    },
    {
      "url": "https://github.com/pallets/flask",
      "type": "PACKAGE"
    },
    {
      "url": "https://github.com/pallets/flask/releases/tag/2.2.5",
      "type": "WEB"
    },
    {
      "url": "https://github.com/pallets/flask/releases/tag/2.3.2",
      "type": "WEB"
    },
    {
      "url": "https://github.com/pypa/advisory-database/tree/main/vulns/flask/PYSEC-2023-62.yaml",
      "type": "WEB"
    },
    {
      "url": "https://lists.debian.org/debian-lts-announce/2023/08/msg00024.html",
      "type": "WEB"
    },
    {
      "url": "https://security.netapp.com/advisory/ntap-20230818-0006",
      "type": "WEB"
    },
    {
      "url": "https://www.debian.org/security/2023/dsa-5442",
      "type": "WEB"
    }
  ],
  "relatedGitRanges": [],
  "database_specific": {
    "cwe_ids": [
      "CWE-539"
    ],
    "severity": "HIGH",
    "github_reviewed": true,
    "nvd_published_at": "2023-05-02T18:15:52Z",
    "github_reviewed_at": "2023-05-01T19:22:20Z"
  }
}
Archived source JSON
OSV · osv · full conditions
{
  "id": "PYSEC-2023-62",
  "aliases": [
    "CVE-2023-30861",
    "GHSA-m2qf-hxjv-5gpq"
  ],
  "affected": [
    {
      "ranges": [
        {
          "repo": "https://github.com/pallets/flask",
          "type": "GIT",
          "events": [
            {
              "introduced": "0"
            },
            {
              "fixed": "70f906c51ce49c485f1d355703e9cc3386b1cc2b"
            },
            {
              "fixed": "afd63b16170b7c047f5758eb910c416511e9c965"
            }
          ]
        },
        {
          "type": "ECOSYSTEM",
          "events": [
            {
              "introduced": "0"
            },
            {
              "fixed": "2.2.5"
            },
            {
              "introduced": "2.3.0"
            },
            {
              "fixed": "2.3.2"
            }
          ]
        }
      ],
      "package": {
        "name": "flask",
        "purl": "pkg:pypi/flask",
        "ecosystem": "PyPI"
      },
      "versions": [
        "0.1",
        "0.10",
        "0.10.1",
        "0.11",
        "0.11.1",
        "0.12",
        "0.12.1",
        "0.12.2",
        "0.12.3",
        "0.12.4",
        "0.12.5",
        "0.2",
        "0.3",
        "0.3.1",
        "0.4",
        "0.5",
        "0.5.1",
        "0.5.2",
        "0.6",
        "0.6.1",
        "0.7",
        "0.7.1",
        "0.7.2",
        "0.8",
        "0.8.1",
        "0.9",
        "1.0",
        "1.0.1",
        "1.0.2",
        "1.0.3",
        "1.0.4",
        "1.1.0",
        "1.1.1",
        "1.1.2",
        "1.1.3",
        "1.1.4",
        "2.0.0",
        "2.0.0rc1",
        "2.0.0rc2",
        "2.0.1",
        "2.0.2",
        "2.0.3",
        "2.1.0",
        "2.1.1",
        "2.1.2",
        "2.1.3",
        "2.2.0",
        "2.2.1",
        "2.2.2",
        "2.2.3",
        "2.2.4",
        "2.3.0",
        "2.3.1"
      ],
      "database_specific": {
        "source": "https://github.com/pypa/advisory-database/blob/main/vulns/flask/PYSEC-2023-62.yaml"
      }
    }
  ],
  "severity": [],
  "upstream": [],
  "withdrawn": null,
  "references": [
    {
      "url": "https://github.com/pallets/flask/commit/70f906c51ce49c485f1d355703e9cc3386b1cc2b",
      "type": "FIX"
    },
    {
      "url": "https://github.com/pallets/flask/releases/tag/2.3.2",
      "type": "WEB"
    },
    {
      "url": "https://github.com/pallets/flask/releases/tag/2.2.5",
      "type": "WEB"
    },
    {
      "url": "https://github.com/pallets/flask/security/advisories/GHSA-m2qf-hxjv-5gpq",
      "type": "ADVISORY"
    },
    {
      "url": "https://github.com/pallets/flask/commit/afd63b16170b7c047f5758eb910c416511e9c965",
      "type": "FIX"
    }
  ],
  "relatedGitRanges": [],
  "database_specific": {}
}
Archived source JSON

Correction evidence

Distribution packages and upstream releases are distinct. ESM channels may require the corresponding Ubuntu entitlement. Notes and branch ranges are not installable package versions. OSV fixed boundaries are ecosystem-specific version thresholds, not proof that a package is currently available or installed.

Evidence typeDistribution / releasePackageChannelVersion or source noteSource
ecosystem-boundaryPyPI / packageflaskNot a distribution channel2.3.2Official record
ecosystem-boundaryPyPI / packageflaskNot a distribution channel2.2.5Official record

Vendor notices and operational guidance

No connected vendor notice is available for this record.

Original sources and dates

Official status history