{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2021-23354","id":"CVE-2021-23354","title":"Regular Expression Denial of Service (ReDoS)","description":"The package printf before 0.6.1 are vulnerable to Regular Expression Denial of Service (ReDoS) via the regex string /\\%(?:\\(([\\w_.]+)\\)|([1-9]\\d*)\\$)?([0 +\\-\\]*)(\\*|\\d+)?(\\.)?(\\*|\\d+)?[hlL]?([\\%bscdeEfFgGioOuxX])/g in lib/printf.js. The vulnerable regular expression has cubic worst-case time complexity.","descriptionLong":"The package printf before 0.6.1 are vulnerable to Regular Expression Denial of Service (ReDoS) via the regex string /\\%(?:\\(([\\w_.]+)\\)|([1-9]\\d*)\\$)?([0 +\\-\\]*)(\\*|\\d+)?(\\.)?(\\*|\\d+)?[hlL]?([\\%bscdeEfFgGioOuxX])/g in lib/printf.js. The vulnerable regular expression has cubic worst-case time complexity.","published":"2021-03-12T15:10:16.014Z","updated":"2026-10-20T10:54:32.134543871Z","reserved":"2021-01-08T00:00:00.000Z","status":"Modified","rejected":false,"assigner":"snyk","metric":{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","rating":"medium","source":"snyk"},"metrics":[{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","rating":"medium","source":"snyk"},{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","rating":"medium","source":"snyk.io"},{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","rating":"high","source":"NVD"},{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","rating":"high","source":"OSV"},{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","rating":"high","source":"GitHub"},{"version":"2.0","score":5,"vector":"AV:N/AC:L/Au:N/C:N/I:N/A:P","rating":"medium","source":"NVD"}],"rating":"medium","products":["printf"],"affectedProducts":[{"vendor":"n/a","product":"printf","defaultStatus":null,"versions":[{"lessThan":"0.6.1","status":"affected","version":"unspecified","versionType":"custom"}],"platforms":[]}],"packages":[{"ecosystem":"npm","name":"printf","purl":"pkg:npm/printf","ranges":["<0.6.1"],"fixed":["0.6.1"],"advisory":"GHSA-xfhp-gmh8-r8v2"}],"cwes":["CWE-1333","CWE-400"],"aliases":["GHSA-xfhp-gmh8-r8v2","SNYK-JS-PRINTF-1072096"],"references":[{"url":"https://snyk.io/vuln/SNYK-JS-PRINTF-1072096","tags":["x_refsource_MISC","x_transferred","Broken Link","advisory","web"]},{"url":"https://github.com/adaltas/node-printf/pull/32","tags":["x_refsource_MISC","x_transferred","Patch","Third Party Advisory","fix","web"]},{"url":"https://github.com/adaltas/node-printf/issues/31","tags":["x_refsource_MISC","x_transferred","Exploit","Issue Tracking","Third Party Advisory","report","web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2021-23354","tags":["advisory"]},{"url":"https://github.com/adaltas/node-printf/commit/a8502e7c9b0b22555696a2d8ef67722086413a68","tags":["web"]}],"patchReferenced":true,"fixAvailable":true,"exploitReferenced":true,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":null,"epss":0.02176,"epssPercentile":0.82763,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2021-23354","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2021-23354","ok":true,"note":"Modified"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2021-23354","ok":true,"note":"1 package"},{"name":"GitHub Advisory","url":"https://github.com/advisories/GHSA-xfhp-gmh8-r8v2","ok":true,"note":"GHSA-xfhp-gmh8-r8v2"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2021-23354","ok":true,"note":"scored 2026-11-20"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}