llamaCVEVulnerability Intelligence
/
Advisory · GitHub · Go · github.com/dunglas/frankenphp

GHSA-J99Q-3WR8-XJ43

php_server runs non-PHP files as PHP when no split extension matches the path

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

Parche disponible
Descargar PNG JSON
CVSS 3.1
7.5
Alta
CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H Fuente: GitHub
ExplotaciónSin evidenciaNo figura en CISA KEV
Exploits públicos0Ninguno conocido
Parche1 versiónPrimer parche el mismo día de la divulgación
Exposición16 dDesde la divulgación, 5 nov 2026, 7:01 a. m.
Detección14 dDesde la divulgación hasta su ingreso al índice
Decisión estimadaSeguir de cerca
Monitorear y programar la remediación
Estimación de Llama con el árbol SSVC de CISA a partir de vector CVSS 3.1 y la evidencia de explotación (sin evaluación oficial): sin explotación conocida, no automatizable e impacto técnico total. Hay versiones corregidas disponibles.
Revisa tus logs de la semana con la lupa.Si sale un exploit, la subo de categoría. Atento.
Timeline

Ciclo de vida de la vulnerabilidad

Hoy
Divulgación
Publicada +1
Explotación
Remediación
Parche v1.13.5
Monitoreo
Detectada +1
5 nov 26
19 nov 26
21 nov 26
5 nov 26
9 nov 26
13 nov 26
17 nov 26
21 nov 26
FechaFaseEventoDetalle
Divulgación Publicada GHSA-J99Q-3WR8-XJ43 divulgada · CVSS 7.5 (GitHub)
Divulgación Modificada Última actualización del registro
Remediación Parche v1.13.5 github.com/dunglas/frankenphp · 0 d desde divulgación
Monitoreo Detectada Ingresó al índice
Monitoreo Verificada Última verificación contra las fuentes
Resumen
Descripción del advisory
Texto original · GitHub · en inglés
Impact

`php_server` can execute a file whose name does not end in any configured `split` extension. An attacker who can store a file with a chosen name or in a chosen directory under the document root (an upload, avatar or attachment) can have its contents run as PHP.

The route that sends requests to the `php` handler is a Caddy `path` matcher built from the split extensions (`*.php`, `*.php/*`). The handler then looks for the script with `splitPos()`. When `splitPos()` finds no split, the whole request path is used as the script. Two kinds of path pass the router but make `splitPos()` return no split:

  • A `.php` inside a directory name, in the default configuration. `splitPos()` stopped at the first `.php` that did not end a path segment, while `*.php/*` matches a later one. `/uploads/photos.php.php/avatar.jpg` ran `avatar.jpg` as PHP. This trigger was introduced in 1.13.0 by the fix for GHSA-xxjp-cjxr-2x6m.
  • Unicode case folding, with a split extension containing `i` or `k` (such as `.inc`). Caddy's path matcher lower-cases with `strings.ToLower`, which maps U+0130 to `i` and U+212A to `k`, while `splitPos()` is ASCII-only. `/uploads/avatar.%C4%B0nc` ran `avatar.İnc`.
  • On Windows, a directory whose name ends in a split extension. Caddy's path matcher turns backslashes into slashes and trims trailing dots and spaces from each segment, so `/uploads/photos.php./avatar.jpg` and `/uploads/photos.php%5Cavatar.jpg` were routed to PHP and ran `avatar.jpg`.

With the `php` directive used directly, a request reaching it with a path that contains no split extension also ran that file as PHP. Patched versions refuse it as well.

Patches

Fixed in 1.13.5.

Workarounds

Store uploaded files outside the document root, or serve upload directories with a route that never reaches the `php` handler. Reject directory names containing a split extension, and non-ASCII file names, at upload time. Avoid split extensions containing `i` or `k`.

Details

When `splitPos()` found no split, `splitCgiPath()` used the whole request path as the script. A request whose path matches no split extension is now rejected with a 404 (`ErrInvalidScriptPath`), unless a worker is explicitly assigned to it (worker `match` rules, extension workers). This holds whatever routed the request to the `php` handler, so it doesn't depend on how Caddy's path matcher normalizes paths.

`splitPos()` also skips an occurrence of a split extension that does not end a path segment and keeps looking for a later one, which matches what the `*.php/*` route accepts. `/uploads/photos.php.php/avatar.jpg` now resolves to the script `/uploads/photos.php.php` (a directory, which PHP fails to open, so nothing runs) with `/avatar.jpg` as `PATH_INFO`. A split inside a file name, the case fixed by GHSA-xxjp-cjxr-2x6m, is still refused.

This is a variant of GHSA-g966-83w7-6w38 and GHSA-3g8v-8r37-cgjm.

Proof of concept

Default configuration:

root /srv/app
php_server

Store `<?php echo 'ran as PHP';` as `/srv/app/uploads/photos.php.php/avatar.jpg`, then:

$ curl http://localhost/uploads/photos.php.php/avatar.jpg
ran as PHP

Unicode trigger:

root /srv/app
php_server {
	split .php .inc
}

Store the same content as `/srv/app/uploads/avatar.İnc` (U+0130), then:

$ curl http://localhost/uploads/avatar.%C4%B0nc
ran as PHP
Credits

Discovered by Anthropic's OSS Scanner, as vulnerability ANT-2026-2KBPI7KZ.

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:N
RedAdyacenteLocalFísica
ComplejidadAC:H
BajaAlta
PrivilegiosPR:L
NingunoBajosAltos
InteracciónUI:N
NingunaRequerida
AlcanceS:U
CambiadoSin cambio
ConfidencialidadC:H
AltoBajoNinguno
IntegridadI:H
AltoBajoNinguno
DisponibilidadA:H
AltoBajoNinguno
Score de explotaciónQué tan fácil y probable es que la exploten
5.9/ 10Medio
Vector 5.9 (moderada) · sin evidencia de explotación.
Versiones

Rangos afectados

Afectada Corregida Última
github.com/dunglas/frankenphp≤ 1.13.4
1.13.4
v1.13.6
Remediación

Estado del parche por paquete

Paquete / productoEstadoCorregida enDesde divulgaciónÚltima versión
gogithub.com/dunglas/frankenphp
Corregida v1.13.5 0 d v1.13.6 no afectada
Versiones corregidasv1.13.5
Explotación

Arsenal público

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

Referencias
Advisoryhttps://github.com/php/frankenphp/security/advisories/GHSA-j99q-3wr8-xj43

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