Skip to content

upgrade shell-quote to 1.9.0 #597

Closed
Closed

Description

@Mayvis

Describe the bug

Image

I use Checkmarx SCA(Software Composition Analysis) to scan my project, and had this CWE-407 issue.

shell-quote prior to 1.8.5 finalizes parsed tokens in parse() using Array.prototype.concat as a reduce accumulator, which reallocates and copies the entire growing array on every iteration. As a result parse() runs in O(n^2) time relative to the number of input tokens. An attacker who can supply an attacker-controlled string to any code path that calls parse() (no shell metacharacters are required; plain space-separated words suffice) can block the single-threaded Node.js event loop for an extended period with a small input, resulting in a denial of service. There is no code execution or data disclosure; impact is to availability only. Fixed in 1.8.5.

Activity

  1. changed the title [-]CWE-407 | Inefficient Algorithmic Complexity[/-] [+]Dependency [email protected] has CWE-407 issue[/+] on Jun 30, 2026
  2. changed the title [-]Dependency [email protected] has CWE-407 issue[/-] [+][High][CVSS 8.7] Algorithmic Complexity DoS in [email protected] parse() (CWE-407)[/+] on Jun 30, 2026
  3. changed the title [-][High][CVSS 8.7] Algorithmic Complexity DoS in [email protected] parse() (CWE-407)[/-] [+]upgrade shell-quote to 1.9.0[/+] on Jun 30, 2026
  4. paescuj commented on Jun 30, 2026

    @paescuj
    Collaborator

    Updated via #599. Please note that concurrently is NOT affected by the mentioned vulnerability (GHSA-395f-4hp3-45gv) as the impacted parse() function isn't used at all in our codebase.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions