Ecosyste.ms: Advisories
An open API service providing security vulnerability metadata for many open source software ecosystems.
Security Advisories: GSA_kwCzR0hTQS13OW1oLTV4OGotOTc1NM4AA9m2
Malicious Matrix homeserver can leak truncated message content of messages it shouldn't have access to
Impact
The fix for GHSA-wm4w-7h2q-3pf7 / CVE-2024-32000 included in matrix-appservice-irc 2.0.0 relied on the Matrix homeserver-provided timestamp to determine whether a user has access to the event they're replying to when determining whether or not to include a truncated version of the original event in the IRC message. Since this value is controlled by external entities, a malicious Matrix homeserver joined to a room in which a matrix-appservice-irc bridge instance (before version 2.0.1) is present can fabricate the timestamp with the intent of tricking the bridge into leaking room messages the homeserver should not have access to.
Patches
matrix-appservice-irc 2.0.1 drops the reliance on origin_server_ts
when determining whether or not an event should be visible to a user, instead tracking the event timestamps internally.
Workarounds
It's possible to limit the amount of information leaked by setting a reply template that doesn't contain the original message. See these lines in the configuration file.
References
For more information
If you have any questions or comments about this advisory, please email us at security at matrix.org.
Permalink: https://github.com/advisories/GHSA-w9mh-5x8j-9754JSON: https://advisories.ecosyste.ms/api/v1/advisories/GSA_kwCzR0hTQS13OW1oLTV4OGotOTc1NM4AA9m2
Source: GitHub Advisory Database
Origin: Unspecified
Severity: Moderate
Classification: General
Published: 2 months ago
Updated: 2 months ago
CVSS Score: 4.3
CVSS vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N
Identifiers: GHSA-w9mh-5x8j-9754, CVE-2024-39691
References:
- https://github.com/matrix-org/matrix-appservice-irc/security/advisories/GHSA-w9mh-5x8j-9754
- https://github.com/matrix-org/matrix-appservice-irc/pull/1804
- https://github.com/matrix-org/matrix-appservice-irc/commit/1835e047f269001054be4c68867797aa12372a0f
- https://nvd.nist.gov/vuln/detail/CVE-2024-39691
- https://github.com/matrix-org/matrix-appservice-irc/blob/d5d67d1d3ea3f0f6962a0af2cc57b56af3ad2129/config.sample.yaml#L601-L604
- https://github.com/advisories/GHSA-w9mh-5x8j-9754
Blast Radius: 0.0
Affected Packages
npm:matrix-appservice-irc
Dependent packages: 2Dependent repositories: 1
Downloads: 483 last month
Affected Version Ranges: <= 2.0.0
Fixed in: 2.0.1
All affected versions: 0.1.0, 0.3.0, 0.3.1, 0.4.0, 0.5.0, 0.6.0, 0.7.0, 0.7.1, 0.7.2, 0.8.0, 0.10.1, 0.11.0, 0.11.1, 0.11.2, 0.12.0, 0.13.0, 0.15.2, 0.16.0, 0.17.0, 0.17.1, 0.18.0, 0.19.0, 0.20.1, 0.20.3, 0.21.0, 0.22.0, 0.23.0, 0.24.0, 0.25.0, 0.26.0, 0.26.1, 0.27.0, 0.29.0, 0.30.0, 0.31.0, 0.32.1, 0.35.0, 0.35.1, 0.36.0
All unaffected versions: