Security mailing lists by PureSourceCode

CVE-2026-35040

MEDIUM 5.3CVSS 3.1

fast-jwt: Stateful RegExp (/g or /y) causes non-deterministic allowed-claim validation (logical DoS)

fast-jwt provides fast JSON Web Token (JWT) implementation. Prior to 6.2.1, using certain modifiers on RegExp objects in the allowedAud, allowedIss, allowedSub, allowedJti, or allowedNonce options in verify functions can cause certain unintended behaviours. This is because some modifiers are stateful and will cause failures in every second verification attempt regardless of the validity of the token provided. Such modifiers are /g (global matching) and /y (sticky matching). This does NOT allow invalid tokens to be accepted, only for valid tokens to be improperly rejected in some configurations. Instead it causes 50% of valid authentication requests to fail in an alternating pattern. This vulnerability is fixed in 6.2.1.

Published
9 Apr 2026
Last modified
26 Oct 2026
Assigned by
security-advisories@github.com
NVD status
Analyzed
Weakness
CWE-440CWE-697
Also known as
GHSA-3j8v-cgw4-2g6q
Sources
NVDJSONOSV GHSA-3j8v-cgw4-2g6qJSON

Scores

SourceScored byVersionScoreVector / decision
NVD security-advisories@github.com (Secondary) CVSS 3.1 MEDIUM 5.3 CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
OSV GitHub CVSS 3.1 MEDIUM 5.3 CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L

Affected

SourceVendor / ecosystemProduct / packageAffected versionsFixed in
NVD nearform fast-jwt
cpe:2.3:a:nearform:fast-jwt:*:*:*:*:*:node.js:*:*
< 6.2.1 6.2.1
OSV npm fast-jwt < 6.2.1 6.2.1

References

History

  • 25 Nov 2026 21:02 UTC · NVD: first stored (published 9 Apr 2026)
  • 25 Nov 2026 20:10 UTC · OSV: first stored (published 9 Apr 2026)
An unhandled error has occurred. Reload ×

Rejoining the server...

Rejoin failed... trying again in seconds.

Failed to rejoin.
Please retry or reload the page.

The session has been paused by the server.

Failed to resume the session.
Please retry or reload the page.