CVE-2021-23392
JavaScript vulnerability analysis and mitigation

Overview

The package locutus before version 2.0.15 contains a Regular Expression Denial of Service (ReDoS) vulnerability identified as CVE-2021-23392. The vulnerability was discovered in the gopher_parsedir function and was disclosed on April 5, 2021, with a patch released on May 27, 2021. The vulnerability affects all versions of the locutus package prior to version 2.0.15 running on Node.js (Snyk Advisory, NVD).

Technical details

The vulnerability exists in the gopher_parsedir function which uses a vulnerable regular expression pattern for parsing. The original regex pattern /^(.)(.?)\t(.?)\t(.?)\t(.?)\u000d\u000a$/ was susceptible to ReDoS attacks. This was fixed by changing the pattern to /^(.)(\t)\t(\t)\t(\t)\t(\t)\r\n$/ to prevent catastrophic backtracking. The vulnerability has a CVSS v3.1 base score of 7.5 (HIGH) according to NVD, while Snyk rates it at 5.3 (MEDIUM) (NVD, GitHub Commit).

Impact

When exploited, this vulnerability can lead to a Denial of Service condition through excessive CPU consumption. The attack can cause the service to process requests very slowly, with processing time increasing exponentially based on input size. This can result in reduced performance or partial service availability (Snyk Advisory).

Exploitability

The vulnerability can be exploited by sending specially crafted input to the gopher_parsedir function. A proof-of-concept exploit exists that demonstrates how an attacker can trigger the ReDoS condition by creating a string with multiple tab characters. The attack requires no special privileges or user interaction to execute (Snyk Advisory).

Mitigation and workarounds

The recommended mitigation is to upgrade the locutus package to version 2.0.15 or higher, which contains the security fix. The fix involves modifying the regular expression pattern used in the gopher_parsedir function to prevent catastrophic backtracking (GitHub PR, GitHub Commit).

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-2026-73421CRITICAL9.1
  • JavaScript logoJavaScript
  • next-auth
NoYesAug 13, 2026
CVE-2026-73420CRITICAL9.1
  • JavaScript logoJavaScript
  • next-auth
NoYesAug 13, 2026
CVE-2026-73305HIGH8.8
  • JavaScript logoJavaScript
  • @budibase/server
NoNoAug 13, 2026
CVE-2026-73408HIGH7.6
  • JavaScript logoJavaScript
  • @budibase/server
NoNoAug 13, 2026
CVE-2026-73428MEDIUM4.6
  • JavaScript logoJavaScript
  • action_text-trix
NoYesAug 13, 2026

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