Skip to content

chore(deps): update dependency shell-quote to ^1.12.0 [security] - #3998

Open
renovate[bot] wants to merge 1 commit into
mainfrom
renovate-npm-shell-quote-vulnerability
Open

renovate[bot] wants to merge 1 commit into
mainfrom
renovate-npm-shell-quote-vulnerability

Conversation

@renovate

@renovate renovate Bot commented Oct 25, 2026

Copy link
Copy Markdown
Contributor

This PR contains the following updates:

Package Change Age Confidence
shell-quote ^1.9.0 → ^1.12.0 age confidence

shell-quote: quote() command injection via a line terminator in a token after a { comment } token

CVE-2026-102422 / GHSA-pqg4-j6r4-53mv

More information

Details

Impact

quote() emits a { comment } token as # followed by its text, which comments out the rest of the shell line, including the opening quote of any later string token. A line terminator in that later string ends the comment, and the rest of the string is parsed as shell input:

quote(['echo', 'ok', { comment: 'x' }, 'a\nid;#']);
// echo ok #x 'a
// id;#'

Passed to sh, bash, dash, ksh, or zsh, this runs id.

parse() emits a comment token for a # in the middle of a word (for example http://example.com/#frag), so callers that combine parse() output with another untrusted string, such as quote(parse(untrustedCommand).concat(untrustedArg)), are affected. The fix for CVE-2026-9277 rejected line terminators in the comment's own text, but not in the tokens after it.

Exploitation requires an attacker-controlled string containing a line terminator that follows a { comment } token in the same quote() call.

Patches

Fixed in v1.11.0: quote() throws a TypeError when a string after a { comment } token contains a line terminator (\n, \r, U+2028, or U+2029).

Workarounds

Drop every token after a { comment } token before calling quote(), or reject line terminators in untrusted strings. Separately, do not append other shell text after quote() output that contains a comment, since the comment swallows it.

Severity

  • CVSS Score: 9.2 / 10 (Critical)
  • Vector String: CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

References

This data is provided by the GitHub Advisory Database (CC-BY 4.0).


Release Notes

ljharb/shell-quote (shell-quote)

v1.12.0

Compare Source

Fixed
  • [New] parse: support here-documents (<<) #31
