{"id":"CVE-2021-43838","aliases":["GHSA-55xv-f85c-248q"],"url":"https://o3.security/vulnerability/CVE-2021-43838","summary":"Regular Expression Denial of Service (ReDoS) in jsx-slack","details":"jsx-slack v4.5.1 and earlier versions are vulnerable to a regular expression denial-of-service (ReDoS) attack. \n\n### Impact\n\nIf attacker can put a lot of JSX elements into `<blockquote>` tag, an internal regular expression for escaping characters may consume an excessive amount of computing resources.\n\n```javascript\n/** @jsxImportSource jsx-slack */\nimport { Section } from 'jsx-slack'\n\nconsole.log(\n  <Section>\n    <blockquote>\n      {[...Array(40)].map((_, i) => (\n        <p>{i + 1}</p>\n      ))}\n    </blockquote>\n  </Section>\n)\n```\n\n### Patches\n\n_See also: https://github.com/yhatt/jsx-slack/security/advisories/GHSA-hp68-xhvj-x6j6_\n\njsx-slack v4.5.2 has updated regular expressions to prevent catastrophic backtracking.\n\njsx-slack v4.5.1 also had patched a workaround. It has no problems to contents with ASCII characters, but _still vulnerable to contents with multibyte characters_. (https://github.com/yhatt/jsx-slack/commit/36e4a10405e4c7745333e245fcc5029c02c7065d)\n\n### References\n\n- https://nvd.nist.gov/vuln/detail/CVE-2021-43838\n- https://github.com/yhatt/jsx-slack/commit/36e4a10405e4c7745333e245fcc5029c02c7065d\n\n### Credits\n\nThanks to @hieki for finding out this vulnerability.","published":"2021-12-17T19:15:07.683Z","modified":"2026-07-09T10:11:52.884820Z","cvss":{"score":7.5,"severity":"HIGH","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"},"epss":null,"cisaKev":null,"exploitsKnown":1,"affectedPackages":[{"ecosystem":"npm","name":"jsx-slack","fixedVersion":"4.5.1"}],"fix":{"url":"https://github.com/yhatt/jsx-slack/commit/36e4a10405e4c7745333e245fcc5029c02c7065d","label":"yhatt/jsx-slack@36e4a10"},"references":[{"type":"FIX","url":"https://github.com/yhatt/jsx-slack/commit/36e4a10405e4c7745333e245fcc5029c02c7065d"},{"type":"FIX","url":"https://github.com/yhatt/jsx-slack/security/advisories/GHSA-55xv-f85c-248q"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2021-43838"},{"type":"WEB","url":"https://github.com/yhatt/jsx-slack"}],"provenance":{"sources":["OSV.dev","FIRST.org (EPSS)"],"lastVerified":"2026-07-09T10:11:52.884820Z"}}