{"id":"CVE-2021-23354","published":"2021-03-12T15:10:16Z","modified":"2024-09-17T03:32:43Z","title":"Regular Expression Denial of Service (ReDoS)","vendor":null,"product":null,"tier":"tail","description":{"text":"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.","provenance":"source","from":"CVE.org"},"cvss":{"score":5.3,"severity":"MEDIUM","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.02176,"percentile":0.82763,"provenance":"source"},"cwes":[],"references":[{"url":"https://snyk.io/vuln/SNYK-JS-PRINTF-1072096","tags":["x_refsource_MISC"]},{"url":"https://github.com/adaltas/node-printf/pull/32","tags":["x_refsource_MISC"]},{"url":"https://github.com/adaltas/node-printf/issues/31","tags":["x_refsource_MISC"]}],"priority":{"score":20.3,"factors":[{"name":"EPSS percentile","points":16.55},{"name":"CVSS severity","points":3.71}]},"affectedVersions":[{"vendor":"n/a","product":"printf","versions":[">= unspecified, < 0.6.1"]}],"affected":[{"ecosystem":"npm","package":"printf","vulnerableRanges":["<0.6.1"],"patched":["0.6.1"],"from":["GHSA-xfhp-gmh8-r8v2"],"provenance":"source"}],"summary":{"text":"The printf package before 0.6.1 contains a Regular Expression Denial of Service (ReDoS) flaw in the regex used by lib/printf.js, whose vulnerable pattern has cubic worst-case time complexity. An attacker with network access and no authentication or user interaction can submit input that triggers this worst-case matching behaviour, causing excessive processing time that degrades availability.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T07:16:23Z"},"euvd":{"id":"EUVD-2021-0725","exploited":false,"provenance":"source"}}