mirror of
https://github.com/Such-Software/hash-wallet.git
synced 2026-10-17 05:41:29 +02:00
getWalletPassword force-unwrapped the secure-storage read, so a null iOS Keychain result (item written by an older build under different Keychain params, e.g. after a TestFlight update) hard-crashed the app and the wallet showed "Corrupted seeds" — reported by a tester whose older Wownero and BTC wallets broke on update. Now it: - falls back to the legacy readNoIOptions path (queries the OTHER iOS Keychain accessibility), which can AUTO-RECOVER such wallets without a seed restore; - falls back to the #__<name>_bak__# backup password the Monero migration writes before re-encrypting; - throws a catchable error instead of a null-check crash, so the loader can offer seed/restore recovery rather than the app dying. Only changes behavior on the previously-crashing null path — strictly safer. Not the file cipher (iOS is always Salsa20) nor the Monero migration (Wownero/BTC don't run it): the wallet files are intact, only the Keychain password was unreadable. flutter_secure_storage stays pinned (ca897a08) and the accessibility stays first_unlock; those must not change without a migration (see docs/internal-notes.md).