Skip to content

fix(e2ee): scope persisted stores by account JID#428

Merged
mremond merged 1 commit into
mainfrom
mr/xenodochial-mclean-29504c
Jun 1, 2026
Merged

fix(e2ee): scope persisted stores by account JID#428
mremond merged 1 commit into
mainfrom
mr/xenodochial-mclean-29504c

Conversation

@mremond
Copy link
Copy Markdown
Member

@mremond mremond commented Jun 1, 2026

Summary

  • Scope 8 persisted stores (5 E2EE trust stores, verification sync version, E2EE toggle, ignore list) by account bare JID to prevent cross-account data leakage
  • Add one-shot migration from unscoped keys and rehydration on account switch

…ount data leakage

Trust stores (verified peers, pinned fingerprints, key-change alerts,
plaintext overrides, cert rejections), the verification sync version,
the E2EE toggle, and the ignore list all used global localStorage keys.
On a multi-account setup this let one account inherit another's trust
decisions — a security issue for E2EE data.

Each store now uses buildScopedStorageKey() to suffix the key with the
bare JID, with one-shot migration from the old unscoped key and a
rehydrate() action triggered on account switch.
@mremond mremond merged commit 571f1b6 into main Jun 1, 2026
2 checks passed
@mremond mremond deleted the mr/xenodochial-mclean-29504c branch June 1, 2026 13:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant