Skip to main content

Shescape EUVDEUVD-2026-57527

| CVE-2026-73413 HIGH
Uncontrolled Resource Consumption (CWE-400)
2026-08-12 GitHub_M GHSA-gm3r-q2wp-hw87
8.7
CVSS 4.0 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Submit oversized crafted payload
  2. Delivery
    Reach application endpoint invoking Shescape API
  3. Exploit
    Default flagProtection processes null-dash fragments
  4. Execution
    Quadratic join loop exhausts CPU cycles
  5. Persist
    Server becomes unresponsive
  6. Impact
    Deny service to legitimate users

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A06:2025 - Insecure Design
ASVS 5.0
V2 - Validation and Business Logic Resource consumption limits
MITRE ATT&CK

1 technique across 1 tactic: Impact

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires that attacker-controlled input reaches any of Shescape's four public APIs - escape, escapeAll, quote, or quoteAll - without a prior length restriction. Flag protection must be active, but this is the library default (flagProtection unspecified or explicitly true), so no non-default configuration is needed. The attacker must be able to supply input long enough to trigger meaningful quadratic slowdown; the PoC uses 32,000 repetitions (~64,000 characters). Exploitation is limited by any upstream input validation in the consuming application that bounds string length before calling Shescape. Whether the vulnerable API endpoint requires application-level authentication depends entirely on the application, not on Shescape itself - the library imposes no authentication of its own.

Impact

The CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:N/UI:N/VA:H) scores 8.7, reflecting network-accessible exploitation with no authentication, no attack prerequisites, and high availability impact. There is no confidentiality or integrity effect. No EPSS score was provided in the input data, so exploitation probability cannot be quantified numerically. KEV status is negative - no confirmed active exploitation by CISA. However, the GHSA advisory includes a fully functional, copy-paste-ready PoC with exact payload and measured impact, making exploitation trivial for any attacker who can reach an application endpoint that forwards untrusted input to Shescape. Since flag protection is the default, the exposure is as wide as the library's deployment footprint - no misconfiguration is required. The primary real-world limiting factor is that an attacker must be able to supply unbounded input to a Shescape API call; applications enforcing input length limits before calling the library would not be exposed.

Exploit ScenarioDerived

An attacker submits an HTTP request body containing a string of 32,000 \u0000- repetitions to a web application that passes unbounded user input through Shescape's default-configured escape or quote API. Shescape's quadratic flag-protection loop spends approximately 20 seconds processing the payload, as confirmed by the public PoC in GHSA-gm3r-q2wp-hw87. Repeating this request at modest frequency saturates server CPU, causing denial of service for legitimate users with no authentication or elevated privilege required.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.3% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Aug 12, 2026

Quadratic-time CPU exhaustion in Shescape's flag-protection loop allows any attacker who can supply untrusted input to the escape, escapeAll, quote, or quoteAll APIs to cause denial of service without authentication or special configuration. Affected npm package versions 2.1.11-2.1.13 and 3.0.0 are vulnerable by default because flagProtection is enabled in the default configuration. The GHSA advisory includes a working proof-of-concept demonstrating approximately 20 seconds of processing time for a 32,000-repeat null-dash payload, and patched releases 2.1.14 and 3.0.1 are available; no active exploitation has been confirmed (not in CISA KEV).

RemediationAI

Upgrade to shescape v2.1.14 or v3.0.1, both confirmed available as tagged releases at https://github.com/ericcornelissen/shescape/releases/tag/v2.1.14 and https://github.com/ericcornelissen/shescape/releases/tag/v3.0.1 respectively. The vendor recommends migrating to v3 given v2's end-of-life date of 2026-09-28; a migration guide is available in the Shescape repository. If an immediate upgrade is not feasible, two compensating controls are available per the vendor advisory: (1) restrict the maximum length of untrusted input before passing it to any Shescape API - this directly breaks the quadratic scaling but requires determining a safe bound for the application; or (2) strip all content before the last - character in untrusted inputs before processing - this is a narrower workaround that alters input and may not be appropriate for all use cases. Versions below 2.0.0 will not receive patches and must be upgraded.

Affected VersionsENISA

shescape 3.0.0, < 3.0.1
shescape 2.1.11, < 2.1.14

Affected Packages

npm shescape fix: 2.1.14, 3.0.1

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in npm

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

Shescape is a Node.js npm library (package shescape, CPE: cpe:2.3:a:ericcornelissen:shescape:*:*:*:*:*:*:*:*, authored by ericcornelissen) that safely escapes shell arguments for child process calls. The root cause is CWE-400 (Uncontrolled Resource Consumption) in the compose function within src/internal/compose.js. When flagProtection is active, the pre-patch implementation splits the argument into fragments via flagFn, then enters a while-loop that calls rest.join('') on each iteration to reconstruct the string - an O(n) operation repeated O(n) times for n flag fragments, yielding O(n²) total complexity. An input of 32,000 \u0000- repetitions (each pair constituting a flag fragment boundary) drives approximately 20 seconds of CPU time per the PoC. The patch replaces this with an index-based traversal (for (; idx < fragments.length - 2; idx += 2)) followed by a single fragments.slice(idx).join('') call outside the loop, reducing complexity to O(n).

Know when Shescape gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (GitHub_M) PRIMARY 8.7 HIGH
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
vuln.today AI 7.5 HIGH

Network-reachable via default configuration with no authentication (PR:N); sole impact is high availability loss from CPU exhaustion with no scope change.

3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
4.0 AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
None
Vulnerable system: Availability
High
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

2
Patch available
Aug 12, 2026 - 21:17 EUVD
CVE Published
Aug 12, 2026 - 19:40 cve.org
HIGH 8.7

DescriptionCVE.org

Shescape is a simple shell escape library for JavaScript. From 2.1.11 until 2.1.14 and 3.0.1, the flag-protection loop in compose in src/internal/compose.js repeatedly joins and slices flag fragments when flagProtection is enabled, which is the default, making processing quadratic in input size across the escape, escapeAll, quote, and quoteAll APIs. An attacker who can supply a large untrusted input containing many flag fragments can consume CPU and cause denial of service. This issue is fixed in versions 2.1.14 and 3.0.1.

Blast Radius

ecosystem impact
† from your stack dependencies † transitive graph · vuln.today resolves 4-path depth
  • 1 npm packages depend on shescape (1 direct, 0 indirect)

Ecosystem-wide dependent count for version 2.1.11.

Executive ViewAI

Why It Matters

Shescape npm package versions 2.1.11-2.1.13 and 3.0.0 contain a denial-of-service vulnerability with publicly available exploit code that exhausts CPU resources through the default flag-protection APIs, causing application unavailability. Any organization using affected versions is at risk when processing untrusted input. Patched versions 2.1.14 and 3.0.1 are available and should be deployed immediately.

Business Impact: High
Compensating Controls

Vendor-released patch: version 2.1.14 and version 3.0.1. No interim mitigations are available; immediate patching is required to eliminate this denial-of-service risk.

Threat Intelligence Overview

EPSS Score
0.3%
Top 74% exploitable
Prevalence
Low
niche npm shell-escaping library, not infrastructure-level software
Threat Intel
1
1 source
Data Quality
6 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA GitHub VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.3%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
Yes
Human Impact
High
Technical Impact
Partial

Priority Score

44
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +44
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.

CVE-2022-31180 CRITICAL POC
9.8 Aug 01

Shescape is a simple shell escape package for JavaScript. Rated critical severity (CVSS 9.8), this vulnerability is remo

CVE-2022-31179 CRITICAL POC
9.8 Aug 01

Shescape is a simple shell escape package for JavaScript. Rated critical severity (CVSS 9.8), this vulnerability is remo

CVE-2023-40185 HIGH POC
8.6 Aug 23

shescape is simple shell escape library for JavaScript. Rated high severity (CVSS 8.6), this vulnerability is remotely e

CVE-2021-21384 HIGH POC
7.8 Mar 19

shescape is a simple shell escape package for JavaScript. Rated high severity (CVSS 7.8), this vulnerability is low atta

CVE-2022-25918 HIGH POC
7.5 Oct 27

The package shescape from 1.5.10 and before 1.6.1 are vulnerable to Regular Expression Denial of Service (ReDoS) via the

CVE-2022-36064 HIGH POC
7.5 Sep 06

Shescape is a shell escape package for JavaScript. Rated high severity (CVSS 7.5), this vulnerability is remotely exploi

CVE-2022-24725 MEDIUM POC
5.5 Mar 03

Shescape is a shell escape package for JavaScript. Rated medium severity (CVSS 5.5), this vulnerability is low attack co

CVE-2026-73414 CRITICAL
9.2 Aug 12

Command injection in Shescape (npm shell-escaping library) versions below 2.1.14 and the 3.0.x line below 3.0.1 allows a

CVE-2023-35931 MEDIUM POC
4.3 Jun 23

Shescape is a simple shell escape library for JavaScript. Rated medium severity (CVSS 4.3), this vulnerability is remote

CVE-2026-32094 MEDIUM
6.5 Mar 11

Shescape versions prior to 2.1.10 fail to properly escape square-bracket glob patterns in Bash, BusyBox sh, and Dash, al

CVE-2026-73412 MEDIUM
6.3 Aug 12

Incomplete Zsh special-character escaping in Shescape allows unauthenticated attackers who control input strings to bypa

CVE-2026-73411 MEDIUM
6.3 Aug 12

Incomplete tilde-escaping in Shescape's Dash shell mode allows attacker-controlled input to bypass sanitization and trig

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy