Loading advisory.
Loading advisory.
fastify vulnerable to denial of service via malicious Content-Type
An attacker can send an invalid Content-Type header that can cause the application to crash, leading to a possible Denial of Service attack. Only the v4.x line is affected.
Published 2022-10-10 00:00 UTC · Modified 2025-04-23 16:51 UTC
Severity and EPSS are shown separately. Helm does not combine them into one score. How tiers work
| Package | Ecosystem | Affected | Fixed in | Upgrade command |
|---|---|---|---|---|
| fastify | npm | >= 4.0.0, < 4.8.1 | 4.8.1 | npm install fastify@4.8.1 |
An attacker can send an invalid Content-Type header that can cause the application to crash, leading to a possible Denial of Service attack. Only the v4.x line is affected.
(This was updated: upon a close inspection, v3.x is not affected after all).
Yes, update to > v4.8.0.
You can reject the malicious content types before the body parser enters in action.
const badNames = Object.getOwnPropertyNames({}.__proto__)
fastify.addHook('onRequest', async (req, reply) => {
for (const badName of badNames) {
if (req.headers['content-type'].indexOf(badName) > -1) {
reply.code(415)
throw new Error('Content type not supported')
}
}
})See the HackerOne report #1715536
No public exploit code known to Helm's sources (Nuclei templates, Metasploit, Exploit-DB and PoC-in-GitHub). That does not mean none exists.
EPSS went from 0.592 on 2026-11-24 to 0.020 on 2026-11-26, over 2 recorded scores.
| Date | Score | Previous | Model |
|---|---|---|---|
| 2026-11-24 | 0.592 | first score | v2026.06.15 |
| 2026-11-26 | 0.020 | 0.592 | v2026.06.15 |