JLSEC-2026-1660: When writing a long cookie name and value to a Netscape cookie jar, a remote HTTP server can make...
When writing a long cookie name and value to a Netscape cookie jar, a remote HTTP server can make curl write a record that exceeds its line-length parsing limit. Consequently, any subsequent curl invocation reading from that same cookie jar using --cookie silently aborts parsing prematurely upon encountering the too long line, ignoring all subsequent valid cookies in the file.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
julia/LibCURL_jllto a version that resolves this vulnerability.Fixed in 8.23.0+0
Event History
Child vulnerabilities
Contains the following vulnerabilities.
Frequently Asked Questions
What conditions are required for exploitation?
A remote HTTP server must be able to cause curl to write a cookie with a sufficiently long name and value into a Netscape-format cookie jar. A later curl invocation must read that same jar using --cookie.
What is the practical impact after a malformed cookie record is written?
Curl silently stops parsing the cookie jar when it reaches the overlong record. Valid cookies located after that record are ignored, which can affect subsequent requests that rely on them.
How can I determine whether a cookie jar is affected?
Inspect Netscape cookie jar files used with --cookie for an excessively long cookie record. If curl encounters such a line, cookies appearing later in the file will not be loaded.
What can be done if updating is not immediately possible?
Remove the overlong cookie record from the affected Netscape cookie jar, or replace the jar with a clean file. Avoid reusing cookie jars that a remote HTTP server can populate with attacker-controlled cookie names and values.