CVE-2026-44456: Hono: bodyLimit() can be bypassed for chunked / unknown-length requests
Summary bodyLimit() does not reliably enforce maxSize for requests without a usable Content-Length (e.g. Transfer-Encoding: chunked). Oversized requests can reach handlers and return 200 instead of 413. Details For chunked / unknown-length requests, bodyLimit() wraps the body in a stream that counts bytes asynchronously, then runs the handler before the size decision is final.
Published May 6, 2026 · Updated May 14, 2026
Affected packages
hono
- Ecosystem
- npm
- Affected
- < 4.12.16
- Fixed in
- 4.12.16
- Check
npm ls hono
Advisory details
From the GitHub Advisory Database (CC BY 4.0).
Summary
bodyLimit() does not reliably enforce maxSize for requests without a usable Content-Length (e.g. Transfer-Encoding: chunked). Oversized requests can reach handlers and return 200 instead of 413.
Details
For chunked / unknown-length requests, bodyLimit() wraps the body in a stream that counts bytes asynchronously, then runs the handler before the size decision is final. The 413 is only applied afterwards by checking c.error.
This lets the limit be bypassed when:
- the handler does not read the body,
- the handler reads only the first chunk(s) and returns, or
- the handler reads the body but swallows the read error in
try/catch.
In all three cases the handler returns 200 before the limit check completes (or its result is observed).
The fix is to enforce the size decision before next() runs, instead of retrofitting the response via c.error afterwards.
Impact
Applications relying on bodyLimit() as a hard boundary can be bypassed: oversized chunked requests can reach handler logic and return successful responses. Per-request data exposure is bounded by maxSize, but the documented guarantee — "oversized requests are rejected before business logic runs" — does not hold.
Credits
- @lalalala5678 (slow chunked / early return variants)
- @Jvr2022 (error handling bypass)
Credited to lalalala5678, Jvr2022.
References
How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. No analysis has been written for this entry yet. Methodology
More npm vulnerabilities
All npm entriesCVE-2026-126355
Hono: `csrf()` does not check requests sent by hyperlink auditing (`text/ping`)
medium5.3Nov 12, 2026CVE-2026-126356
Hono: `validator('form')` skips validation for `multipart/form-data` requests with extra parameters
medium5.3Nov 12, 2026CVE-2026-126357
Hono: `mount()` and `app.mount()` can forward a path that bypasses middleware scoped inside the mount prefix
medium5.3Nov 12, 2026CVE-2026-126358
Hono: RegExpRouter skips wildcard middleware for some route sets and for paths with an encoded line terminator
medium5.3Nov 12, 2026CVE-2026-126359
Hono: `css` helper does not escape a closing tag split between the template and an interpolated value, allowing HTML injection
low3.4Nov 12, 2026CVE-2026-111757
Hono: `serveStatic` decodes the request path a second time, leading to bypass of middleware on static paths
medium5.3Oct 20, 2026
