GHSA-MWP9-4838-C7FR
Unauthenticated resource exhaustion through unbounded Accept-Language ranges
CVSS:3.1/AV:N/AC:L/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-MWP9-4838-C7FR divulgada · CVSS 7.5 (GitHub) | |
| Remediación | Parche v0.13.49 | github.com/daptin/daptin · 0 d desde divulgación | |
| Monitoreo | Detectada | Ingresó al índice | |
| Monitoreo | Verificada | Última verificación contra las fuentes |
Summary
Daptin's pre-authentication language middleware passed an unbounded number of comma-separated `Accept-Language` entries to `golang.org/x/text/language.ParseAcceptLanguage`. The previous complexity guard counted hyphens and underscores, but did not limit header length or the number of language ranges. Repeated short language tags or wildcard entries therefore bypassed that guard and caused substantial CPU and transient memory consumption. Malformed values could also be copied in full to error logs.
The report was independently reproduced and is confirmed valid. The fix is released in Daptin 0.13.49.
Impact
An unauthenticated network client can submit a large `Accept-Language` header on routes using the language middleware. Parsing allocates and sorts entries before authentication. Repeated requests can exhaust CPU and memory through allocation and garbage-collection pressure. Logging malformed headers adds a disk-consumption vector. Ordinary request-rate limits do not bound the work performed for each request.
This advisory covers comma-separated range inflation remaining after the separator-only hardening in commit `2d709509`. That earlier hardening addressed the underscore/hyphen form described by GHSA-rhj7-vh3v-mcq6 / CVE-2026-62160 https://github.com/daptin/daptin/security/advisories/GHSA-rhj7-vh3v-mcq6.
Affected versions
Daptin versions before 0.13.49 containing the language middleware are affected, including 0.13.48. The comma-count and logging problems also existed before the separator-only fix.
Package: `github.com/daptin/daptin` (Go).
Patched version and behavior
Upgrade to 0.13.49 or later. The shared language preference parser now enforces these limits before invoking the upstream parser:
- At most 8 KiB of input.
- At most 32 comma-separated language ranges, including wildcard ranges.
- At most 32 combined hyphen/underscore separators, retaining the previous protection.
Oversized or overly complex headers use the configured default language. The same parsing bounds apply to the configured default. Both middleware and direct calls use the same validation path. Malformed-header diagnostics are generic DEBUG messages and do not include the submitted header.
Fix: 895e7071 https://github.com/daptin/daptin/commit/895e7071.
Release: v0.13.49 https://github.com/daptin/daptin/releases/tag/v0.13.49.
Docker users should pull `daptin/daptin:v0.13.49` or a later fixed version and recreate their containers using that image. Pulling an image alone does not replace an existing running container.
Maintainer verification
A controlled local Go parser microbenchmark using approximately 1 MiB inputs reproduced the amplification:
| Input | Before fix: allocated bytes / allocations | After fix: allocated bytes / allocations |
|---|---:|---:|
| Repeated `en,` entries | 127,570,184 / 1,048,645 | 312 / 6 |
| Repeated wildcard entries | 159,445,096 / 1,048,650 | 312 / 6 |
These measurements describe additional parsing allocations, not the total memory required to receive an HTTP request. Timing depends on the host and is not used as the regression assertion.
Regression coverage verifies byte, range, wildcard, and separator boundaries; bounded allocation for oversized input; preservation of normal browser preferences and authentication denial; and absence of raw header contents in logs. A real-server HTTP test reproduced the log leak on the previous binary and passed on the fixed binary. The full Go test suite, affected-package race tests, and vet passed with `GOWORK=off`.
Temporary mitigation
Until upgraded, remove `Accept-Language` at a trusted ingress proxy so Daptin uses its configured default language. Do not rely on request-rate limits alone to eliminate the per-request amplification.
Credit
Thanks to @lanjianchun https://github.com/lanjianchun for reporting the vulnerability.
Desglose de métricas
Rangos afectados
Estado del parche por paquete
| Paquete / producto | Estado | Corregida en | Desde divulgación | Última versión |
|---|---|---|---|---|
gogithub.com/daptin/daptin |
Corregida | v0.13.49 | 0 d | v0.13.57 no afectada |
0.13.49v0.13.49Arsenal público
Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.
https://github.com/daptin/daptin/security/advisories/GHSA-mwp9-4838-c7frLas referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.
