Command Injection in hot-formula-parser
Critical severity
GitHub Reviewed
Published
May 6, 2020
to the GitHub Advisory Database
•
Updated Jan 9, 2023
Description
Reviewed
May 6, 2020
Published to the GitHub Advisory Database
May 6, 2020
Last updated
Jan 9, 2023
Versions of
hot-formula-parserprior to 3.0.1 are vulnerable to Command Injection. The package fails to sanitize values passed to theparsefunction and concatenates it in anevalcall. If a value of the formula is supplied by user-controlled input it may allow attackers to run arbitrary commands in the server.Parsing the following formula creates a
testfile in the present directory:"SUM([(function(){require('child_process').execSync('touch test')})(),2])"Recommendation
Upgrade to version 3.0.1 or later.
References