Descrizione
Allocation of Resources Without Limits or Throttling vulnerability in Plug.Parsers.MULTIPART in elixir-plug plug allows an unauthenticated remote attacker to exhaust memory via a multipart request body built from parts without headers, or from header lines without a name and a value. The parser charges the :length limit only with the name and value bytes of each part header and the bytes of each part body. The part delimiter, the header separator, and the line endings cost nothing. In lib/plug/parsers/multipart.ex, Plug.Parsers.MULTIPART.parse_multipart_headers/5 keeps an entry for every part without a content-disposition header, together with its header list, until the whole body is read. A request made of such parts does not reach the limit at any size, and the parser process holds a multiple of the request size in memory until parsing completes. Any endpoint that uses Plug.Parsers with the :multipart parser is reachable. This issue affects plug: from 1.13.0 before 1.20.4.
Come correggere
Priorità: Bassa — correggere con la manutenzione ordinaria. Motivazione: CVSS 6.9, EPSS 0.5% (percentile 45).
Versioni da aggiornare
Il record non riporta ancora i prodotti e le versioni corrette (analisi NVD in corso). Consultare l'advisory del vendor nei riferimenti.
Mitigazioni temporanee
Da applicare solo se non è possibile aggiornare subito:
- Applicare rate limiting e limiti sulle risorse a monte del servizio e monitorarne la disponibilità.
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.
Riferimenti
- Riferimentohttps://cna.erlef.org/cves/CVE-2026-120287.html
- Riferimentohttps://github.com/elixir-plug/plug/commit/3d3fb645323643935c6c94863c1b3edfd62e2828
- Riferimentohttps://github.com/elixir-plug/plug/commit/497913f2a6d744d693e98e96c5b9c6d88c265695
- Riferimentohttps://github.com/elixir-plug/plug/commit/e06acbd3d381931f23cbde7d763136c9ccb091ac
- Riferimentohttps://github.com/elixir-plug/plug/security/advisories/GHSA-qj4r-jh2r-rw3f
- Riferimentohttps://osv.dev/vulnerability/EEF-CVE-2026-120287