{"schemaVersion":3,"id":"CVE-2022-39255","aliases":[],"status":"published","duplicateOf":null,"title":null,"description":"Matrix iOS SDK allows developers to build iOS apps compatible with Matrix. Prior to version 0.23.19, an attacker cooperating with a malicious homeserver can construct messages that legitimately appear to have come from another person, without any indication such as a grey shield. Additionally, a sophisticated attacker cooperating with a malicious homeserver could employ this vulnerability to perform a targeted attack in order to send fake to-device messages appearing to originate from another user. This can allow, for example, to inject the key backup secret during a self-verification, to make a targeted device start using a malicious key backup spoofed by the homeserver. These attacks are possible due to a protocol confusion vulnerability that accepts to-device messages encrypted with Megolm instead of Olm. matrix-ios-sdk version 0.23.19 has been modified to only accept Olm-encrypted to-device messages. Out of caution, several other checks have been audited or added. This attack requires coordination between a malicious home server and an attacker, so those who trust their home servers do not need a workaround. To avoid malicious backup attacks, one should not verify one's new logins using emoji/QR verifications methods until patched.","dates":{"published":"2022-09-28T20:35:10.000Z","modified":"2025-04-23T16:54:34.263Z","reserved":null,"kevAdded":[],"kevDue":[]},"cvss":{"headline":{"score":8.6,"severity":"high","version":"3.1","versionLabel":"v3.1","source":"CVE.org","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:N/I:H/A:N","computed":false,"selection":"backend-summary"},"metrics":[{"version":"3.1","versionLabel":"v3.1","source":"CVE.org","score":8.6,"severity":"high","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:N/I:H/A:N","exploitability":null,"impact":null,"computed":false},{"version":"3.1","versionLabel":"v3.1","source":"NVD","score":7.5,"severity":"high","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N","exploitability":null,"impact":null,"computed":false}]},"epss":{"probability":0.01025,"percentile":0.63007,"severity":"low","asOf":"2026-10-19T00:00:00.000Z","change":{"pp":0.19900000000000004,"baselineDate":"2026-09-19T00:00:00.000Z","baselineScore":0.00826},"history":[{"date":"2026-09-14T00:00:00.000Z","score":0.00826,"percentile":null},{"date":"2026-09-15T00:00:00.000Z","score":0.00826,"percentile":null},{"date":"2026-09-16T00:00:00.000Z","score":0.00826,"percentile":null},{"date":"2026-09-17T00:00:00.000Z","score":0.00826,"percentile":null},{"date":"2026-09-18T00:00:00.000Z","score":0.00826,"percentile":null},{"date":"2026-09-19T00:00:00.000Z","score":0.00826,"percentile":null},{"date":"2026-09-20T00:00:00.000Z","score":0.00826,"percentile":null},{"date":"2026-09-21T00:00:00.000Z","score":0.00826,"percentile":null},{"date":"2026-09-22T00:00:00.000Z","score":0.00833,"percentile":null},{"date":"2026-09-23T00:00:00.000Z","score":0.00833,"percentile":null},{"date":"2026-09-24T00:00:00.000Z","score":0.00833,"percentile":null},{"date":"2026-09-25T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-09-26T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-09-27T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-09-28T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-09-29T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-09-30T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-01T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-02T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-03T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-04T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-05T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-06T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-07T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-08T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-09T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-10T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-11T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-12T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-13T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-14T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-15T00:00:00.000Z","score":0.01025,"percentile":null},{"date":"2026-10-16T00:00:00.000Z","score":0.01025,"percentile":null},{"date":"2026-10-17T00:00:00.000Z","score":0.01025,"percentile":null},{"date":"2026-10-18T00:00:00.000Z","score":0.01025,"percentile":null},{"date":"2026-10-19T00:00:00.000Z","score":0.01025,"percentile":0.63007}],"last30":[{"date":"2026-09-19T00:00:00.000Z","score":0.00826,"percentile":null},{"date":"2026-09-20T00:00:00.000Z","score":0.00826,"percentile":null},{"date":"2026-09-21T00:00:00.000Z","score":0.00826,"percentile":null},{"date":"2026-09-22T00:00:00.000Z","score":0.00833,"percentile":null},{"date":"2026-09-23T00:00:00.000Z","score":0.00833,"percentile":null},{"date":"2026-09-24T00:00:00.000Z","score":0.00833,"percentile":null},{"date":"2026-09-25T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-09-26T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-09-27T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-09-28T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-09-29T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-09-30T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-01T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-02T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-03T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-04T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-05T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-06T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-07T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-08T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-09T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-10T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-11T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-12T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-13T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-14T00:00:00.000Z","score":0.01001,"percentile":null},{"date":"2026-10-15T00:00:00.000Z","score":0.01025,"percentile":null},{"date":"2026-10-16T00:00:00.000Z","score":0.01025,"percentile":null},{"date":"2026-10-17T00:00:00.000Z","score":0.01025,"percentile":null},{"date":"2026-10-18T00:00:00.000Z","score":0.01025,"percentile":null},{"date":"2026-10-19T00:00:00.000Z","score":0.01025,"percentile":0.63007}]},"kev":{"state":"not-listed","entries":[],"listedCount":0,"totalCatalogs":3,"catalogs":[{"source":"cisa","label":"CISA","listed":false,"entry":null},{"source":"enisa","label":"ENISA","listed":false,"entry":null},{"source":"circl","label":"CIRCL","listed":false,"entry":null}]},"ransomware":{"state":"none-recorded","sources":[]},"exploits":[],"exploitCount":0,"weaknesses":[{"id":"CWE-287","name":"Improper Authentication","description":"When an actor claims to have a given identity, the product does not prove or insufficiently proves that the claim is correct.","type":"weakness","status":"Draft","abstraction":"Class","likelihoodOfExploit":"High","url":"https://cwe.mitre.org/data/definitions/287.html"},{"id":"CWE-322","name":"Key Exchange without Entity Authentication","description":"The product performs a key exchange with an actor without verifying the identity of that actor.","type":"weakness","status":"Draft","abstraction":"Base","likelihoodOfExploit":"High","url":"https://cwe.mitre.org/data/definitions/322.html"}],"affected":[{"vendor":"matrix-org","product":"matrix-ios-sdk","name":"matrix-ios-sdk","label":"matrix-ios-sdk","ecosystem":null,"cpePart":"a","purl":null,"purlType":null,"versions":[{"text":"< 0.23.19","noFixRecorded":false,"fixedIn":null}],"versionsText":"< 0.23.19","eol":null,"hubHref":"/vendor/matrix-org/matrix-ios-sdk"},{"vendor":"matrix","product":"software_development_kit","name":"software development kit","label":"software_development_kit","ecosystem":null,"cpePart":"a","purl":null,"purlType":null,"versions":[{"text":"< 0.23.19","noFixRecorded":false,"fixedIn":null}],"versionsText":"< 0.23.19","eol":null,"hubHref":"/vendor/matrix/software_development_kit"}],"affectedCount":2,"eol":{"hasEol":false,"count":0},"references":[{"url":"https://matrix.org/blog/2022/09/28/upgrade-now-to-address-encryption-vulns-in-matrix-sdks-and-clients","label":"matrix.org/blog/2022/09/28/upgrade-now-to-address-encryption-vulns-in-matrix-sdks-and-clients","hostname":"matrix.org","tags":["X Refsource MISC","Vendor Advisory"]},{"url":"https://github.com/matrix-org/matrix-ios-sdk/security/advisories/GHSA-hw6g-j8v6-9hcm","label":"github.com/matrix-org/matrix-ios-sdk/security/advisories/GHSA-hw6g-j8v6-9hcm","hostname":"github.com","tags":["X Refsource CONFIRM","Third Party Advisory"]},{"url":"https://github.com/matrix-org/matrix-ios-sdk/commit/5ca86c328a5faaab429c240551cb9ca8f0f6262c","label":"github.com/matrix-org/matrix-ios-sdk/commit/5ca86c328a5faaab429c240551cb9ca8f0f6262c","hostname":"github.com","tags":["X Refsource MISC","Patch","Third Party Advisory"]},{"url":"https://github.com/matrix-org/matrix-ios-sdk/releases/tag/v0.23.19","label":"github.com/matrix-org/matrix-ios-sdk/releases/tag/v0.23.19","hostname":"github.com","tags":["X Refsource MISC","Release Notes","Third Party Advisory"]}],"lineage":{"upstream":[],"downstream":[],"duplicates":[],"related":[]},"timeline":[{"kind":"published","date":"2022-09-28T20:35:10.000Z","label":"Published","detail":"Vulnerability first disclosed.","source":null},{"kind":"modified","date":"2025-04-23T16:54:34.263Z","label":"Last modified","detail":"Vulnerability information updated.","source":null}],"risk":{"score":35,"level":"medium","profile":"Default","thresholds":{"critical":75,"high":50,"medium":25,"low":10}},"meta":{"dataAsOf":"2026-10-20T09:41:43.688Z","stale":false,"partial":false}}