{"id":"CVE-2021-43843","published":"2021-12-20T21:15:12Z","modified":"2024-08-04T04:10:16Z","title":"Insufficient patch for Regular Expression Denial of Service (ReDoS) to jsx-slack v4.5.1","vendor":"yhatt","product":"jsx-slack","tier":"tail","description":{"text":"jsx-slack is a package for building JSON objects for Slack block kit surfaces from JSX. The maintainers found the patch for CVE-2021-43838 in jsx-slack v4.5.1 is insufficient tfor protection from a Regular Expression Denial of Service (ReDoS) attack. If an attacker can put a lot of JSX elements into `<blockquote>` tag _with including multibyte characters_, an internal regular expression for escaping characters may consume an excessive amount of computing resources. v4.5.1 passes the test against ASCII characters but misses the case of multibyte characters. jsx-slack v4.5.2 has updated regular expressions for escaping blockquote characters to prevent catastrophic backtracking. It is also including an updated test case to confirm rendering multiple tags in `<blockquote>` with multibyte characters.","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.01979,"percentile":0.8087,"provenance":"source"},"cwes":[{"id":"CWE-400","name":"Uncontrolled Resource Consumption"},{"id":"CWE-1333","name":"Inefficient Regular Expression Complexity"}],"references":[{"url":"https://github.com/yhatt/jsx-slack/security/advisories/GHSA-hp68-xhvj-x6j6","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/yhatt/jsx-slack/security/advisories/GHSA-55xv-f85c-248q","tags":["x_refsource_MISC"]},{"url":"https://github.com/yhatt/jsx-slack/commit/46bc88391d89d5fda4ce689e18ca080bcdd29ecc","tags":["x_refsource_MISC"]},{"url":"https://github.com/yhatt/jsx-slack/releases/tag/v4.5.2","tags":["x_refsource_MISC"]}],"priority":{"score":19.9,"factors":[{"name":"EPSS percentile","points":16.17},{"name":"CVSS severity","points":3.71}]},"vendorSlug":"yhatt","affectedVersions":[{"vendor":"yhatt","product":"jsx-slack","versions":["< 4.5.2"]}],"affected":[{"ecosystem":"npm","package":"jsx-slack","vulnerableRanges":["<4.5.2"],"patched":["4.5.2"],"from":["GHSA-hp68-xhvj-x6j6"],"provenance":"source"}],"euvd":{"id":"EUVD-2022-0618","exploited":false,"provenance":"source"},"lineage":{"familyId":"fam-yhatt-jsx-slack-cve-2021-43838","parents":[{"from":"CVE-2021-43838","to":"CVE-2021-43843","relation":"incomplete-fix","confidence":"high","kind":"lineage","evidence":[{"kind":"text","provenance":"source","relation":"incomplete-fix","quote":"The maintainers found the patch for CVE-2021-43838 in jsx-slack v4.5.1 is insufficient tfor protection from a Regular Expression Denial of Service (ReDoS) attack.","from":"CVE.org","in":"CVE-2021-43843"},{"kind":"osv-related","provenance":"source","id":"GHSA-55xv-f85c-248q","via":"related"},{"kind":"osv-related","provenance":"source","id":"GHSA-hp68-xhvj-x6j6","via":"reference","url":"https://github.com/yhatt/jsx-slack/security/advisories/GHSA-55xv-f85c-248q"},{"kind":"version-step","provenance":"source","package":"npm:jsx-slack","fromFixed":"4.5.1","toFixed":"4.5.2","daysApart":3},{"kind":"same-code","provenance":"machine","files":["src/mrkdwn/escape.ts"],"commits":["https://github.com/yhatt/jsx-slack/commit/36e4a10405e4c7745333e245fcc5029c02c7065d","https://github.com/yhatt/jsx-slack/commit/46bc88391d89d5fda4ce689e18ca080bcdd29ecc"],"basis":"rarely changed file"},{"kind":"similar","provenance":"machine","score":0.75,"basis":"same product + CWE + description similarity"}]}],"packageHistory":[{"cve":"CVE-2021-43838","published":"2021-12-17","fixed":"4.5.1","kev":false},{"cve":"CVE-2021-43843","published":"2021-12-20","fixed":"4.5.2","kev":false}],"package":"npm:jsx-slack"}}