# CVE-2022-39236: matrix-js-sdk improper beacon event handling causing availability issues

Source: https://junglewise.ai/threats/cve-2022-39236-matrix-js-sdk-improper-beacon-event-handling-causing-availability  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2022-09-29. Updated: 2026-09-25  
License: CC BY 4.0 with a link back

CVE-2022-39236 · Severity: low · CVSS 3.1 · Published 2022-09-29

The matrix-js-sdk is a JavaScript library used by Matrix messaging applications to communicate with Matrix servers. Malformed beacon events can cause the SDK to malfunction or exclude/corrupt data, making chat applications appear to work normally while silently losing or corrupting user messages and other runtime data.

Technologies: [matrix-js-sdk (npm)](https://junglewise.ai/threats/technologies/matrix-js-sdk). Vendors: [npm](https://junglewise.ai/threats/vendors/npm).

## Quick answers

**Is CVE-2022-39236 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2022-39236 being exploited in the wild.

**How severe is CVE-2022-39236?** Low severity, with a CVSS score of 3.1, published 29 September 2022.

**Which products and versions are affected?** matrix-js-sdk (npm) SEMVER:introduced=17.1.0-rc.1,fixed=19.7.0.

**Is there a fix for CVE-2022-39236?** Yes. matrix-js-sdk (npm): upgrade to 19.7.0 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2022-39236 attacked?** It is attacked over the network, in a software library.

**Am I affected by CVE-2022-39236?** Check whether you run matrix-js-sdk (npm) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- matrix-js-sdk (npm): upgrade to 19.7.0 or later

  ```sh
  npm install matrix-js-sdk@19.7.0
  ```


## Technical details

This vulnerability is a logic error in how matrix-js-sdk processes beacon events defined in Matrix Spec Proposal 3488. Improperly formed beacon events can trigger improper data handling in the SDK, disrupting normal operation and potentially causing data loss or corruption. The attack vector is network-based and requires low privileges (an authenticated user or external attacker sending malformed events). The SDK may continue to appear functional while excluding or corrupting runtime data. The vulnerability affects versions 17.1.0-rc.1 through 19.6.x and is patched in v19.7.0. Workarounds include redacting malicious events, clearing storage, or restarting the client.

## Affected products

- matrix-org matrix-js-sdk 17.1.0-rc.1 through 19.6.x

## Identifiers

- CVE-2022-39236
- GHSA-hvv8-5v86-r45x

## Timeline

- 2022-09-28: disclosed: Publicly disclosed on GitHub and NVD
- 2022-09-28: patched: Fixed in matrix-js-sdk v19.7.0
- 2022-09-29: other: OSV entry published

## References

- [https://github.com/matrix-org/matrix-js-sdk/security/advisories/GHSA-hvv8-5v86-r45x](https://github.com/matrix-org/matrix-js-sdk/security/advisories/GHSA-hvv8-5v86-r45x)

## Related threats

- [matrix-js-sdk insufficient validation in room upgrade handling](https://junglewise.ai/threats/cve-2025-59160-matrix-js-sdk-insufficient-validation-in-room-upgrade-handling)
- [matrix-js-sdk MXC URI path traversal](https://junglewise.ai/threats/cve-2024-50336-matrix-js-sdk-mxc-uri-path-traversal)
- [Matrix JavaScript SDK key history sharing vulnerability](https://junglewise.ai/threats/cve-2024-47080-matrix-javascript-sdk-key-history-sharing-vulnerability)
- [matrix-js-sdk infinite recursion in room upgrade history](https://junglewise.ai/threats/cve-2024-42369-matrix-js-sdk-infinite-recursion-in-room-upgrade-history)
- [matrix-js-sdk unauthorized eavesdropping in group calls](https://junglewise.ai/threats/cve-2023-29529-matrix-js-sdk-unauthorized-eavesdropping-in-group-calls)
