Advisory

GHSA-mp7c-m3rh-r56v

Also known as: CVE-2025-59160

Summary

matrix-js-sdk has insufficient validation when considering a room to be upgraded by another

Details

Impact
matrix-js-sdk before 38.2.0 has insufficient validation of room predecessor links in MatrixClient::getJoinedRooms, allowing a remote attacker to attempt to replace a tombstoned room with an unrelated attacker-supplied room.

Patches
The issue has been patched and users should upgrade to 38.2.0.

Workarounds
Avoid using MatrixClient::getJoinedRooms in favour of getRooms() and filtering upgraded rooms separately.

Severity

Medium Basis: The source's own band: MODERATE

Dates

Published
2025-09-16 20:18 UTC
Modified
2025-09-22 22:59 UTC

Affected packages and fixes

matrix-js-sdk

npm · All systems

Affected

  • introduced 0, fixed 38.2.0 (semver)

Fixed versions

38.2.0

Fix

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: GitHub Advisory Database (reviewed advisories) · CC BY 4.0

Sources & licences