CVE-2022-39287
JavaScript vulnerability analysis and mitigation

Overview

tiny-csrf, a Node.js cross-site request forgery (CSRF) protection middleware, was found to have a critical vulnerability in versions prior to 1.1.0. The vulnerability was discovered and disclosed on October 7, 2022, identified as CVE-2022-39287. The core issue was that CSRF tokens were transmitted in clear text as cookies were not encrypted, potentially exposing them to malicious attackers (GitHub Advisory, NVD).

Technical details

The vulnerability stemmed from the lack of encryption for cookies containing CSRF tokens. The fix implemented in version 1.1.0 introduced AES-256-CBC encryption algorithm for cookie protection, requiring a 32-character secret key. The update also expanded default CSRF protection to cover POST, PUT, and PATCH requests (GitHub Commit).

Impact

The vulnerability could allow malicious attackers to read CSRF tokens directly, potentially compromising the CSRF protection mechanism and enabling cross-site request forgery attacks (GitHub Advisory).

Mitigation and workarounds

The vulnerability was addressed in commit 8eead6d and included in version 1.1.0. Users are strongly advised to upgrade to version 1.1.0 or later, as there are no known workarounds for this security issue (GitHub Advisory).

Additional resources


SourceThis report was generated using AI

Related JavaScript vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2025-67731HIGH8.7
  • JavaScriptJavaScript
  • servify-express
NoYesDec 12, 2025
CVE-2025-67718HIGH8.7
  • JavaScriptJavaScript
  • formio
NoYesDec 11, 2025
CVE-2025-65513HIGH7.5
  • JavaScriptJavaScript
  • mcp-fetch-server
NoNoDec 09, 2025
CVE-2025-67716MEDIUM5.7
  • JavaScriptJavaScript
  • @auth0/nextjs-auth0
NoYesDec 11, 2025
CVE-2025-67490MEDIUM5.4
  • JavaScriptJavaScript
  • @auth0/nextjs-auth0
NoYesDec 10, 2025

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management