llamaCVEVulnerability Intelligence
/
Advisory · GitHub · Go · github.com/zzet/gortex

GHSA-JH93-48GG-GQJP

Path traversal in generate_skill default output path via skill_name

Texto original en inglés · Ver en español

Parche disponible
Descargar PNG JSON
CVSS 3.1
3.3
Baja
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N Fuente: GitHub
ExplotaciónSin evidenciaNo figura en CISA KEV
Exploits públicos0Ninguno conocido
Parche1 versiónPrimer parche a -2 d de la divulgación
Exposición70 dDesde la divulgación, 11 sept 2026, 1:39 a. m.
Detección69 dDesde la divulgación hasta su ingreso al índice
Timeline

Ciclo de vida de la vulnerabilidad

Hoy
Divulgación
Publicada +1
Explotación
Remediación
Parche v0.64.2
Monitoreo
Detectada +1
9 sept 26
11 sept 26
19 nov 26
21 nov 26
9 sept 26
27 sept 26
15 oct 26
2 nov 26
21 nov 26
FechaFaseEventoDetalle
Remediación Parche v0.64.2 github.com/zzet/gortex · -2 d desde divulgación
Divulgación Publicada GHSA-JH93-48GG-GQJP divulgada · CVSS 3.3 (GitHub)
Divulgación Modificada Última actualización del registro
Monitoreo Detectada Ingresó al índice
Monitoreo Verificada Última verificación contra las fuentes
Resumen
Descripción del advisory
Texto original · GitHub · en inglés
Summary

The generate_skill MCP tool allows path traversal through the skill_name parameter when output_dir is omitted. The default output directory is constructed from an indexed repository root and the unvalidated skill_name, allowing generated files to be created outside the repository containment boundary.

Details

In internal/mcp/tools_generate_skill.go, skill_name is only trimmed. When output_dir is empty, the handler constructs:

absOutputDir = filepath.Join(repoRoot, ".claude", "skills", skillName)

The explicit output_dir branch calls resolveFilePath and applies repository confinement, but the default branch does not apply the equivalent guard. Later, the handler writes to absOutputDir using os.MkdirAll and os.WriteFile for SKILL.md and the references tree.

The documented Gortex security model states that MCP agent file access is confined to indexed repository roots because indexed content may influence agent tool calls. This path bypasses that boundary.

PoC

Prerequisites: run Gortex with an indexed Git repository containing a readable source directory. Invoke generate_skill in editing mode with output_dir omitted:

{
"directory": "/path/to/repo/src",
"skill_name": "../../../gortex-outside",
"dry_run": false
}

For a repository at /tmp/work/repo, the handler resolves:

/tmp/work/repo/.claude/skills/../../../gortex-outside

which normalizes to:

/tmp/work/gortex-outside

The handler then creates that directory and writes SKILL.md outside the indexed repository root. The same behavior was confirmed in an isolated Go test executing the same filepath.Join, os.MkdirAll, and os.WriteFile primitives with a temporary repository tree. No real user path was modified.

Impact

A caller able to invoke the MCP tool can create or overwrite SKILL.md and generated reference files outside every indexed repository root, subject to the daemon process permissions. In the documented prompt-injection threat model, untrusted indexed content can influence an agent to invoke tools with attacker-controlled arguments. This breaks the stated filesystem containment boundary and may affect trusted agent skill directories or other writable locations on the same filesystem.

Suggested remediation

Validate skill_name as a single safe path component (reject path separators, absolute paths, . and ..), or route the default destination through the same repository confinement guard used for explicit output_dir values. A post-join containment check should also resolve symlinks before writing.

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

Vector CVSS 3.1

Desglose de métricas

Opción resaltada = valor del vector · izquierda = peor caso · GitHub
Vector de ataqueAV:L
RedAdyacenteLocalFísica
ComplejidadAC:L
BajaAlta
PrivilegiosPR:N
NingunoBajosAltos
InteracciónUI:R
NingunaRequerida
AlcanceS:U
CambiadoSin cambio
ConfidencialidadC:N
AltoBajoNinguno
IntegridadI:L
AltoBajoNinguno
DisponibilidadA:N
AltoBajoNinguno
Score de explotaciónQué tan fácil y probable es que la exploten
6.4/ 10Medio
Vector 6.4 (fácil) · sin evidencia de explotación.
Versiones

Rangos afectados

Afectada Corregida Última
github.com/zzet/gortex< v0.64.2
v0.64.2
v0.64.11
Remediación

Estado del parche por paquete

Paquete / productoEstadoCorregida enDesde divulgaciónÚltima versión
gogithub.com/zzet/gortex
Corregida v0.64.2 -2 d v0.64.11 no afectada
Versiones corregidasv0.64.2
Explotación

Arsenal público

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

Referencias
Advisoryhttps://github.com/zzet/gortex/security/advisories/GHSA-jh93-48gg-gqjp

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