Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessAttacker sends crafted HTTP input to application
-
DeliveryApplication uses input as cookie name or value without sanitization
-
ExploitUnsanitized value passed to cow_cookie:cookie/1
-
ExecutionMalicious characters serialized into Cookie: request header
-
PersistPoisoned header forwarded to upstream server or proxy
-
ImpactDownstream server processes phantom cookie or split HTTP request
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization CRLF sequence sanitization
|
| Exploitation Conditions | Exploitation requires that the target application passes attacker-influenced strings as cookie name or value arguments to cow_cookie:cookie/1 without first sanitizing them - the CVSS 4.0 AV:L and AT:P metrics reflect that the attacker does not send a packet directly to this library function but must control data within the application's own processing pipeline. The most realistic vector is a web application that reads user-supplied values (query parameters, form fields, upstream response headers) and re-encodes them into outbound Cookie headers via cowlib. Factors that limit exploitation: (1) the application must forward attacker-controlled strings to cow_cookie:cookie/1 without validation - an application-level sanitization step anywhere in the chain breaks the attack; (2) the injected cookie smuggling impact depends on the receiving server treating injected cookie fields as authoritative, which varies by downstream server behavior; (3) SSVC automatable: no confirms the attack cannot be scripted against the library in isolation. Applications that only pass internally-generated or already-decoded cookie values to this function are not affected. |
| Impact | The provided CVSS 4.0 vector (AV:L/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:L/SA:N, score 2.1) classifies the attack vector as Local with an attack prerequisite present (AT:P), reflecting that exploitation requires attacker-controlled data to flow into cow_cookie:cookie/1 within the application process rather than via a direct network request to the library. This is consistent with SSVC automatable: no - the exploit chain cannot be scripted end-to-end without a cooperating application code path that passes unsanitized external input to the encoder. EPSS at 0.02% and SSVC exploitation: none further confirm absence of observed weaponization. The RCE tag in the source metadata is inconsistent with CWE-93 and the described impact (header injection, cookie smuggling); it appears to be a miscategorization and should not factor into risk prioritization. Real-world impact is limited to integrity manipulation (VI:L/SI:L) against downstream servers that trust injected cookies - a meaningful but bounded risk in proxy and API-gateway architectures. No confidentiality or availability impact is claimed or inferable from available data. |
| Exploit ScenarioDerived | An attacker sends a crafted HTTP request to a cowlib-based application that forwards cookies derived from user input to an upstream API or proxy - for example, a session token read from a query parameter is passed as a cookie value to cow_cookie:cookie/1 without sanitization. By embedding '; admin=1' in the input, the attacker introduces a phantom admin cookie that the upstream server interprets as a legitimate separate cookie attribute, potentially escalating privileges on the downstream system. Alternatively, embedding '\r\nX-Forwarded-For: 127.0.0.1\r\n' into a cookie value causes the serialized header to split, injecting an arbitrary trusted-IP header into the proxied request. No public proof-of-concept exploit has been identified, though the patch commit includes four concrete test cases (cookie_crlf_injection_test_/0) that directly demonstrate these injection vectors. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Jul 23, 2026
CRLF injection in cowlib's cow_cookie:cookie/1 encoder allows an attacker who controls cookie name or value strings to inject semicolons, commas, CR, LF, or TAB characters into a serialized Cookie: request header, enabling cookie smuggling and HTTP request header splitting against downstream proxies or servers. Affected applications are those built on cowlib 2.9.0 and later that pass externally-influenced data directly to this function without prior sanitization - notably Cowboy-based Erlang web services acting as reverse proxies or API gateways. No public exploit has been identified and no active exploitation is confirmed; EPSS stands at 0.02% (6th percentile) and CISA KEV status is absent, consistent with SSVC exploitation: none.
RemediationAI
The primary fix is to apply the upstream patch commit 177953dd51540da11090666c1f007214127a1144 from the erlef fork of cowlib (https://github.com/erlef/cowlib/commit/177953dd51540da11090666c1f007214127a1144); a separately tagged released version incorporating this commit is not independently confirmed from available data, so consumers should verify with the erlef maintainers or pin to a commit SHA past this point. As a compensating control where patching is not immediately feasible, applications should sanitize or reject cookie name and value strings containing CR (\r), LF (\n), semicolon, comma, VT (\013), FF (\014), or TAB characters before passing them to cow_cookie:cookie/1 - this mirrors exactly the validation the patch adds at the library level. This application-layer guard can be implemented without modifying cowlib but requires auditing all call sites that construct cookie lists from external input; missing a single call site leaves the gap open. Note that values produced by the existing decoder functions (parse_cookie_name/1, parse_cookie_value/1) are already validated and safe to re-encode; the risk is confined to application code that constructs cookie pairs independently from external data.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
cowlib is a low-level Erlang HTTP/1.x and HTTP/2 parsing and serialization library, most prominently used by the Cowboy HTTP server and its ecosystem. CWE-93 (Improper Neutralization of CRLF Sequences) identifies the root cause: the cow_cookie:cookie/1 encoder concatenates user-supplied name-value pairs into a Cookie: request header using iolist construction without asserting that the inputs are free of forbidden characters - specifically semicolon, comma, CR (\r), LF (\n), VT (\013), FF (\014), and TAB. The decoder side (parse_cookie_name/1, parse_cookie_value/1) and the setcookie/3 response-cookie builder already enforce this validation via binary:match/2 guards, making the cookie/1 client-header encoder the sole unguarded path. The patch commit (177953dd51540da11090666c1f007214127a1144 in the erlef fork) mirrors the existing decoder validation directly into the encoder and also backfills missing guards for the Domain and Path attributes in setcookie/3's attributes/1 helper. CPE cpe:2.3:a:ninenines:cowlib:*:*:*:*:*:*:*:* covers all versions from 2.9.0 per the advisory.
Know when Cowlib gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:L/SA:N
AV:N reflects realistic network-reachable attack path via application input; AC:H captures the prerequisite that unsanitized user data must flow to cow_cookie:cookie/1; S:C because injected headers affect a downstream scoped system.
Primary rating from Vendor (EEF).
CVSS VectorVendor: EEF
Lifecycle Timeline
3DescriptionCVE.org
Improper Neutralization of CRLF Sequences ('CRLF Injection') vulnerability in ninenines cowlib allows HTTP request splitting and cookie smuggling via unvalidated cookie name and value fields.
cow_cookie:cookie/1 in cowlib builds a client-side Cookie: request header from a list of name-value pairs without validating either field. An attacker who controls the cookie names or values passed to this function can inject ;, ,, CR, LF, or TAB characters into the serialized header. This enables two classes of attack: cookie smuggling within a single header (e.g. injecting "; admin=1" to introduce a phantom cookie that the receiving server treats as authentic) and HTTP request header splitting (injecting CRLF to append arbitrary headers or smuggle a complete second request against a shared upstream proxy). The decoder side (parse_cookie_name/1, parse_cookie_value/1) and setcookie/3 already validate and reject these characters; the encoder alone is missing the check.
This issue affects cowlib from 2.9.0.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.
An unauthenticated remote peer can exhaust memory on an HTTP/2 endpoint built on ninenines cowlib 2.7.0 or later by send
Remote denial of service in ninenines cowlib (the HTTP support library behind the Cowboy web server and Gun client) from
Unauthenticated remote denial of service in ninenines cowlib (versions 0.1.0 through 2.16.0) allows a single crafted SPD
Link header directive smuggling in ninenines cowlib (2.9.0+) enables attacker-controlled browsers to initiate out-of-ban
HTTP response splitting in ninenines cowlib allows network-accessible attackers to inject arbitrary HTTP headers when ap
CRLF injection in cowlib's SSE encoder allows an attacker who supplies field values - id, event, data, or comment - cont
EUVD-2026-29193
GHSA-g2wm-735q-3f56
NVD
CVE.org
EPSS
Vulnrichment
VulDB
Exploit-DB