CVE-2023-30861
Flask es un framework ligero de aplicaciones web WSGI. Cuando se cumplen todas las siguientes condiciones, una respuesta que contiene datos destinados a un cliente puede ser almacenada en caché y posteriormente enviada por el proxy a otros clientes. Si el proxy también almacena en caché las cabeceras `Set-Cookie`, puede enviar la cookie `session` de un cliente a otros clientes. La gravedad depende del uso que la aplicación haga de la sesión y del comportamiento del proxy con respecto a las cookies. El riesgo depende de que se cumplan todas estas condiciones.
1. La aplicación debe estar alojada detrás de un proxy de caché que no elimine las cookies ni ignore las respuestas con cookies. 2. La aplicación establece `session.permanent = True`. 3.
Leer descripción completaMostrar menos
La aplicación no accede ni modifica la sesión en ningún momento durante una solicitud. 4. `SESSION_REFRESH_EACH_REQUEST` está habilitado (valor por defecto). 5. La aplicación no establece una cabecera `Cache-Control` que indique que una página es privada o que no debe almacenarse en caché.
Esto ocurre porque las versiones vulnerables de Flask solo establecen la cabecera `Vary: Cookie` cuando se accede a la sesión o se modifica, y no cuando se renueva (se vuelve a enviar para actualizar la caducidad) sin haber sido accedida o modificada. Este problema se ha corregido en las versiones 2.3.2 y 2.2.5.
Traducción automática del texto original de NVD (en inglés).
Cronología
Elaborada con nuestros propios datos: NVD, CISA KEV y otros catálogos de explotación, FIRST EPSS, exploits públicos, prensa especializada y la cobertura de Orbitaley.
- Registro CVE publicado en NVD
- Última modificación del registro en NVD
- Primer exploit público
Exploits públicos
Hay código de explotación o plantillas de detección públicos. No es lo mismo que explotación activa confirmada (KEV), pero aumenta el riesgo: parchee con prioridad.
- Prueba de concepto en GitHub (no verificada) · Lista de pruebas de concepto en GitHub
⚠️ Las pruebas de concepto de GitHub no están verificadas: algunas son falsas o contienen malware. No las ejecute nunca fuera de un laboratorio aislado.
Tecnologías afectadas (1)
Registro NVD
- Estado en NVD
- Modificada
- Publicada
- 2 may 2023
- Última modificación
- 17 jun 2026
- Vector CVSS
- CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
- Debilidad (CWE)
- CWE-539
Referencias
- Aviso del fabricantegithub.com/pallets/flask/security/advisories/GHSA-m2qf-hxjv-5gpq
- Parchegithub.com/pallets/flask/commit/70f906c51ce49c485f1d355703e9cc3…
- Parchegithub.com/pallets/flask/commit/afd63b16170b7c047f5758eb910c416…
- Notas de versióngithub.com/pallets/flask/releases/tag/2.2.5
- Notas de versióngithub.com/pallets/flask/releases/tag/2.3.2
- Lista de correolists.debian.org/debian-lts-announce/2023/08/msg00024.html
Mostrar 2 referencias másMostrar menos
- Referenciasecurity.netapp.com/advisory/ntap-20230818-0006
- Referenciadebian.org/security/2023/dsa-5442
JSON original (NVD)
Mostrar
{
"id": "CVE-2023-30861",
"cveTags": [],
"metrics": {
"ssvcV203": [
{
"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
"ssvcData": {
"id": "CVE-2023-30861",
"role": "CISA Coordinator",
"options": [
{
"exploitation": "none"
},
{
"automatable": "no"
},
{
"technicalImpact": "partial"
}
],
"version": "2.0.3",
"timestamp": "2025-01-30T16:29:21.702514Z"
}
}
],
"cvssMetricV31": [
{
"type": "Secondary",
"source": "security-advisories@github.com",
"cvssData": {
"scope": "UNCHANGED",
"version": "3.1",
"baseScore": 7.5,
"attackVector": "NETWORK",
"baseSeverity": "HIGH",
"vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N",
"integrityImpact": "NONE",
"userInteraction": "NONE",
"attackComplexity": "LOW",
"availabilityImpact": "NONE",
"privilegesRequired": "NONE",
"confidentialityImpact": "HIGH"
},
"impactScore": 3.6,
"exploitabilityScore": 3.9
},
{
"type": "Primary",
"source": "nvd@nist.gov",
"cvssData": {
"scope": "UNCHANGED",
"version": "3.1",
"baseScore": 7.5,
"attackVector": "NETWORK",
"baseSeverity": "HIGH",
"vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N",
"integrityImpact": "NONE",
"userInteraction": "NONE",
"attackComplexity": "LOW",
"availabilityImpact": "NONE",
"privilegesRequired": "NONE",
"confidentialityImpact": "HIGH"
},
"impactScore": 3.6,
"exploitabilityScore": 3.9
}
]
},
"affected": [
{
"source": "security-advisories@github.com",
"affectedData": [
{
"vendor": "pallets",
"product": "flask",
"versions": [
{
"status": "affected",
"version": ">= 2.3.0, < 2.3.2"
},
{
"status": "affected",
"version": "< 2.2.5"
}
]
}
]
}
],
"published": "2023-05-02T18:15:52.373",
"references": [
{
"url": "https://github.com/pallets/flask/commit/70f906c51ce49c485f1d355703e9cc3386b1cc2b",
"tags": [
"Patch"
],
"source": "security-advisories@github.com"
},
{
"url": "https://github.com/pallets/flask/commit/afd63b16170b7c047f5758eb910c416511e9c965",
"tags": [
"Patch"
],
"source": "security-advisories@github.com"
},
{
"url": "https://github.com/pallets/flask/releases/tag/2.2.5",
"tags": [
"Release Notes"
],
"source": "security-advisories@github.com"
},
{
"url": "https://github.com/pallets/flask/releases/tag/2.3.2",
"tags": [
"Release Notes"
],
"source": "security-advisories@github.com"
},
{
"url": "https://github.com/pallets/flask/security/advisories/GHSA-m2qf-hxjv-5gpq",
"tags": [
"Vendor Advisory"
],
"source": "security-advisories@github.com"
},
{
"url": "https://lists.debian.org/debian-lts-announce/2023/08/msg00024.html",
"source": "security-advisories@github.com"
},
{
"url": "https://security.netapp.com/advisory/ntap-20230818-0006/",
"source": "security-advisories@github.com"
},
{
"url": "https://www.debian.org/security/2023/dsa-5442",
"source": "security-advisories@github.com"
},
{
"url": "https://github.com/pallets/flask/commit/70f906c51ce49c485f1d355703e9cc3386b1cc2b",
"tags": [
"Patch"
],
"source": "af854a3a-2127-422b-91ae-364da2661108"
},
{
"url": "https://github.com/pallets/flask/commit/afd63b16170b7c047f5758eb910c416511e9c965",
"tags": [
"Patch"
],
"source": "af854a3a-2127-422b-91ae-364da2661108"
},
{
"url": "https://github.com/pallets/flask/releases/tag/2.2.5",
"tags": [
"Release Notes"
],
"source": "af854a3a-2127-422b-91ae-364da2661108"
},
{
"url": "https://github.com/pallets/flask/releases/tag/2.3.2",
"tags": [
"Release Notes"
],
"source": "af854a3a-2127-422b-91ae-364da2661108"
},
{
"url": "https://github.com/pallets/flask/security/advisories/GHSA-m2qf-hxjv-5gpq",
"tags": [
"Vendor Advisory"
],
"source": "af854a3a-2127-422b-91ae-364da2661108"
},
{
"url": "https://lists.debian.org/debian-lts-announce/2023/08/msg00024.html",
"source": "af854a3a-2127-422b-91ae-364da2661108"
},
{
"url": "https://security.netapp.com/advisory/ntap-20230818-0006/",
"source": "af854a3a-2127-422b-91ae-364da2661108"
},
{
"url": "https://www.debian.org/security/2023/dsa-5442",
"source": "af854a3a-2127-422b-91ae-364da2661108"
}
],
"vulnStatus": "Modified",
"weaknesses": [
{
"type": "Secondary",
"source": "security-advisories@github.com",
"description": [
{
"lang": "en",
"value": "CWE-539"
}
]
}
],
"descriptions": [
{
"lang": "en",
"value": "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.\n\n1. The application must be hosted behind a caching proxy that does not strip cookies or ignore responses with cookies.\n2. The application sets `session.permanent = True`\n3. The application does not access or modify the session at any point during a request.\n4. `SESSION_REFRESH_EACH_REQUEST` enabled (the default).\n5. The application does not set a `Cache-Control` header to indicate that a page is private or should not be cached.\n\nThis 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."
}
],
"lastModified": "2026-06-17T05:55:47.853",
"configurations": [
{
"nodes": [
{
"negate": false,
"cpeMatch": [
{
"criteria": "cpe:2.3:a:palletsprojects:flask:*:*:*:*:*:*:*:*",
"vulnerable": true,
"matchCriteriaId": "D663DAAF-D84C-4510-98CE-D24A4034CF18",
"versionEndExcluding": "2.2.5"
},
{
"criteria": "cpe:2.3:a:palletsprojects:flask:*:*:*:*:*:*:*:*",
"vulnerable": true,
"matchCriteriaId": "6DE28F1D-750A-445D-8706-17E6F1E20F64",
"versionEndExcluding": "2.3.2",
"versionStartIncluding": "2.3.0"
}
],
"operator": "OR"
}
]
}
],
"sourceIdentifier": "security-advisories@github.com"
}