{"id":"CVE-2025-53549","aliases":["EUVD-2025-21024","GHSA-275g-g844-73jh","RUSTSEC-2025-0043","openSUSE-SU-2025:15351-1"],"status":"published","title":"Matrix Rust SDK allows SQL injection in the EventCache implementation","description":"The Matrix Rust SDK is a collection of libraries that make it easier to build Matrix clients in Rust. An SQL injection vulnerability in the EventCache::find_event_with_relations method of matrix-sdk 0.11 and 0.12 allows malicious room members to execute arbitrary SQL commands in Matrix clients that directly pass relation types provided by those room members into this method, when used with the default sqlite-based store backend. Exploitation is unlikely, as no known clients currently use the API in this manner. This vulnerability is fixed in 0.13.","severity":{"version":"4.0","score":5.2,"vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:U","level":"medium","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-10","score":0.0031,"percentile":0.24135,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-89"],"published":"2025-07-10T17:41:16Z","modified":"2026-11-04T02:46:42Z","fixes":[{"ecosystem":"crates.io","package":"matrix-sdk","fixed_in":["0.13.0"],"sources":["ghsa","osv"]},{"ecosystem":"crates.io","package":"matrix-sdk-sqlite","fixed_in":["0.13.0"],"sources":["ghsa","osv"]},{"ecosystem":"openSUSE:Tumbleweed","package":"fractal","fixed_in":["12.beta+14-1.1"],"sources":["osv"]}],"affected":[{"source":"ghsa","ecosystem":"crates.io","package":"matrix-sdk","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0.11.0"},{"fixed":"0.13.0"}]}]},{"source":"ghsa","ecosystem":"crates.io","package":"matrix-sdk-sqlite","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0.11.0"},{"fixed":"0.13.0"}]}]},{"source":"osv","ecosystem":"crates.io","package":"matrix-sdk","ranges":[{"type":"SEMVER","events":[{"introduced":"0.11.0"},{"fixed":"0.13.0"}]}]},{"source":"osv","ecosystem":"crates.io","package":"matrix-sdk-sqlite","ranges":[{"type":"SEMVER","events":[{"introduced":"0.11.0"},{"fixed":"0.13.0"}]}]},{"source":"osv","ecosystem":"crates.io","package":"matrix-sdk-sqlite","ranges":[{"type":"SEMVER","events":[{"introduced":"0.11.0"},{"fixed":"0.13.0"}]}]},{"source":"osv","ecosystem":"openSUSE:Tumbleweed","package":"fractal","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"12.beta+14-1.1"}]}]}],"products":[{"vendor":"matrix-org","product":"matrix-rust-sdk"}],"references":[{"url":"https://github.com/matrix-org/matrix-rust-sdk/security/advisories/GHSA-275g-g844-73jh","tags":["x_refsource_CONFIRM","advisory","web"]},{"url":"https://github.com/matrix-org/matrix-rust-sdk/pull/4849","tags":["x_refsource_MISC","fix","web"]},{"url":"https://github.com/matrix-org/matrix-rust-sdk/commit/d0c01006e4808db5eb96ad5c496416f284d8bd3c","tags":["web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2025-53549","tags":["advisory"]},{"url":"https://rustsec.org/advisories/RUSTSEC-2025-0043.html","tags":["web","advisory"]},{"url":"https://github.com/advisories/GHSA-275g-g844-73jh"},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/53xxx/CVE-2025-53549.json","tags":["advisory"]},{"url":"https://github.com/matrix-org/matrix-rust-sdk","tags":["package"]},{"url":"https://crates.io/crates/matrix-sdk-sqlite","tags":["package"]},{"url":"","tags":["advisory"]},{"url":"https://www.suse.com/security/cve/CVE-2025-53549","tags":["web"]}],"sources":{"cve":[{"id":"CVE-2025-53549","title":"Matrix Rust SDK allows SQL injection in the EventCache implementation","description":"The Matrix Rust SDK is a collection of libraries that make it easier to build Matrix clients in Rust. An SQL injection vulnerability in the EventCache::find_event_with_relations method of matrix-sdk 0.11 and 0.12 allows malicious room members to execute arbitrary SQL commands in Matrix clients that directly pass relation types provided by those room members into this method, when used with the default sqlite-based store backend. Exploitation is unlikely, as no known clients currently use the API in this manner. This vulnerability is fixed in 0.13.","status":"published","published":"2025-07-10T18:28:24.373Z","modified":"2025-07-10T19:02:23.365Z","cvss":[{"version":"4.0","score":5.2,"vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:U","level":"medium","assessor":"cna"}],"cwes":["CWE-89"],"updated_at":"2026-11-02T14:32:49.180768Z"}],"euvd":[{"id":"EUVD-2025-21024","description":"The Matrix Rust SDK is a collection of libraries that make it easier to build Matrix clients in Rust. An SQL injection vulnerability in the EventCache::find_event_with_relations method of matrix-sdk 0.11 and 0.12 allows malicious room members to execute arbitrary SQL commands in Matrix clients that directly pass relation types provided by those room members into this method, when used with the default sqlite-based store backend. Exploitation is unlikely, as no known clients currently use the API in this manner. This vulnerability is fixed in 0.13.","status":"published","published":"2025-07-10T18:28:24Z","modified":"2025-07-10T19:02:23Z","cvss":[{"version":"4.0","score":5.2,"vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:U","level":"medium"}],"updated_at":"2026-11-02T20:32:09.615515Z"}],"ghsa":[{"id":"GHSA-275g-g844-73jh","title":"Matrix Rust SDK vulnerable to SQL Injection through its EventCache implementation","description":"An SQL injection vulnerability in the `EventCache::find_event_with_relations` method of matrix-sdk 0.11 and 0.12 allows malicious room members to execute arbitrary SQL commands in Matrix clients that directly pass relation types provided by those room members into this method, when used with the default sqlite-based store backend. Exploitation is unlikely, as no known clients currently use the API in this manner.\n\n### Workarounds\n\nPassing only trusted (or sanitised) relation types to the `filter` argument of `EventCache::find_event_with_relations()` avoids the issue.\n\n### Patches\n\nThe issue is fixed in matrix-sdk 0.13.\n\n### References\n\nThe issue was introduced in https://github.com/matrix-org/matrix-rust-sdk/pull/4849.","status":"published","published":"2025-07-10T17:41:16Z","modified":"2025-07-11T20:45:36Z","cvss":[{"version":"4.0","score":5.2,"vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:U","level":"medium"}],"cwes":["CWE-89"],"updated_at":"2026-11-02T14:38:49.837727Z"}],"nvd":[{"id":"CVE-2025-53549","description":"The Matrix Rust SDK is a collection of libraries that make it easier to build Matrix clients in Rust. An SQL injection vulnerability in the EventCache::find_event_with_relations method of matrix-sdk 0.11 and 0.12 allows malicious room members to execute arbitrary SQL commands in Matrix clients that directly pass relation types provided by those room members into this method, when used with the default sqlite-based store backend. Exploitation is unlikely, as no known clients currently use the API in this manner. This vulnerability is fixed in 0.13.","status":"published","published":"2025-07-10T19:15:26.683Z","modified":"2026-06-17T09:38:25.76Z","cvss":[{"version":"4.0","score":5.2,"vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:U/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","level":"medium","assessor":"secondary"}],"cwes":["CWE-89"],"updated_at":"2026-11-02T14:11:18.285862Z"}],"osv":[{"id":"CVE-2025-53549","title":"Matrix Rust SDK allows SQL injection in the EventCache implementation","description":"The Matrix Rust SDK is a collection of libraries that make it easier to build Matrix clients in Rust. An SQL injection vulnerability in the EventCache::find_event_with_relations method of matrix-sdk 0.11 and 0.12 allows malicious room members to execute arbitrary SQL commands in Matrix clients that directly pass relation types provided by those room members into this method, when used with the default sqlite-based store backend. Exploitation is unlikely, as no known clients currently use the API in this manner. This vulnerability is fixed in 0.13.","status":"published","published":"2025-07-10T18:28:24.373Z","modified":"2026-11-04T02:46:42.941464133Z","cvss":[{"version":"4.0","score":5.2,"vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:U","level":"medium"}],"cwes":["CWE-89"],"updated_at":"2026-11-04T02:53:57.551196Z"},{"id":"GHSA-275g-g844-73jh","title":"Matrix Rust SDK vulnerable to SQL Injection through its EventCache implementation","description":"An SQL injection vulnerability in the `EventCache::find_event_with_relations` method of matrix-sdk 0.11 and 0.12 allows malicious room members to execute arbitrary SQL commands in Matrix clients that directly pass relation types provided by those room members into this method, when used with the default sqlite-based store backend. Exploitation is unlikely, as no known clients currently use the API in this manner.\n\n### Workarounds\n\nPassing only trusted (or sanitised) relation types to the `filter` argument of `EventCache::find_event_with_relations()` avoids the issue.\n\n### Patches\n\nThe issue is fixed in matrix-sdk 0.13.\n\n### References\n\nThe issue was introduced in https://github.com/matrix-org/matrix-rust-sdk/pull/4849.","status":"published","published":"2025-07-10T17:41:16Z","modified":"2025-07-11T20:45:34Z","cvss":[{"version":"4.0","score":5.2,"vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:U","level":"medium"}],"cwes":["CWE-89"],"updated_at":"2026-11-02T15:46:33.956911Z"},{"id":"openSUSE-SU-2025:15351-1","title":"fractal-12.beta+14-1.1 on GA media","description":"These are all security issues fixed in the fractal-12.beta+14-1.1 package on the GA media of openSUSE Tumbleweed.","status":"published","published":"2025-07-17T00:00:00Z","modified":"2026-03-23T04:53:40.684627Z","updated_at":"2026-11-02T16:58:37.810934Z"},{"id":"RUSTSEC-2025-0043","title":"matrix-sdk-sqlite: SQL injection vulnerability in `SqliteEventCacheStore::find_event_with_relations`","description":"The `SqliteEventCacheStore::find_event_with_relations` function constructs SQL\nqueries using `format!()` with unescaped input, allowing an attacker to inject\narbitrary SQL. This results in a SQL injection vulnerability.","status":"published","published":"2025-07-11T12:00:00Z","modified":"2026-10-12T18:00:10.950538086Z","updated_at":"2026-11-02T15:53:39.971022Z"}]}}
