calculateKeyCrc method

  1. @override
int calculateKeyCrc()
override

Calculate a hash of the key. Make sure to use a secure hash.

Implementation

@override
int calculateKeyCrc() => hive_internal.Crc32.compute(
      encryptionKey.runUnlockedSync(
        (encryptionKeyData) => sodium.crypto.genericHash(
          message: encryptionKeyData,
          outLen: sodium.crypto.genericHash.bytesMax,
        ),
      ),
    );