CVE-2026-56762: Hono - Missing Cookie Name Validation in setCookie()
Hono before 4.12.12 does not validate cookie names on the write path in the setCookie(), serialize(), and serializeSigned() functions, allowing invalid characters such as control characters (e.g. \r or \n) when an application passes a user-controlled cookie name. This can produce malformed Set-Cookie header values. In modern runtimes such as Node.js and Cloudflare Workers, such invalid header values are rejected and cause a runtime error before the response is sent, so header injection or response splitting could not be reproduced; the issue primarily affects correctness and robustness, resulting in runtime errors (availability) rather than confirmed header injection.
Affected Software
Event History
Frequently Asked Questions
What is the severity of CVE-2026-56762?
CVE-2026-56762 has a medium severity rating of 5.3.
How do I fix CVE-2026-56762?
You can fix CVE-2026-56762 by upgrading Hono to version 4.12.12 or later.
What is the impact of CVE-2026-56762?
CVE-2026-56762 allows for malformed Set-Cookie headers due to missing cookie name validation.
Which functions are affected by CVE-2026-56762?
The affected functions in CVE-2026-56762 are setCookie(), serialize(), and serializeSigned().
Can CVE-2026-56762 be exploited?
Yes, CVE-2026-56762 can be exploited if an application accepts user-controlled cookie names.