# Trail of Bits security audit 2026: findings and fixes

This page lists all findings of the [Trail of Bits security audit](https://github.com/simplex-chat/simplex-chat/blob/master/docs/SimpleX_Chat_Code_Review_2026_Final_Report_with_Fix_Review.pdf) of SimpleX Chat apps and the simplexmq library, the status assigned by Trail of Bits in its fix review, where and when we fixed each issue, and our comments. See the [blog post](https://simplex.chat/blog/20261121-simplex-chat-security-audit-trail-of-bits-security-process.md) for the overview.

## Summary

Status in the report, as assessed by Trail of Bits in the fix review:

| Severity | Resolved | Partially resolved | Unresolved | Total |
|---|---|---|---|---|
| High | 4 | 2 | 0 | 6 |
| Medium | 11 | 3 | 2 | 16 |
| Low | 27 | 1 | 1 | 29 |
| Informational | 7 | 6 | 11 | 24 |
| **Total** | **49** | **12** | **14** | **75** |

After the fix review, we resolved two more issues in code: TOB-SMPLXCHAT-6 and 8.

## All findings

"Severity" and "Difficulty" are the ratings by Trail of Bits: the impact of the issue, and how hard it is to exploit. "Status" is the status in the Trail of Bits fix review. "Fix and release" lists each fix with the stable release of the apps or servers that first included it; the fixes marked "after the fix review" are not in the report. All fixes are included in v7.1.4.

| ID | Finding | Severity | Difficulty | Status | Fix and release | Our comment |
|---|---|---|---|---|---|---|
| TOB-SMPLXCHAT-35 | Relay channel pending-review subscribers receive visible history before approval | High | Low | Resolved | [#7347](https://github.com/simplex-chat/simplex-chat/pull/7347) v7.1.0 | Resolved: pending members do not receive channel history; admission review is not allowed in channels. |
| TOB-SMPLXCHAT-56 | Host-side path traversal via unsanitized file name in remote control file transfer | High | Low | Resolved | [#7352](https://github.com/simplex-chat/simplex-chat/pull/7352) v7.1.0 | Resolved: remote-control files cannot be written outside the files folder. |
| TOB-SMPLXCHAT-19 | Concurrent SKEY commands can overwrite the queue sender key | High | High | Resolved | [#1844](https://github.com/simplex-chat/simplexmq/pull/1844) v7.1.0 | Resolved: the server installs a sender key only once; a competing SKEY cannot replace it. |
| TOB-SMPLXCHAT-33 | Compromised relay forges verified admin events by injecting a fake high-role member | High | High | Resolved | [#7132](https://github.com/simplex-chat/simplex-chat/pull/7132) v7.0.0 | Resolved: unauthorized privileged members introduced via a relay are rejected. |
| TOB-SMPLXCHAT-34 | Compromised relay installs a fake admin/moderator signing key through unsigned member introductions | High | High | Partially resolved | [#7017](https://github.com/simplex-chat/simplex-chat/pull/7017) v7.0.0<br>[#7883](https://github.com/simplex-chat/simplex-chat/pull/7883) v7.1.0, after the fix review | Mitigated: unsigned introductions cannot grant member or higher roles with a signing key. Since v7.1.0, an owner's promotion that carries a member key different from the stored one is refused. |
| TOB-SMPLXCHAT-39 | P2p group admin forges owner-attributed roster events via unsigned forwarded messages | High | High | Partially resolved | [#7289](https://github.com/simplex-chat/simplex-chat/pull/7289) v7.0.0 | Mitigated: only the admin who introduced the member can still forward such events, an accepted limitation of peer-to-peer groups; relay-based groups remove it. |
| TOB-SMPLXCHAT-30 | JSON batch path in parseChatMessages lacks an element count bound, enabling database write amplification | Medium | Low | Resolved | [#7364](https://github.com/simplex-chat/simplex-chat/pull/7364) v7.1.0 | Resolved: message batches are limited in size. |
| TOB-SMPLXCHAT-42 | XFTP CLI path traversal via unsanitized file header name | Medium | Low | Resolved | [#1850](https://github.com/simplex-chat/simplexmq/pull/1850) v7.1.0 | Resolved: received file names cannot escape the destination folder. |
| TOB-SMPLXCHAT-46 | Default transport-session pooling lets a relay link a user's queues | Medium | Low | Resolved | — | Documented in the threat model; per-connection isolation is available in the app settings. |
| TOB-SMPLXCHAT-49 | iOS call handler silently ignores encryption-downgrade confirmation flag, enabling plaintext media | Medium | Low | Resolved | [#7647](https://github.com/simplex-chat/simplex-chat/pull/7647) v7.1.0 | Resolved: the app asks the user before connecting a call without end-to-end encryption. |
| TOB-SMPLXCHAT-57 | Verified controller bypasses allowRemoteCommand on the host, gaining unrestricted command execution | Medium | Low | Resolved | [#7370](https://github.com/simplex-chat/simplex-chat/pull/7370) v7.1.0 | Resolved: the host enforces which remote commands are allowed. |
| TOB-SMPLXCHAT-70 | Android archive import path traversal via unsanitized content-provider filename | Medium | Low | Resolved | [#7375](https://github.com/simplex-chat/simplex-chat/pull/7375) v7.1.0 | Resolved: imported archive names cannot escape the app cache folder. |
| TOB-SMPLXCHAT-2 | Fingerprint validation does not authenticate full invitation setup parameters | Medium | Medium | Unresolved | — | Accepted, future work: we will migrate to security codes that include the post-quantum handshake parameters. |
| TOB-SMPLXCHAT-40 | Moderator can grant moderator role to joining members via link acceptance | Medium | Medium | Resolved | [#7629](https://github.com/simplex-chat/simplex-chat/pull/7629) v7.1.0 | Resolved: only admins can accept members with the moderator role. |
| TOB-SMPLXCHAT-43 | XFTP redirect bypasses relay approval for inner description servers | Medium | Medium | Partially resolved | [#7617](https://github.com/simplex-chat/simplex-chat/pull/7617) v7.1.0 | Resolved for new transfers: XFTP redirects are rejected. |
| TOB-SMPLXCHAT-50 | iOS frame decryptor crashes on undersized frames from a malicious peer | Medium | Medium | Resolved | [#7613](https://github.com/simplex-chat/simplex-chat/pull/7613) v7.1.0 | Resolved: undersized frames are rejected. |
| TOB-SMPLXCHAT-58 | Known controller sessions auto-verified without human code comparison | Medium | Medium | Resolved | [#1891](https://github.com/simplex-chat/simplexmq/pull/1891) docs | Intended: code comparison is required on first pairing and optional for known desktops; it can be required for every session with Verify connections. |
| TOB-SMPLXCHAT-74 | Native iOS CallKit can answer calls without SimpleX authentication | Medium | Medium | Resolved | — | Intended: answering a native call connects the call; chats stay protected by SimpleX Lock. CallKit can be disabled. |
| TOB-SMPLXCHAT-1 | The hybrid handshake does not bind the KEM public key or ciphertext | Medium | High | Unresolved | — | Accepted, future work: binding the KEM public key and ciphertext in the handshake requires a protocol version upgrade. |
| TOB-SMPLXCHAT-20 | Malicious proxy can replay forwarded commands to the destination relay | Medium | High | Partially resolved | [#1915](https://github.com/simplex-chat/simplexmq/pull/1915) v7.1.0 | Resolved for protocol v23: forwarded responses use fresh nonces. |
| TOB-SMPLXCHAT-21 | Recipient key rotation can be undone by a command pre-verified under the old key | Medium | High | Resolved | — | Not applicable to the app: SimpleX Chat does not use RKEY, and the scenario requires a stolen recipient key. |
| TOB-SMPLXCHAT-62 | Android Keystore key missing hardware-backed isolation and user authentication | Medium | High | Partially resolved | [#7637](https://github.com/simplex-chat/simplex-chat/pull/7637) v7.1.0 | Improved: new keys use StrongBox where available, and the app shows the key storage level. |
| TOB-SMPLXCHAT-5 | RSAgreed can fall back to RSRequired without notifying the peer | Low | Low | Resolved | [#1923](https://github.com/simplex-chat/simplexmq/pull/1923) v7.1.0 | Resolved: a new synchronization request in the agreed state now gets a reply instead of a silent local reset. |
| TOB-SMPLXCHAT-23 | Deleted queues retain entries in the queues and links maps, leaking memory permanently | Low | Low | Resolved | [#1947](https://github.com/simplex-chat/simplexmq/pull/1947) v7.1.0<br>[#1919](https://github.com/simplex-chat/simplexmq/pull/1919) v7.1.0, after the fix review | Resolved: deleted queues are removed from all server maps, and the journal store is removed. |
| TOB-SMPLXCHAT-31 | isDataImage accepts data:image/svg+xml, permitting script execution in legacy browsers | Low | Low | Resolved | [#7643](https://github.com/simplex-chat/simplex-chat/pull/7643) v7.1.0 | Resolved: channel previews on the website accept only raster image data. |
| TOB-SMPLXCHAT-36 | Stale channel preview JSON files are never deleted because isBase64Url rejects the padding character | Low | Low | Resolved | [#7611](https://github.com/simplex-chat/simplex-chat/pull/7611) v7.1.0 | Resolved: stale channel preview files are removed on startup. |
| TOB-SMPLXCHAT-41 | x.grp.msg.forward JSON decoding is unboundedly recursive with no depth guard | Low | Low | Resolved | [#7614](https://github.com/simplex-chat/simplex-chat/pull/7614) v7.1.0 | Resolved: nested forwarding depth is limited. |
| TOB-SMPLXCHAT-45 | getBody ciphertext size check allows 4 GB reads | Low | Low | Resolved | [#7616](https://github.com/simplex-chat/simplex-chat/pull/7616) v7.1.0 | Resolved: remote-control message sizes are limited. |
| TOB-SMPLXCHAT-47 | Opt-in TSMUser mode uses a static SOCKS credential | Low | Low | Resolved | [#8154](https://github.com/simplex-chat/simplex-chat/pull/8154) v7.1.4, after the fix review | Intended: the opt-in per-profile mode reuses Tor circuits to reduce latency, and Tor guard relays never see SOCKS credentials. After the fix review, the iOS settings reset was fixed to restore the default per-session mode. |
| TOB-SMPLXCHAT-48 | ipAddressProtected ignores socksMode, suppressing the SMP delivery proxy under SMOnion for public-only relays | Low | Low | Resolved | [#1895](https://github.com/simplex-chat/simplexmq/pull/1895) v7.1.0 | Resolved: the private routing decision accounts for the SOCKS mode and destination host. |
| TOB-SMPLXCHAT-51 | Per-call media key logged in plaintext when developer debug mode is enabled on Android and desktop | Low | Low | Resolved | [#7618](https://github.com/simplex-chat/simplex-chat/pull/7618) v7.1.0 | Resolved: call commands with keys are no longer logged. |
| TOB-SMPLXCHAT-52 | Desktop call session token exposed in browser URL, WebSocket server performs no Origin check | Low | Low | Resolved | [#7619](https://github.com/simplex-chat/simplex-chat/pull/7619) v7.1.0 | Resolved: the call page connection is checked by origin and only the first connection is accepted. |
| TOB-SMPLXCHAT-54 | Call notification sets VISIBILITY_PUBLIC unconditionally, leaking call occurrence in HIDDEN preview mode | Low | Low | Resolved | [#7620](https://github.com/simplex-chat/simplex-chat/pull/7620) v7.1.0 | Resolved: caller profile is hidden in hidden preview mode. |
| TOB-SMPLXCHAT-59 | Multicast invitation replay via missing timestamp freshness check | Low | Low | Resolved | [#1899](https://github.com/simplex-chat/simplexmq/pull/1899) v7.1.0 | Resolved: multicast announcements are valid only within a time window. |
| TOB-SMPLXCHAT-60 | Skipped-key ratchet map grows without bound, enabling memory exhaustion | Low | Low | Resolved | [#7622](https://github.com/simplex-chat/simplex-chat/pull/7622) v7.1.0 | Resolved: skipped keys in remote access are limited. |
| TOB-SMPLXCHAT-61 | Unbounded zstd decompression enables compression bomb from a verified controller | Low | Low | Resolved | [#7616](https://github.com/simplex-chat/simplex-chat/pull/7616) v7.1.0 | Resolved: decompression of remote-control messages is limited. |
| TOB-SMPLXCHAT-71 | All key-lifecycle operations leave un-scrubbed .bak database copies on disk | Low | Low | Partially resolved | [#7628](https://github.com/simplex-chat/simplex-chat/pull/7628) v7.1.0 | Resolved for app operations: database backups are removed after key changes. |
| TOB-SMPLXCHAT-72 | Archive import has no uncompressed-size cap | Low | Low | Resolved | — | Accepted: the archive is chosen by the user, and the worst case is filling local storage. |
| TOB-SMPLXCHAT-73 | Control-port auth uses non-constant-time comparison with no rate limit | Low | Low | Resolved | [#1898](https://github.com/simplex-chat/simplexmq/pull/1898) v7.1.0 | Resolved: control-port passwords are compared in constant time; SMP passwords are random 144-bit values. |
| TOB-SMPLXCHAT-55 | iOS dropped-notification queue is keyed by entity ID | Low | Medium | Resolved | — | Not an issue: entity IDs are unique database IDs shared by all profiles. |
| TOB-SMPLXCHAT-64 | iOS database files not excluded from iCloud backup | Low | Medium | Resolved | [#7623](https://github.com/simplex-chat/simplex-chat/pull/7623) v7.1.0 | Resolved: app data is excluded from iCloud backup. |
| TOB-SMPLXCHAT-3 | Skipped message keys have no aggregate cap or cleanup path | Low | High | Resolved | [#1903](https://github.com/simplex-chat/simplexmq/pull/1903) v7.1.0 | Resolved: each receiving chain keeps at most 2,000 skipped message keys and prunes older ones. |
| TOB-SMPLXCHAT-4 | Expired AgentRatchetKey replay forces stale ratchet resync | Low | High | Resolved | [#1893](https://github.com/simplex-chat/simplexmq/pull/1893) v7.1.0 | Resolved: processed ratchet-key hashes are kept for the connection lifetime, up to a cap. |
| TOB-SMPLXCHAT-7 | Receive ratchet updates are committed after failed body authentication | Low | High | Resolved | [#1892](https://github.com/simplex-chat/simplexmq/pull/1892) v7.1.0 | Resolved: the message body is authenticated before any ratchet state is saved. |
| TOB-SMPLXCHAT-22 | Client-controlled fwdVersion bypasses version gates | Low | High | Resolved | [#1890](https://github.com/simplex-chat/simplexmq/pull/1890) v7.1.0 | Resolved: the relay checks the forwarded version before processing the command. |
| TOB-SMPLXCHAT-24 | Any party knowing the sender queue ID can race to install a sender key before the intended sender | Low | High | Resolved | — | Documented first-use behaviour: knowing the sender queue ID alone can disrupt the initial setup but cannot produce an accepted chat confirmation. |
| TOB-SMPLXCHAT-25 | PKEY version range is not covered by the relay certificate signature | Low | High | Unresolved | [#1900](https://github.com/simplex-chat/simplexmq/pull/1900) docs<br>[#1915](https://github.com/simplex-chat/simplexmq/pull/1915) v7.1.0 | Documented: the version is bound once the client selects it (protocol v23). |
| TOB-SMPLXCHAT-44 | XFTP server replays store log file paths without prefix validation | Low | High | Resolved | [#1894](https://github.com/simplex-chat/simplexmq/pull/1894) v7.1.0 | Resolved: restored file names are validated; the store log is trusted administrative state. |
| TOB-SMPLXCHAT-63 | Wipe routines miss .exported files left by a crashed rekey | Low | High | Resolved | [#7615](https://github.com/simplex-chat/simplex-chat/pull/7615) v7.1.0 | Resolved: .exported files are removed when the database is deleted. |
| TOB-SMPLXCHAT-65 | randomDatabasePassword silently falls back to an empty string on failure | Low | High | Resolved | [#7621](https://github.com/simplex-chat/simplex-chat/pull/7621) v7.1.0 | Resolved: the app shows an error if random passphrase generation fails. |
| TOB-SMPLXCHAT-75 | App re-lock during a call exposes chat list on Android and desktop | Low | High | Resolved | [#7627](https://github.com/simplex-chat/simplex-chat/pull/7627) v7.1.0<br>[#7505](https://github.com/simplex-chat/simplex-chat/pull/7505) v7.1.0 | Resolved: the app is not locked during a call, and the lock delay restarts after the call. |
| TOB-SMPLXCHAT-32 | Legacy full links silently ignore supplied owner signatures instead of reporting unsupported verification | Informational | Low | Unresolved | — | Intended: a legacy link without owner verification is reported as not verified, which is different from a failed verification. |
| TOB-SMPLXCHAT-37 | XGrpMsgForward relay-role check fires inside the handler, not at dispatch | Informational | Low | Unresolved | — | Accepted: this is a comment on code organization, not an exploitable issue. |
| TOB-SMPLXCHAT-6 | Plaintext confirmation header version can be downgraded | Informational | Medium | Unresolved | [#2053](https://github.com/simplex-chat/simplexmq/pull/2053) v7.1.4, after the fix review | Resolved after the fix review: the agent accepts confirmations only with the client version that its agent version implies. |
| TOB-SMPLXCHAT-8 | Planned deniability migration applies only to senders, leaving recipient commands non-repudiable | Informational | High | Unresolved | [#2054](https://github.com/simplex-chat/simplexmq/pull/2054) v7.1.4, after the fix review | Resolved after the fix review: sender commands are now authorized with X25519 keys, completing the planned migration. Recipient commands to their own server are not intended to be deniable. |
| TOB-SMPLXCHAT-11 | The handshake has no identity keys; peer authentication rests entirely on the out-of-band security code | Informational | High | Unresolved | — | Intended: SimpleX has no identity keys by design; the handshake is protected from MITM by the out-of-band link and can be verified with the security code. |
| TOB-SMPLXCHAT-13 | Post-compromise sender impersonation is delivery-scoped | Informational | High | Partially resolved | [#1902](https://github.com/simplex-chat/simplexmq/pull/1902) docs | Threat model updated to describe this case. |
| TOB-SMPLXCHAT-14 | Plaintext ehVersion drives ratchet-header parse mode | Informational | High | Resolved | [#1841](https://github.com/simplex-chat/simplexmq/pull/1841) v7.1.0 | Resolved: support for the older header encoding was removed, so ratchet headers have one encoding. |
| TOB-SMPLXCHAT-17 | Resync replay guard is committed before ratchet recreation | Informational | High | Resolved | [#1923](https://github.com/simplex-chat/simplexmq/pull/1923) v7.1.0 | Resolved: the replay guard and the new ratchet are written in one database transaction. |
| TOB-SMPLXCHAT-26 | Basic auth secret is compared without constant-time equality | Informational | High | Resolved | [#1898](https://github.com/simplex-chat/simplexmq/pull/1898) v7.1.0 | Resolved: server passwords are compared in constant time. |
| TOB-SMPLXCHAT-27 | cbNonce silently truncates or pads corrId values, creating non-injective nonce mappings | Informational | High | Resolved | [#1925](https://github.com/simplex-chat/simplexmq/pull/1925) v7.1.0 | Resolved: correlation IDs used as nonces must have the exact size. |
| TOB-SMPLXCHAT-28 | Palindromic corrId compromises request/response nonce domain separation | Informational | High | Partially resolved | [#1915](https://github.com/simplex-chat/simplexmq/pull/1915) v7.1.0 | Resolved for protocol v23: request and response nonces are separated. |
| TOB-SMPLXCHAT-29 | withQueue_ fast path passes a stale QueueRec snapshot to authorization checks | Informational | High | Resolved | [#1917](https://github.com/simplex-chat/simplexmq/pull/1917) v7.1.0 | Resolved: the server checks the live queue state before adding link data. |
| TOB-SMPLXCHAT-38 | Channel GROwner role changes do not transfer or revoke short-link owner authority | Informational | High | Partially resolved | [#7631](https://github.com/simplex-chat/simplex-chat/pull/7631) v7.1.0 | Resolved in current apps: owner role cannot be assigned in channels. |
| TOB-SMPLXCHAT-53 | Per-call media key is derived without a KDF and persisted to the chat database | Informational | High | Partially resolved | [#7642](https://github.com/simplex-chat/simplex-chat/pull/7642) v7.1.0 | Resolved for new calls: media keys are derived with HKDF and stale invitations expire. |
| TOB-SMPLXCHAT-66 | Large cryptographic primitive surface increases attack surface and maintenance burden | Informational | High | Partially resolved | [#1913](https://github.com/simplex-chat/simplexmq/pull/1913) docs | Documented: we added a registry of cryptographic primitives. |
| TOB-SMPLXCHAT-68 | SNTRUP761 KeyGen loops without bound on R3 inversion failure | Informational | High | Resolved | [#1918](https://github.com/simplex-chat/simplexmq/pull/1918) v7.1.0 | Resolved: SNTRUP761 key generation retries are bounded. |
| TOB-SMPLXCHAT-69 | Curve448 DH outputs are not checked for all-zero/low-order results | Informational | High | Unresolved | [#1921](https://github.com/simplex-chat/simplexmq/pull/1921) proposed | Accepted: low-order keys are not produced by key generation; an additional check is prepared. |
| TOB-SMPLXCHAT-9 | Hybrid KDF distinguishes DH-only vs DH+KEM inputs only by length | Informational | Not Applicable | Unresolved | — | Accepted, future work. |
| TOB-SMPLXCHAT-10 | The X3DH-style multi-DH has no clear security justification in the OOB-authenticated model | Informational | Not Applicable | Unresolved | — | Accepted: the multi-DH design is reserved for future handshakes bound to optional identities. |
| TOB-SMPLXCHAT-12 | Protocol role names and prekey framing are inconsistent | Informational | Not Applicable | Partially resolved | [#1912](https://github.com/simplex-chat/simplexmq/pull/1912) docs | Documentation updated to use role names for the key-exchange parties. |
| TOB-SMPLXCHAT-15 | KEM state transitions are more permissive than the protocol table | Informational | Not Applicable | Unresolved | — | Accepted: the more permissive transitions do not compromise security. |
| TOB-SMPLXCHAT-16 | URI parser ignores KEM ciphertext without a KEM key | Informational | Not Applicable | Resolved | [#1901](https://github.com/simplex-chat/simplexmq/pull/1901) v7.1.0 | Resolved: invitations with a KEM ciphertext but no KEM key are rejected. |
| TOB-SMPLXCHAT-18 | Pending sends retain ratchet message keys instead of storing ciphertext | Informational | Not Applicable | Unresolved | — | Intended: most sends are broadcasts with large ciphertexts; keeping message keys reduces database churn and fits the threat model. |
| TOB-SMPLXCHAT-67 | Double-ratchet AEAD uses non-standard 16-byte GCM IV | Informational | Undetermined | Unresolved | [#1914](https://github.com/simplex-chat/simplexmq/pull/1914) docs | Accepted: the 16-byte IV is documented. |
