Advisory

GHSA-49wp-qq6x-g2rf

Also known as: CVE-2020-28482, SNYK-JS-FASTIFYCSRF-1062044

Summary

Cross-site Request Forgery in fastify-csrf

Details

The package fastify-csrf before 3.0.0 has a set of issues that affect its ability to do CSRF protection.

  1. The generated cookie used insecure defaults, and did not have the httpOnly flag on: cookieOpts: { path: '/', sameSite: true }
  2. The CSRF token was available in the GET query parameter

Severity

High Basis: The source's own band: HIGH

Dates

Published
2021-01-20 21:30 UTC
Modified
2026-07-08 06:49 UTC

Affected packages and fixes

fastify-csrf

npm · All systems

Affected

  • introduced 0, fixed 3.0.0 (semver)

Fixed versions

3.0.0

Fix

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: GitHub Advisory Database (reviewed advisories) · CC BY 4.0

Sources & licences