CVE-2026-47069
CRLF injection in cookie domain/path options in hackney
Weakness Type (CWE)
CWE-93 — CWE-93 Improper Neutralization of CRLF Sequences ('CRLF Injection')
CAPEC
Vulnerability description
Improper Neutralization of CRLF Sequences ('CRLF Injection') vulnerability in benoitc hackney allows HTTP Response Splitting.The hackney_cookie:setcookie/3 function in src/hackney_cookie.erl validates the Name and Value arguments against CRLF and control characters, but concatenates the domain and path options verbatim into the output iolist with no equivalent check. An attacker who controls either option — for example by supplying a Host header value forwarded as the cookie domain, or a request path forwarded as the cookie path — can inject a literal CRLF sequence and arbitrary additional Set-Cookie headers into the HTTP response.
This issue affects hackney: from 0.9.0 before 4.0.1.
Affected
pkg:hex/hackney
| Module | Source File | Routine |
|---|---|---|
hackney_cookie
|
src/hackney_cookie.erl
|
hackney_cookie:setcookie/3
|
pkg:github/benoitc/hackney
| Module | Source File | Routine |
|---|---|---|
hackney_cookie
|
src/hackney_cookie.erl
|
hackney_cookie:setcookie/3
|
| Status | Type | Version | Changes / Fixed in |
|---|---|---|---|
| affected | git ⓘ | 602d5c7f2e
|
< 8e02b99c28
|
References
- https://github.com/benoitc/hackney/security/advisories/GHSA-mp55-p8c9-rfw2 vendor-advisory related
- https://osv.dev/vulnerability/EEF-CVE-2026-47069 related
- https://github.com/benoitc/hackney/commit/8e02b99c28aea1b3fa2ddc0e66f51fe5bb0ac540 patch
Credits
- Finder: Peter Ullrich
- Remediation developer: Benoit Chesneau
- Analyst: Jonatan Männchen
CVE record as JSON:
GET /cves/CVE-2026-47069.json
OSV record as JSON:
GET /osv/EEF-CVE-2026-47069.json