{"id":"CVE-2016-10541","aliases":["GHSA-qg8p-v9q4-gh34"],"url":"https://o3.security/vulnerability/CVE-2016-10541","summary":"Potential Command Injection in shell-quote","details":"Affected versions of `shell-quote` do not properly escape command line arguments, which may result in command injection if the library is used to escape user input destined for use as command line arguments.\n\n\n\n## Proof of Concept:\n\nThe following characters are not escaped properly: `>`,`;`,`{`,`}`\n\nBash has a neat but not well known feature known as \"Bash Brace Expansion\", wherein a sub-command can be executed without spaces by running it between a set of `{}` and using the `,` instead of ` ` to seperate arguments. Because of this, full command injection is possible even though it was initially thought to be impossible. \n\n```\n   const quote = require('shell-quote').quote;\n   console.log(quote(['a;{echo,test,123,234}']));\n   // Actual                    \"a;{echo,test,123,234}\"\n   // Expected                  \"a\\;\\{echo,test,123,234\\}\"\n   // Functional Equivalent     \"a; echo 'test' '123' '1234'\"\n```\n\n\n\n## Recommendation\n\nUpdate to version 1.6.1 or later.","published":"2018-05-31T20:29:01.503Z","modified":"2026-08-27T18:52:39.994520Z","cvss":{"score":9.8,"severity":"CRITICAL","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"},"epss":{"score":0.02251,"percentile":0.82077,"asOf":"2026-09-17"},"cisaKev":null,"exploitsKnown":1,"affectedPackages":[{"ecosystem":"npm","name":"shell-quote","fixedVersion":"1.6.1"}],"fix":null,"references":[{"type":"ADVISORY","url":"https://nodesecurity.io/advisories/117"},{"type":"EVIDENCE","url":"https://github.com/advisories/GHSA-qg8p-v9q4-gh34"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2016-10541"},{"type":"WEB","url":"https://www.npmjs.com/advisories/117"}],"provenance":{"sources":["OSV.dev","FIRST.org (EPSS)"],"lastVerified":"2026-08-27T18:52:39.994520Z"}}