GHSA-6FR7-VVRM-WF2W
Default automatic STREAM credit can OOM a slow Erlang QUIC owner
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H
Fuente: GitHub
Ciclo de vida de la vulnerabilidad
| Fecha | Fase | Evento | Detalle |
|---|---|---|---|
| Divulgación | Publicada | GHSA-6FR7-VVRM-WF2W divulgada · CVSS 5.9 (GitHub) | |
| Divulgación | Modificada | Última actualización del registro | |
| Monitoreo | Detectada | Ingresó al índice | |
| Monitoreo | Verificada | Última verificación contra las fuentes |
Summary
`quic 2.1.1` defaults each receive stream to automatic flow control. Incoming
bytes earn new QUIC credit when they are delivered into the Erlang owner's
mailbox, rather than when the application consumes them. A slow or blocked
owner therefore does not apply backpressure: a remote peer can keep sending
while payload messages accumulate outside the transport receive-buffer limit.
Two 4 GiB attacks were OOM-killed. Consuming-owner controls accepted comparable
traffic and stayed below 73 MiB.
Details
Affected revision: `quic 2.1.1`, commit
`0b5634b6468c1b2aa3132baaabe5515d4ea485bd`.
- Every stream defaults to `recv_flow = auto`
https://github.com/benoitc/erlang_quic/blob/0b5634b6468c1b2aa3132baaabe5515d4ea485bd/include/quic.hrl#L621-L638. - Contiguous STREAM data is delivered to the owner before receive-credit updates
https://github.com/benoitc/erlang_quic/blob/0b5634b6468c1b2aa3132baaabe5515d4ea485bd/src/quic_connection.erl#L7290-L7355. - Automatic mode advances `MAX_STREAM_DATA` from the delivered offset
https://github.com/benoitc/erlang_quic/blob/0b5634b6468c1b2aa3132baaabe5515d4ea485bd/src/quic_connection.erl#L7356-L7427. - Only manual streams subtract application-unconsumed bytes when granting connection credit
https://github.com/benoitc/erlang_quic/blob/0b5634b6468c1b2aa3132baaabe5515d4ea485bd/src/quic_connection.erl#L7446-L7488. - `deliver_stream_data/4` places each payload in the owner mailbox
https://github.com/benoitc/erlang_quic/blob/0b5634b6468c1b2aa3132baaabe5515d4ea485bd/src/quic_connection.erl#L7842-L7871.
The transport receive buffer can remain bounded while the same bytes are
retained as Erlang messages in another process. The QUIC peer observes renewed
flow-control credit and can continue growing that mailbox.
Proof of concept
Reproduce
- A server using `quic` accepts the attacker's connection.
- The application keeps the default `recv_flow=auto` behavior.
- The selected connection owner consumes STREAM messages more slowly than the
The slow-owner condition is application-dependent. No non-default QUIC window,
malformed frame, race timing, or server-side access is required.
Proof of concept
- Build `quic 2.1.1` at the tested commit with OTP 27.
- Start a server whose connection owner does not consume
- Limit the victim to exactly 4 GiB memory and total memory+swap, with restart
- Complete one normal QUIC handshake and repeatedly write 32,768-byte STREAM
- Probe the endpoint with independent fresh QUIC connections.
- Repeat with an owner that continuously consumes the same STREAM messages.
| Arm | Repeats | Result |
|---|---:|---|
| Slow/blocked owner | 2 | OOM at 3,034,128,370 and 3,047,042,995 received bytes; exit 137 |
| Consuming owner | 2 | 3,143,335,936 and 3,276,800,000 bytes accepted; healthy; zero probe failures |
Attack owner mailboxes reached 2,294,168 and 2,305,923 messages. Controls used
at most 72,274,744 bytes of sampled VM memory.
Impact
A remote peer can exhaust the BEAM VM when an affected application uses the
default automatic receive mode with a slow owner. Process termination disrupts
all connections and other Erlang services sharing that VM.
Incluye detalles técnicos publicados por el investigador. Úselos solo para validar y corregir sus propios sistemas.
Desglose de métricas
Rangos afectados
Estado del parche por paquete
| Paquete / producto | Estado | Corregida en | Desde divulgación | Última versión |
|---|---|---|---|---|
Hexquic |
Sin parche | — | — | — |
Arsenal público
Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.
https://github.com/benoitc/erlang_quic/security/advisories/GHSA-6fr7-vvrm-wf2wLas referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.
