CVE-2024-7774
A path traversal vulnerability exists in the `getFullPath` method of langchain-ai/langchainjs version 0.2.5. This vulnerability allows attackers to save files anywhere in the filesystem, overwrite existing text files, read `.txt` files, and delete files. The vulnerability is exploited through the `setFileContent`, `getParsedFile`, and `mdelete` methods, which do not properly sanitize user input.
CVSS
- Versión: 3.1
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
- Puntuación base: 9.1
Probabilidad de explotación (EPSS)
- Probabilidad de explotación en los próximos 30 días: 0.56%
- Percentil entre todas las CVEs puntuadas: 44
- Fecha de la puntuación: 5/10/2026
EPSS (Exploit Prediction Scoring System, de FIRST) estima la probabilidad de que una vulnerabilidad sea explotada en 30 días. Complementa a CVSS (impacto) y a CISA KEV (explotación confirmada).
🎯 Técnicas ATT&CK
Cómo se explota esta vulnerabilidad y qué consigue el atacante, en el lenguaje de MITRE ATT&CK.
- Explotación
T1190Exploit Public-Facing Applicationinitial access95 % - Impacto principal
T1565.001Stored Data Manipulationimpact90 % - Impacto secundario
T1005Data from Local Systemcollection85 % - Impacto secundario
T1070.004File Deletionstealth80 %
Vector CVSS AV:N/PR:N/UI:N indica explotación remota sin autenticación (T1190). Path traversal permite sobrescribir archivos (T1565.001), leer datos (T1005) y eliminar ficheros (T1070.004). CWE-29 y CWE-22 confirman traversal de rutas.
Inferido por nuestro agente de análisis a partir de la descripción oficial, el vector CVSS y la CWE, y comprobado por un supervisor. Puede contener errores.
🛡️ Mitigaciones ATT&CK que cubren estas técnicas
Tecnologías afectadas (1)
CWE
- CWE-29
- CWE-22
Referencias
JSON original (NVD)
Mostrar
{
"id": "CVE-2024-7774",
"cveTags": [],
"metrics": {
"ssvcV203": [
{
"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
"ssvcData": {
"id": "CVE-2024-7774",
"role": "CISA Coordinator",
"options": [
{
"exploitation": "poc"
},
{
"automatable": "no"
},
{
"technicalImpact": "partial"
}
],
"version": "2.0.3",
"timestamp": "2024-10-29T13:28:45.771600Z"
}
}
],
"cvssMetricV30": [
{
"type": "Secondary",
"source": "security@huntr.dev",
"cvssData": {
"scope": "UNCHANGED",
"version": "3.0",
"baseScore": 6.5,
"attackVector": "NETWORK",
"baseSeverity": "MEDIUM",
"vectorString": "CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N",
"integrityImpact": "LOW",
"userInteraction": "NONE",
"attackComplexity": "LOW",
"availabilityImpact": "NONE",
"privilegesRequired": "NONE",
"confidentialityImpact": "LOW"
},
"impactScore": 2.5,
"exploitabilityScore": 3.9
}
],
"cvssMetricV31": [
{
"type": "Primary",
"source": "nvd@nist.gov",
"cvssData": {
"scope": "UNCHANGED",
"version": "3.1",
"baseScore": 9.1,
"attackVector": "NETWORK",
"baseSeverity": "CRITICAL",
"vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N",
"integrityImpact": "HIGH",
"userInteraction": "NONE",
"attackComplexity": "LOW",
"availabilityImpact": "NONE",
"privilegesRequired": "NONE",
"confidentialityImpact": "HIGH"
},
"impactScore": 5.2,
"exploitabilityScore": 3.9
}
]
},
"affected": [
{
"source": "security@huntr.dev",
"affectedData": [
{
"vendor": "langchain-ai",
"product": "langchain-ai/langchainjs",
"versions": [
{
"status": "affected",
"version": "unspecified",
"lessThan": "0.2.19",
"versionType": "custom"
}
]
}
]
},
{
"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
"affectedData": [
{
"cpes": [
"cpe:2.3:a:langchain-ai:langchain-ai\\/langchainjs:*:*:*:*:*:*:*:*"
],
"vendor": "langchain-ai",
"product": "langchain-ai\\/langchainjs",
"versions": [
{
"status": "affected",
"version": "0",
"lessThan": "0.2.19",
"versionType": "custom"
}
],
"defaultStatus": "unknown"
}
]
}
],
"published": "2024-10-29T13:15:09.930",
"references": [
{
"url": "https://github.com/langchain-ai/langchainjs/commit/a0fad77d6b569e5872bd4a9d33be0c0785e538a9",
"tags": [
"Patch"
],
"source": "security@huntr.dev"
},
{
"url": "https://huntr.com/bounties/8fe40685-b714-4191-af7a-3de5e5628cee",
"tags": [
"Exploit",
"Third Party Advisory"
],
"source": "security@huntr.dev"
}
],
"vulnStatus": "Analyzed",
"weaknesses": [
{
"type": "Secondary",
"source": "security@huntr.dev",
"description": [
{
"lang": "en",
"value": "CWE-29"
}
]
},
{
"type": "Primary",
"source": "nvd@nist.gov",
"description": [
{
"lang": "en",
"value": "CWE-22"
}
]
}
],
"descriptions": [
{
"lang": "en",
"value": "A path traversal vulnerability exists in the `getFullPath` method of langchain-ai/langchainjs version 0.2.5. This vulnerability allows attackers to save files anywhere in the filesystem, overwrite existing text files, read `.txt` files, and delete files. The vulnerability is exploited through the `setFileContent`, `getParsedFile`, and `mdelete` methods, which do not properly sanitize user input."
},
{
"lang": "es",
"value": "Existe una vulnerabilidad de path traversal en el método `getFullPath` de la versión 0.2.5 de langchain-ai/langchainjs. Esta vulnerabilidad permite a los atacantes guardar archivos en cualquier parte del sistema de archivos, sobrescribir archivos de texto existentes, leer archivos `.txt` y eliminar archivos. La vulnerabilidad se explota a través de los métodos `setFileContent`, `getParsedFile` y `mdelete`, que no desinfectan adecuadamente la entrada del usuario."
}
],
"lastModified": "2026-06-17T08:20:53.750",
"configurations": [
{
"nodes": [
{
"negate": false,
"cpeMatch": [
{
"criteria": "cpe:2.3:a:langchain:langchain.js:0.2.5:*:*:*:*:*:*:*",
"vulnerable": true,
"matchCriteriaId": "C8FEBDE2-0730-4472-8E92-1523B8C84610"
}
],
"operator": "OR"
}
]
}
],
"sourceIdentifier": "security@huntr.dev"
}