CVE-2026-47675
Analyzed Analyzed - Analysis Complete
Hono Cookie SameSite and Priority Header Injection

Publication date: 2026-05-28

Last updated on: 2026-05-29

Assigner: GitHub, Inc.

Description
Hono is a Web application framework that provides support for any JavaScript runtime. Prior to 4.12.21, the serialize() function in hono/cookie validates domain and path options against characters that corrupt Set-Cookie header syntax (;, \r, \n), but does not apply the same validation to sameSite and priority. An application that passes user-controlled input into either option may produce a Set-Cookie response header containing attacker-chosen additional attributes. This vulnerability is fixed in 4.12.21.
CVSS Scores
EPSS Scores
Probability:
Percentile:
Meta Information
Published
2026-05-28
Last Modified
2026-05-29
Generated
2026-06-17
AI Q&A
2026-05-28
EPSS Evaluated
2026-06-16
NVD
EUVD
Affected Vendors & Products
Showing 1 associated CPE
Vendor Product Version / Range
hono hono to 4.12.21 (exc)
Helpful Resources
Exploitability
CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-113 The product receives data from an HTTP agent/component (e.g., web server, proxy, browser, etc.), but it does not neutralize or incorrectly neutralizes CR and LF characters before the data is included in outgoing HTTP headers.
CWE-1287 The product receives input that is expected to be of a certain type, but it does not validate or incorrectly validates that the input is actually of the expected type.
Attack-Flow Graph
AI Quick Actions
Instant insights powered by AI
Compliance Impact

The vulnerability in Hono's cookie serialization function allows attackers to inject additional attributes into Set-Cookie headers by exploiting insufficient validation of the sameSite and priority options. This can lead to cookie attribute injection or HTTP response header injection, potentially overriding security settings or enabling malicious cookies.

Such manipulation of cookies and HTTP headers can undermine security controls that are often required by standards and regulations like GDPR and HIPAA, which mandate protection of user data and secure session management. Therefore, this vulnerability could negatively impact compliance by exposing applications to risks of session hijacking, data leakage, or unauthorized access.

Executive Summary

The CVE-2026-47675 vulnerability affects the Hono web application framework's cookie helper function called serialize(). Prior to version 4.12.21, this function validated the domain and path options to prevent corruption of the Set-Cookie header syntax, but it did not apply the same validation to the sameSite and priority options.

Because of this, if an application passes user-controlled input into either the sameSite or priority options, an attacker can inject additional malicious attributes into the Set-Cookie response header. This can lead to cookie attribute injection or HTTP response header injection.

Impact Analysis

This vulnerability can allow attackers to inject additional attributes into the Set-Cookie header by exploiting the lack of validation on the sameSite and priority options.

Such injection can override security settings on cookies or enable the setting of additional malicious cookies, potentially compromising the security of user sessions or enabling further attacks.

The vulnerability has a moderate severity with a CVSS score of 4.3 and requires user interaction but no special privileges.

Detection Guidance

This vulnerability involves injection of additional attributes into the Set-Cookie response header by passing user-controlled input into the sameSite or priority options in the Hono framework's cookie serialization function.

To detect this vulnerability on your system or network, you should monitor HTTP responses for Set-Cookie headers that contain unexpected or malformed attributes, especially those including semicolons, carriage returns, or line feeds in the sameSite or priority fields.

Commands to help detect this may include using tools like curl or tcpdump to capture and inspect HTTP response headers. For example:

  • Use curl to fetch HTTP headers and look for suspicious Set-Cookie attributes: curl -I http://your-application-url
  • Use tcpdump or Wireshark to capture HTTP traffic and filter for Set-Cookie headers containing unusual characters: tcpdump -A -s 0 'tcp port 80 and (((ip[2:2] - ((ip[0]&0xf)<<2)) - ((tcp[12]&0xf0)>>2)) != 0)'

Additionally, review application code or logs to identify if user input is passed unchecked into the sameSite or priority options of the serialize() function in Hono versions prior to 4.12.21.

Mitigation Strategies

The primary mitigation step is to upgrade the Hono framework to version 4.12.21 or later, where the serialize() function properly validates the sameSite and priority options to prevent injection of malicious characters.

If upgrading immediately is not possible, ensure that any user-controlled input passed to the sameSite and priority options is properly sanitized to exclude characters that can corrupt the Set-Cookie header syntax, such as semicolons, carriage returns, and line feeds.

Additionally, review your application code to avoid passing untrusted input directly into cookie attributes and consider implementing web application firewall (WAF) rules to detect and block suspicious Set-Cookie headers.

Chat Assistant
Ask questions about this CVE
Hi! I’m here to help you understand CVE-2026-47675. Ask me anything about the vulnerability, its impact, or mitigation strategies.
0/70
EPSS Chart