Junglewise Threat Intelligence

CVE-2019-10769: safer-eval sandbox breakout and arbitrary code execution

CVE-2019-10769 · Severity: low · CVSS 3.1 · Published 2019-12-11

Technologies: safer-eval (npm). Vendors: npm.

Executive brief

safer-eval is a Node.js library designed to safely evaluate code expressions in a sandboxed environment. A critical vulnerability allows attackers to escape the sandbox and execute arbitrary code on the system. Any application using safer-eval to process untrusted user input is at risk of complete system compromise.

Technical details

safer-eval contains an insufficient input validation and improper sandbox isolation vulnerability (CWE-20, CWE-94) that allows attackers to break out of the intended sandbox environment. The package fails to properly restrict access to the main JavaScript context, allowing an attacker to bypass intended security boundaries. No authentication or special preconditions are required—any user input passed to safer-eval can be exploited. A successful exploit grants an attacker arbitrary code execution with the privileges of the Node.js process. No patch has been released; the maintainers recommend switching to alternative packages such as vm2.

Affected products

  • npm safer-eval 0.0.0 and all versions up to 1.3.6

Timeline

  • 2019-12-06: disclosed: Original disclosure
  • 2019-12-11: advisory: GHSA-v63x-xc9j-hhvq published

References

Related threats