isar / isar/hive

Crash while using encryption on iOS

Open
#1,075 2 comments 0 reactions 0 assignees View on GitHub
question
Dominant language
Dart
Stars
4.4k
Forks
449
PR merge metrics
No merged PRs in 30d

Description

**Problem**
I have been using Hive with satisfaction for some months in apps developed with Flutter for Android without any particular problems but today I started the development of a new app for iOS and I encountered a problem: if I enable the encryption, the app crashes because it fails to open the box.
Is it enough to disable the encryption for everything to work correctly?
Has anyone had similar problems?

**Code sample**
```dart
box = await Hive.openBox(boxName, encryptionCipher: HiveAesCipher(encryptionKey));
```

**Version**
- Platform: iOS
- Flutter version: 3.3.2
- Hive version: 2.2.3

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reproducing the Hive.openBox call with HiveAesCipher(encryptionKey) on iOS using Flutter 3.3.2 and Hive 2.2.3, and capture the crash or box-opening error. Compare encrypted and unencrypted behavior, then confirm that an encrypted box opens successfully on iOS without affecting Android.

Written by the indexing model from the issue text.

Assessment

Tech stack
dart, flutter
Domain
database, mobile, security
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.