5367544b59
The 0.18.1 fix relied on an existing-device + present-stronghold-key match.
That fails for users who:
- had multiple device registrations and only retain the latest device's
private key in the local vault
- had a vault wipe / fresh OS install at some point
- have device rows that vanished server-side but keys still locally
Migration now scans conversation_keys for distinct un-migrated
recipient_device_ids visible to the user (RLS-filtered) and probes the
stronghold for each, regardless of whether the server still lists that
device. Result struct surfaces attempted/migrated/noKey/decryptFail/rpcFail
counters; SecurityCenter shows them via a new "Migration erneut ausführen"
button so users can self-diagnose without DevTools.
Also adds [crypto-migration] console.info breadcrumbs at every decision
point so a single F12 shows what happened.
apps/desktop/src/lib
Desktop-local helpers that depend on Tauri plugins.
Expected contents:
stronghold.ts— wrapstauri-plugin-strongholdfor secret storage; adapter for@chat-app/shared/auth.sqlite.ts— wrapstauri-plugin-sql(SQLite), exposes migration runner.notifications.ts— wrapstauri-plugin-notification.sodium.ts— bindslibsodium-wrappers(WASM) to the crypto adapter interface.store.ts— Zustand store setup (auth state, chat state slices).