Descrizione
Improper Handling of Highly Compressed Data (Data Amplification) vulnerability in elixir-grpc grpc_core and grpc allows unauthenticated attackers to exhaust server memory via a compressed Erlang external term in a gRPC message body. GRPC.Codec.Erlpack.decode/2 (grpc_core/lib/grpc/codec/erlpack.ex, and lib/grpc/codec/erlpack.ex before the package split) passes the message body to :erlang.binary_to_term/2. That function inflates a compressed term in full before it returns. The codec sets no limit on the decoded size, and its type checks run only on the decoded term. The server's max_body_size limit counts the compressed bytes of the request. A request with Content-Type: application/grpc+erlpack can therefore make the server allocate a term much larger than the request body. This issue affects grpc: from 0.4.0 before 1.0.0; grpc_core: from 1.0.0 before 1.1.0.
Come correggere
Priorità: Media — correggere nel prossimo ciclo di patch. Motivazione: CVSS 8.2, EPSS 0.7% (percentile 54).
Versioni da aggiornare
- elixir-grpc grpc: vulnerabili le versioni dalla
0.4.0precedenti alla1.0.0→ aggiornare alla1.0.0o successiva. - elixir-grpc grpc_core: vulnerabili le versioni dalla
1.0.0precedenti alla1.1.0→ aggiornare alla1.1.0o successiva.
Indicazioni del vendor
Workaround (testo originale del vendor):
Remove GRPC.Codec.Erlpack from the server's codecs list if the codec is not needed. If the codec is needed, register a wrapper codec in its place. The wrapper implements the GRPC.Codec behaviour, returns "erlpack" from name/0, raises in decode/2 when the body starts with the bytes 131, 80 (the compressed term tag), and delegates all other calls to GRPC.Codec.Erlpack.
Mitigazioni temporanee
Da applicare solo se non è possibile aggiornare subito:
- Ridurre l'esposizione del componente vulnerabile (segmentazione, accesso solo da reti fidate) finché la patch non è applicata.
Verifica
- Individuare tutti gli asset con il prodotto interessato (inventario, scanner di vulnerabilità, CMDB).
- Confrontare la versione installata con quelle indicate sopra.
- Applicare l'aggiornamento in un ambiente di test, poi in produzione; riavviare i servizi se richiesto.
- Ripetere la scansione per confermare la correzione.
Configurazioni interessate
| Vendor | Prodotto | Versioni vulnerabili | Corretta in |
|---|---|---|---|
| elixir-grpc | grpc | ≥ 0.4.0 < 1.0.0 | 1.0.0 |
| elixir-grpc | grpc_core | ≥ 1.0.0 < 1.1.0 | 1.1.0 |
Riferimenti
- Riferimentohttps://cna.erlef.org/cves/CVE-2026-121808.html
- Riferimentohttps://github.com/elixir-grpc/grpc/commit/0332faae5f5e132314794dbfdae5edecbccea292
- Riferimentohttps://github.com/elixir-grpc/grpc/commit/25bcc569fe2cc4478531a6c546c923205fc751c9
- Riferimentohttps://github.com/elixir-grpc/grpc/commit/d6bc56ac75dfb6c02db2099909210a37c9be8db6
- Riferimentohttps://github.com/elixir-grpc/grpc/security/advisories/GHSA-xxp9-7hp4-rqwp
- Riferimentohttps://osv.dev/vulnerability/EEF-CVE-2026-121808