llamaCVEVulnerability Intelligence
/
Advisory · GitHub · npm · isomorphic-git

GHSA-CW2G-2VWQ-88W6

isomorphic-git: Path traversal via a ".." tree-entry name writes files outside the working directory on clone/checkout

Parche disponible
Descargar PNG JSON
CVSS
—
medium
Fuente: —
ExplotaciónSin evidenciaNo figura en CISA KEV
Exploits públicos0Ninguno conocido
Parche1 versiónPrimer parche a -132 d de la divulgación
Exposición11 dDesde la divulgación, 9 nov 2026, 3:13 p. m.
Detección7 dDesde la divulgación hasta su ingreso al índice
Decisión estimadaSeguir
Remediar en la ventana regular de mantenimiento
Estimación de Llama con el árbol SSVC de CISA a partir de la severidad declarada por GHSA (media) y la evidencia de explotación (sin evaluación oficial): sin explotación conocida, no automatizable e impacto técnico parcial. Hay versiones corregidas disponibles.
Ni pánico ni ignorarla: término medio.Ponle etiqueta y a la cola. Ordenadito.
Timeline

Ciclo de vida de la vulnerabilidad

Hoy
Divulgación
Publicada +1
Explotación
Remediación
Parche 1.38.6
Monitoreo
Detectada
30 jun 26
9 nov 26
17 nov 26
21 nov 26
30 jun 26
5 ago 26
10 sept 26
16 oct 26
21 nov 26
FechaFaseEventoDetalle
Remediación Parche 1.38.6 isomorphic-git · -132 d desde divulgación
Divulgación Publicada GHSA-CW2G-2VWQ-88W6 divulgada
Divulgación Modificada Última actualización del registro
Monitoreo Detectada Ingresó al índice
Resumen
Descripción del advisory
Texto original · GitHub · en inglés

### Summary
isomorphic-git's tree parser (`src/models/GitTree.js`) validates each entry name only against the path separators `/` and `\`. It does not reject the standalone reserved name `..`, so a malicious repository can, on a single `clone`/`checkout`, **write files outside the working
directory** (unbounded depth). Works on any host-backed `fs` provider.

### Details
The guard is:

// src/models/GitTree.js
if (path.includes('\\') || path.includes('/')) {
  throw new UnsafeFilepathError(path)
}

The standalone string `..` passes. isomorphic-git assembles the full path incrementally across tree levels, so nesting `..` trees yields `../escaped.txt`, `../../escaped.txt`, … with unbounded depth (each level is a separate tree object that passes the per-entry guard). On checkout `mkdir(workdir/..)` hits `EEXIST` (ignored) and the file is written above the working directory. Depth is chosen to reach the home dir, `/etc`, `/tmp`, etc.; overwriting a shell rc / config / startup file can escalate to code execution.

#### Canonical git behavior (divergence)
git rejects this via `verify_path()`: `git read-tree` fails with `error: invalid path '../escaped.txt'` and `git fsck` flags `warning … hasDotdot: contains '..'`. (git's `verify_path` also rejects `.` and `.git`, the latter flagged by fsck as `hasDotgit` — see the fix note below.) GitHub runs fsck on push, so such a tree can't be hosted there; reach is limited to a self-hosted/Smart-HTTP remote or a MitM.

### PoC
`https://github.com/spiceoverflow/av2-dotdot-traversal` — open in a Codespace; a single `git.clone()` from the bundled server writes `escaped.txt` one directory above the clone target (`DEPTH=N` escapes N levels):

[AV-2] *** PATH TRAVERSAL CONFIRMED ***
[AV-2] File written outside workdir: …/escaped.txt

### Impact
A path-traversal arbitrary file write outside the working directory (CWE-22), triggered by a single clone/checkout; it can escalate to code execution by overwriting shell rc, config, or startup files.

Any application or user that clones/checks out an untrusted (or compromised / MitM'd) repository with isomorphic-git on a host-backed filesystem (Linux, macOS, or Windows — no symlink or privilege required). Requires a non-GitHub remote (self-hosted / Smart-HTTP) or a MitM, since GitHub's fsck rejects trees containing `..`.

### Suggested fix
In the tree parser, reject any entry name equal to `.` or `..`. For full `verify_path` parity it should also reject `.git` (case-insensitively, trailing dots/spaces stripped) and the NTFS 8.3 / HFS variants git blocks. Note: a literal `.git` entry is *not* independently exploitable via
`clone`/`checkout` in current isomorphic-git — the checkout walk skips a `.git` tree entry (a sibling file is written but the `.git` entry is not), so rejecting `.git` is defense-in-depth / git parity rather than a separately demonstrated bug. Additionally, normalize and bounds-check the assembled full path against the working-tree root before any filesystem write.

Incluye detalles técnicos publicados por el investigador. Úselos solo para validar y corregir sus propios sistemas.

Versiones

Rangos afectados

Afectada Corregida Última
isomorphic-git< 1.38.6
1.38.6
1.44.17
Remediación

Estado del parche por paquete

Paquete / productoEstadoCorregida enDesde divulgaciónÚltima versión
npmisomorphic-git
Corregida 1.38.6 -132 d 1.44.17 no afectada
Versiones corregidas1.38.6
Explotación

Arsenal público

Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.

Referencias
Advisoryhttps://nvd.nist.gov/vuln/detail/CVE-2026-63478
Otrahttps://github.com/isomorphic-git/isomorphic-git/security/advisories/GHSA-cw2g-2vwq-88w6
Otrahttps://github.com/isomorphic-git/isomorphic-git/pull/2370
Otrahttps://github.com/isomorphic-git/isomorphic-git/commit/823843d1cd19182df79bc907c767f5bcecb39a0b
Otrahttps://github.com/isomorphic-git/isomorphic-git
Otrahttps://github.com/isomorphic-git/isomorphic-git/releases/tag/v1.38.6

Las referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.