fix undecryptable self-copies by preserving the self-session
iOS CI / Build and Test SwiftUI App (push) Canceled after 0s
Build Unsigned iOS and macOS Apps / Build Unsigned iOS IPA (push) Canceled after 0s
Build Unsigned iOS and macOS Apps / Build macOS ZIP (push) Canceled after 0s

- Purge the poisoned self-session only once per account instead of on
  every connect, and rebuild it from the own published bundle when
  missing: deleting it repeatedly broke encrypt-to-self, so archived
  copies of own messages (most visibly in the self-chat) failed with
  "could not decrypt".
- Detect OMEMO 2 (urn:xmpp:omemo:2) payloads, which the pinned
  MartinOMEMO does not implement, and show them as undecryptable
  instead of empty plaintext bubbles.
- Guard both behaviours in verify.sh and document the namespace
  limitation in SECURITY.md.
This commit is contained in:
wt committed 2026-08-30 00:32:40 +07:00
1 parent 5a7fc36722
commit 8b86e33186
5 files changed
+92 -20

No files matched your search

+8 -5
View File
@@ -46,11 +46,14 @@ final class TimelineUITests: XCTestCase {
let app = launchApp()
openChat(app)
// Message 60 can sit partially behind the composer, so drag on a
// bubble that is reliably visible and hittable in the bottom area.
let target = bubble("uitest-msg-55", in: app)
XCTAssertTrue(target.waitForExistence(timeout: 10))
XCTAssertTrue(target.isHittable, "The swipe target must be hittable")
// The initial scroll position varies slightly between runs, so pick
// the first hittable bubble from the bottom area of the timeline.
let candidates = [60, 59, 58, 55, 50, 45].map {
bubble("uitest-msg-\($0)", in: app)
}
let target = candidates.first { $0.exists && $0.isHittable }
XCTAssertNotNil(target, "At least one swipe target must be hittable")
guard let target else { return }
// A controlled right-to-left drag: the stock swipeLeft() flicks too
// fast for the gesture's horizontal lock to engage reliably.
let start = target.coordinate(withNormalizedOffset: CGVector(dx: 0.9, dy: 0.5))