Skip to content

Migrating "cryptography_flutter" package from KGP to built-in Kotlin#225

Open
drmirk wants to merge 3 commits into
dint-dev:masterfrom
drmirk:kgp_migration
Open

Migrating "cryptography_flutter" package from KGP to built-in Kotlin#225
drmirk wants to merge 3 commits into
dint-dev:masterfrom
drmirk:kgp_migration

Conversation

@drmirk

@drmirk drmirk commented May 31, 2026

Copy link
Copy Markdown
  1. Flutter 3.44 is warning to migrate "cryptography_flutter" plugin to migrate to built-in kotlin form KGP. Followed the official documentation and added a check to apply the KGP only when the app's Android Gradle Plugin version is earlier than 9.
  2. During testing, SecretKey was making StateError. Because even after SecretKeyData instance was destroyed, there were subsequent call to its bytes getter. So, checking if it has been destroyed before accessing its bytes.
  3. During testing randomly got NEGATIVE_NUMBER Crash. BigInteger constructor interprets the first bit of the array as a sign bit. The 1 explicitly tells Java to treat the byte array as a positive.

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