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

GHSA-28VM-87FH-3PX5

Use-after-free when an extension passes a zval to Workers.SendMessage()

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

Parche disponible
Descargar PNG JSON
CVSS 3.1
3.7
Baja
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L 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
Remediar en la ventana regular de mantenimiento
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 parcial. Hay versiones corregidas disponibles.
Actualiza cuando toque, sin correr.Ni el pentester más aburrido usaría esto.
Timeline

Ciclo de vida de la vulnerabilidad

Hoy
Divulgación
Publicada
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-28VM-87FH-3PX5 divulgada · CVSS 3.7 (GitHub)
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

Only custom builds that link a Go extension using the experimental extension workers API are affected, and only if that extension passes a PHP value (an `unsafe.Pointer` to a `zval`) to `Workers.SendMessage()`. Stock binaries and Docker images are not affected.

`SendMessage()` handed the caller's `zval` to the extension worker thread as is. Once the worker's closure returned, `frankenphp_handle_request()` released the value with `zval_ptr_dtor()` on the worker thread, although it never took a reference, and after the calling thread had already been woken up. Each PHP thread has its own Zend heap and refcounts are not atomic, so the value was released once too often, on the wrong heap, while the calling thread could still use it.

Depending on the value and timing, this leads to use-after-free, heap corruption (`zend_mm_heap corrupted`) and a crash of the whole process. If the extension forwards client-controlled data this way, a remote client can trigger it.

Patches

Fixed in 1.13.5.

Workarounds

In the extension, convert the value on the calling thread with `frankenphp.GoValue()` and pass the resulting Go value to `SendMessage()` instead of the `zval` pointer.

Details

`go_frankenphp_worker_handle_request_start()` returned an `unsafe.Pointer` message to the worker unchanged, while other message types were converted with `PHPValue()` on the worker thread. `frankenphp_handle_request()` then destroyed the parameter in both cases.

`SendMessage()` now copies a `zval` message with `GoValue()` while still on the calling thread, and the worker thread always builds its own `zval` with `PHPValue()`, which `frankenphp_handle_request()` owns and releases. Types that `GoValue()` cannot convert, such as objects, now make `SendMessage()` return an error. The container allocated by `PHPValue()` is also freed after use; it was previously leaked for every message.

Proof of concept

An extension function that forwards its argument:

//export_php:function my_queue_push(mixed $data): bool
func my_queue_push(data *C.zval) bool {
	_, err := worker.SendMessage(context.Background(), unsafe.Pointer(data), nil)
	return err == nil
}

Calling `my_queue_push(str_repeat('x', 64))` repeatedly from a PHP script aborts the process with `zend_mm_heap corrupted`.

Credits

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

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

Rangos afectados

Afectada Corregida Última
github.com/dunglas/frankenphp≥ 1.10.0 ≤ 1.13.4
1.10.0
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-28vm-87fh-3px5

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