CRLF Injection in form-data <=4.0.5 via unsanitized field names and filenames
CVE-2026-12143 Published on June 12, 2026
form-data does not escape CR/LF/quote in multipart field names and filenames (CRLF injection)
form-data is a library for creating readable multipart/form-data streams. In versions through 4.0.5, the `field` argument to `FormData#append` and the `filename` option are concatenated verbatim into the `Content-Disposition` header without escaping carriage return (CR), line feed (LF), or double-quote (") characters. An application that passes attacker-controlled data as a field name or filename (for example, an API gateway that turns JSON object keys into multipart field names) allows the attacker to terminate the header line and inject additional headers, or to smuggle entire additional multipart parts, into the request the application forwards to a backend. This can let the attacker add or override form fields (e.g. set `is_admin=true`) seen by the downstream parser. This is an instance of CWE-93 (CRLF injection). The fix escapes CR, LF, and `"` as `%0D`, `%0A`, and `%22` in field names and filenames, matching the serialization browsers use per the WHATWG HTML multipart/form-data encoding algorithm. Exploitation requires the consuming application to use untrusted input as a field name or filename; applications that use only fixed/trusted field names are not affected. Fixed in 2.5.6, 3.0.5, and 4.0.6.
Vulnerability Analysis
CVE-2026-12143 can be exploited with network access, and does not require authorization privileges or user interaction. This vulnerability is considered to have a low attack complexity. An automatable proof of concept (POC) exploit exists. The potential impact of an exploit of this vulnerability is considered to have no impact on confidentiality, a high impact on integrity, and no impact on availability.
Weakness Type
What is a CRLF Injection Vulnerability?
The software uses CRLF (carriage return line feeds) as a special element, e.g. to separate lines or records, but it does not neutralize or incorrectly neutralizes CRLF sequences from inputs.
CVE-2026-12143 has been classified to as a CRLF Injection vulnerability or weakness.
Products Associated with CVE-2026-12143
Want to know whenever a new CVE is published for Red Hat products? stack.watch will email you.
Affected Versions
form-data:- Before 2.5.6 is affected.
- Version 3.0.0 and below 3.0.5 is affected.
- Version 4.0.0 and below 4.0.6 is affected.
- Version 4.2.0-13 and below * is unaffected.
- Version 1782840519 and below * is unaffected.
- Version 1782839981 and below * is unaffected.
- Version 1782839193 and below * is unaffected.
- Version 1782838753 and below * is unaffected.
- Version 1782839279 and below * is unaffected.
- Version 1782840539 and below * is unaffected.
- Version 1782841925 and below * is unaffected.
- Version 1782844225 and below * is unaffected.
- Version 1782839658 and below * is unaffected.
- Version 1782838476 and below * is unaffected.
- Version 1782839996 and below * is unaffected.
- Version 1782839494 and below * is unaffected.
- Version 1783357116 and below * is unaffected.
- Version 1783357140 and below * is unaffected.
- Version 1783448184 and below * is unaffected.
- Version 1784210921 and below * is unaffected.
- Version 1783690532 and below * is unaffected.
- Version 1785169013 and below * is unaffected.
- Version 1784724699 and below * is unaffected.
- Version 1784713741 and below * is unaffected.
- Version 1785230147 and below * is unaffected.
- Version 1785245777 and below * is unaffected.
- Version 1784737150 and below * is unaffected.
- Version 1781937133 and below * is unaffected.
- Version 1782287580 and below * is unaffected.
- Version 1782201894 and below * is unaffected.
- Version 1782201833 and below * is unaffected.
- Version 1782201696 and below * is unaffected.
- Version 1782201537 and below * is unaffected.
- Version 1782201851 and below * is unaffected.
- Version 1782201812 and below * is unaffected.
- Version 1782231869 and below * is unaffected.
- Version 1782201466 and below * is unaffected.
- Version 1783750447 and below * is unaffected.
- Version 1783751865 and below * is unaffected.
- Version 1784353904 and below * is unaffected.
- Version 1784351966 and below * is unaffected.
- Version 1783955846 and below * is unaffected.
- Version 1784125838 and below * is unaffected.
Exploit Probability
EPSS (Exploit Prediction Scoring System) scores estimate the probability that a vulnerability will be exploited in the wild within the next 30 days. The percentile shows you how this score compares to all other vulnerabilities.