Live threats

All CVEs / Fastify

CVE-2022-41919Fastify

High 8.8 No auth needed

Priority
68
CVSS 3.1
8.8
EPSS
0.5%
probability of exploitation in 30 days · percentile 37
Auth required
No
Published
Nov 22, 2022
Updated
Jun 17, 2026
Category
Application · Cross-platform
Weakness (CWE)
CWE-352
SSVC (CISA)
Exploitation: none · Automatable: no · Technical impact: partial
Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H

What happens

Fastify is a web framework with minimal overhead and plugin architecture. The attacker can use the incorrect `Content-Type` to bypass the `Pre-Flight` checking of `fetch`. `fetch()` requests with Content-Type’s essence as "application/x-www-form-urlencoded", "multipart/form-data", or "text/plain", could potentially be used to invoke routes that only accepts `application/json` content type, thus bypassing any CORS protection, and therefore they could lead to a Cross-Site Request Forgery attack. This issue has been patched in version 4.10.2 and 3.29.4. As a workaround, implement Cross-Site Request Forgery protection using `@fastify/csrf'.

Original NVD text.

What to do

  1. Apply the vendor's security update for Fastify.
  2. It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.

Affected packages

EcosystemPackageAffected versionsFixed inHow to upgrade
npm fastify ≥ 4.0.0 < 4.10.2 4.10.2 npm install fastify@4.10.2
npm fastify ≥ 3.0.0 < 3.29.4 3.29.4 npm install fastify@3.29.4

Per OSV / GitHub Advisories (GHSA-3fjj-p79j-c9hh). Check the version in your lockfile before upgrading.

Affected products (CPE)

VendorProductVersions
fastifyfastify≥ 3.0.0 < 3.29.4
fastifyfastify≥ 4.0.0 < 4.10.2

Official sources

References

Links published by the sources. Open them with care.