fix(app): on Apple's systems the account's keys stay on this device
flutter_secure_storage's default accessibility on iOS and macOS (unlocked) lets keychain items into encrypted backups, which restore on another device. The account's unlocked keys are now kept first_unlock_this_device (macOS through its data protection keychain, the package's default there), and never synchronised to iCloud Keychain. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
This commit is contained in:
parent
5270ce6775
commit
67b26e0ea0
1 changed files with 34 additions and 1 deletions
|
|
@ -0,0 +1,19 @@
|
|||
import 'package:flutter_secure_storage/flutter_secure_storage.dart';
|
||||
import 'package:flutter_test/flutter_test.dart';
|
||||
import 'package:halkyon_app/halkyon_app.dart';
|
||||
|
||||
void main() {
|
||||
test("the account's keys stay on this device on Apple's systems: never in "
|
||||
'a backup restored elsewhere, nor in iCloud Keychain', () {
|
||||
for (final options in [
|
||||
accountKeyStorage.iOptions,
|
||||
accountKeyStorage.mOptions,
|
||||
]) {
|
||||
expect(
|
||||
options.accessibility,
|
||||
KeychainAccessibility.first_unlock_this_device,
|
||||
);
|
||||
expect(options.synchronizable, isFalse);
|
||||
}
|
||||
});
|
||||
}
|
||||
Loading…
Reference in a new issue