CVE-2026-29045: Hono Hono Vulnerable To Arbitrary File Vulnerability

HIGH
Advisory Identifier: GHSA-q5qw-h33p-qvwr
CVSS 7.5
CWE-177
Published
Advisory Summary

CVE-2026-29045 is a HIGH (CVSS 7.5) hono vulnerable to arbitrary file vulnerability (CWE-177: Improper Handling of URL Encoding (Hex Encoding)) affecting Hono libraries in the npm ecosystem. The issue involves hono vulnerable to arbitrary file access via servestatic vulnerability. Remediation is available by upgrading affected packages to version 4.12.4.

CVE-2026-29045 at a Glance

CVE Identifier CVE-2026-29045
GHSA Identifier GHSA-q5qw-h33p-qvwr
Severity HIGH
CVSS v3.1 Base Score 7.5
CWE Classification CWE-177: Improper Handling of URL Encoding (Hex Encoding)
Affected Product Hono
Package Ecosystem npm
Published Date
Last Updated

Security Impact

CVSS: 7.5

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity None (I:N)
Availability None (A:N)

How to Fix CVE-2026-29045

To remediate this vulnerability, upgrade all affected Hono dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

hono fixed: 4.12.4
npm install hono@4.12.4
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

npm ls hono

How to Check if You Are Affected

To determine whether your Node.js application is affected by CVE-2026-29045, inspect your project dependencies using npm:

npm ls hono

Analyze the terminal output to locate any version of Hono in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 4.12.4), your application is affected.

Note: The npm ls hono command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-177: Improper Handling of URL Encoding (Hex Encoding), where the product does not properly handle when all or part of an input has been url encoded. In Hono, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

## Summary When using `serveStatic` together with route-based middleware protections (e.g. `app.use('/admin/*', ...)`), inconsistent URL decoding allowed protected static resources to be accessed without authorization. The router used `decodeURI`, while `serveStatic` used `decodeURIComponent`. This mismatch allowed paths containing encoded slashes (`%2F`) to bypass middleware protections while still resolving to the intended filesystem path. ## Details The routing layer preserved `%2F` as a literal string, while `serveStatic` decoded it into `/` before resolving the file path. Example: Request: `/admin%2Fsecret.html` - Router sees: `/admin%2Fsecret.html` → does not match `/admin/*` - Static handler resolves: `/admin/secret.html` As a result, static files under the configured static root could be served without triggering route-based protections. This only affects applications that both: - Protect subpaths using route-based middleware, and - Serve files from the same static root using `serveStatic`. This does **not** allow access outside the static root and is **not** a path traversal vulnerability. ## Impact An unauthenticated attacker could bypass route-based authorization for protected static resources by supplying paths containing encoded slashes. Applications relying solely on route-based middleware to protect static subpaths may have exposed those resources.

CVE-2026-29045 Affected Hono Versions

1 component(s)
Fixed Versions:
4.12.4
Product / Package Ecosystem Affected Versions Fixed Version
hono
npm
< 4.12.4
4.12.4

References

Frequently Asked Questions

What is CVE-2026-29045?
CVE-2026-29045 is a security vulnerability in Hono involving Hono vulnerable to arbitrary file access via serveStatic vulnerability under CWE-177: Improper Handling of URL Encoding (Hex Encoding).
Which Hono versions are affected?
Affected versions include releases prior to 4.12.4 across affected packages: hono.
What version fixes CVE-2026-29045?
Upgrading to 4.12.4 (or the latest patched release for your respective branch) resolves the vulnerability.
Is hono affected?
Yes, hono is affected in releases prior to 4.12.4. Upgrade your dependency to 4.12.4 or later.
What is the CVSS score of CVE-2026-29045?
CVE-2026-29045 has a CVSS v3.1 base score of 7.5 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N.
What CWE is associated with CVE-2026-29045?
CVE-2026-29045 is classified under CWE-177: Improper Handling of URL Encoding (Hex Encoding) (The product does not properly handle when all or part of an input has been URL encoded.).
How can I check npm dependencies for CVE-2026-29045?
Run the dependency tree command: 'npm ls hono'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-q5qw-h33p-qvwr",
  "modified" : "2026-03-05T15:26:34Z",
  "published" : "2026-03-04T19:48:00Z",
  "aliases" : [ "CVE-2026-29045" ],
  "summary" : "Hono vulnerable to arbitrary file access via serveStatic vulnerability ",
  "details" : "## Summary\n\nWhen using `serveStatic` together with route-based middleware protections (e.g. `app.use('/admin/*', ...)`), inconsistent URL decoding allowed protected static resources to be accessed without authorization.\n\nThe router used `decodeURI`, while `serveStatic` used `decodeURIComponent`. This mismatch allowed paths containing encoded slashes (`%2F`) to bypass middleware protections while still resolving to the intended filesystem path.\n\n\n## Details\n\nThe routing layer preserved `%2F` as a literal string, while `serveStatic` decoded it into `/` before resolving the file path.\n\nExample:\n\nRequest: `/admin%2Fsecret.html`\n\n- Router sees: `/admin%2Fsecret.html` → does not match `/admin/*`\n- Static handler resolves: `/admin/secret.html`\n\nAs a result, static files under the configured static root could be served without triggering route-based protections.\n\nThis only affects applications that both:\n\n- Protect subpaths using route-based middleware, and\n- Serve files from the same static root using `serveStatic`.\n\nThis does **not** allow access outside the static root and is **not** a path traversal vulnerability.\n\n\n## Impact\n\nAn unauthenticated attacker could bypass route-based authorization for protected static resources by supplying paths containing encoded slashes.\n\nApplications relying solely on route-based middleware to protect static subpaths may have exposed those resources.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "hono"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "4.12.4"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/honojs/hono/security/advisories/GHSA-q5qw-h33p-qvwr"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-29045"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/honojs/hono/commit/6a0607a929d888893f0c91d92dce2fcfdb3662a3"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/honojs/hono"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-177" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-03-04T19:48:00Z",
    "nvd_published_at" : "2026-03-04T23:16:10Z"
  }
}