Commits
  • [New] parse: support tab-stripping here-documents (<<-) dbfac37
  • [New] parse: support output process substitution (>() 2053315
  • [New] parse: support the case test-next terminator (;;&) 7d688b9
  • [New] parse: support the case fall-through terminator (;&) f27010e
  • [New] parse: support redirecting output despite noclobber (>|) b78d19c
  • [New] parse: support opening a file for reading and writing (<>) 21cc333
  • [New] parse: support redirecting stdout and stderr (&>) 6ad6cd2
  • [New] parse: support appending stdout and stderr (&>>) 90cde9c
  • [Dev Deps] update @ljharb/eslint-config 3a7b4ae

v1.11.0

Compare Source

Fixed
  • [Refactor] quote: drop a replace that can never match in the single-quote branch #15
  • [New] parse: support bash ANSI-C quoting ($'...') #32
Commits
  • [Fix] quote: reject line terminators in tokens after a comment 6002b2e
  • [Fix] parse: preserve text after special shell parameters 81b08a5
  • [Fix] parse: an escaped backslash does not escape the character after it d708019
  • [Fix] quote: preserve ! in arguments that also contain ' ad39927
  • [Fix] parse: treat $_name as a variable name, not $_ followed by text 28f88cd
  • [Fix] quote: preserve empty glob patterns 35c9b97
  • [Fix] quote: escape ~ in glob patterns to prevent shell tilde-expansion 239d49c
  • [Dev Deps] update @ljharb/eslint-config, auto-changelog, eslint, evalmd b1e406e
  • [meta] npmignore some files ebfc308
  • [actions] add permissions 3429b0d
  • [actions] set least-privilege cache-mode 36f2394
  • [Dev Deps] update eslint 6de9a41

v1.10.0

Compare Source

Merged
  • [New] parse: add opt-in splitUnquoted option for shell field-splitting of unquoted expansions #1
Commits
  • [Fix] parse: match nested ${...} braces so nested parameter expansion is consumed as one substitution c0842c8
  • [Tests] parse: pin single-quote literalness and unmatched-quote handling a0d03e3
  • [readme] remove the space in js code fences so evalmd evaluates them 2116fa3
  • [Tests] quote: pin conservative escaping of =, @, ^, ,, :, ! (#​11) 1c36f3f
  • [readme] document that quote outputs POSIX quoting, not cmd.exe/PowerShell 100e96e
  • [readme] document parse's supported parameter-expansion subset e1c75cd
  • [Fix] parse: a backslash inside single quotes must not escape the closing quote 5d460a3
  • [readme] fix stale example outputs 2de86f5
  • [Tests] quote: pin that a backslash with whitespace is not doubled in single quotes (#​14) 190e236
  • [readme] quote: use output verbatim; do not re-quote it (#​11) 1b36468
  • [Refactor] parse: fix swapped SINGLE_QUOTE/DOUBLE_QUOTE variable names 801af5c
  • [types] fix an error TS v6 ignores but v7 fails on 59bbf8b
  • [Dev Deps] update @arethetypeswrong/cli, evalmd a04d475
  • [Dev Deps] update @arethetypeswrong/ci, eslint d390f9a
  • [Tests] quote: the tilde test escapes every ~, not just a leading one (#​9) 617d119

Configuration

📅 Schedule: (UTC)

  • Branch creation
    • At any time (no schedule defined)
  • Automerge
    • At any time (no schedule defined)

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate Bot added the dependencies Pull requests that update a dependency label Oct 25, 2026
@netlify

netlify Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for brilliant-pasca-3e80ec canceled.

Name Link
🔨 Latest commit f302fba
🔍 Latest deploy log https://app.netlify.com/projects/brilliant-pasca-3e80ec/deploys/6b06cb40acd1328d9ec4d27e

@github-actions

github-actions Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

🚀 Performance Test Results

Test Configuration:

  • VUs: 4
  • Duration: 1m0s

Test Metrics:

  • Requests/s: 47.03
  • Iterations/s: 15.67
  • Failed Requests: 0.00% (0 of 2830)
📜 Logs

> performance@1.0.0 run-tests:testenv /home/runner/work/rafiki/rafiki/test/performance
> ./scripts/run-tests.sh -e test -k -q --vus 4 --duration 1m

Cloud Nine GraphQL API is up: http://localhost:3101/graphql
Cloud Nine Wallet Address is up: http://localhost:3100/
Happy Life Bank Address is up: http://localhost:4100/
cloud-nine-wallet-test-backend already set
cloud-nine-wallet-test-auth already set
happy-life-bank-test-backend already set
happy-life-bank-test-auth already set
     data_received..................: 1.0 MB 17 kB/s
     data_sent......................: 2.2 MB 36 kB/s
     http_req_blocked...............: avg=10.29µs  min=2.43µs   med=5.76µs   max=3.18ms   p(90)=7.01µs   p(95)=7.86µs  
     http_req_connecting............: avg=594ns    min=0s       med=0s       max=1.03ms   p(90)=0s       p(95)=0s      
     http_req_duration..............: avg=84.3ms   min=7.84ms   med=68.86ms  max=466.91ms p(90)=143.74ms p(95)=165.28ms
       { expected_response:true }...: avg=84.3ms   min=7.84ms   med=68.86ms  max=466.91ms p(90)=143.74ms p(95)=165.28ms
     http_req_failed................: 0.00%  ✓ 0         ✗ 2830
     http_req_receiving.............: avg=107.32µs min=29.24µs  med=89.47µs  max=1.67ms   p(90)=138.4µs  p(95)=208.33µs
     http_req_sending...............: avg=47.14µs  min=9.88µs   med=26.87µs  max=4.26ms   p(90)=50.8µs   p(95)=75.7µs  
     http_req_tls_handshaking.......: avg=0s       min=0s       med=0s       max=0s       p(90)=0s       p(95)=0s      
     http_req_waiting...............: avg=84.15ms  min=7.63ms   med=68.7ms   max=466.82ms p(90)=143.62ms p(95)=165.17ms
     http_reqs......................: 2830   47.032714/s
     iteration_duration.............: avg=254.92ms min=166.53ms med=242.83ms max=946.94ms p(90)=308.45ms p(95)=335.49ms
     iterations.....................: 943    15.672032/s
     vus............................: 4      min=4       max=4 
     vus_max........................: 4      min=4       max=4 

@renovate
renovate Bot force-pushed the renovate-npm-shell-quote-vulnerability branch from f873925 to 48240e7 Compare November 5, 2026 19:08
@renovate
renovate Bot force-pushed the renovate-npm-shell-quote-vulnerability branch 2 times, most recently from 162f4be to d5357d6 Compare November 20, 2026 20:10
@renovate
renovate Bot force-pushed the renovate-npm-shell-quote-vulnerability branch from d5357d6 to f302fba Compare November 25, 2026 11:49

This branch has not been deployed

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

Labels

dependencies Pull requests that update a dependency

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants