fix: change tag length in aes gcm cipher

This commit is contained in:
Hugo Pointcheval 2022-05-25 23:29:02 +02:00
parent 5729fff09b
commit 39a0a44730
Signed by: hugo
GPG Key ID: A9E8E9615379254F

View File

@ -3,7 +3,7 @@
// ----- // -----
// File: aes.dart // File: aes.dart
// Created Date: 16/12/2021 16:28:00 // Created Date: 16/12/2021 16:28:00
// Last Modified: 25/05/2022 15:40:07 // Last Modified: 25/05/2022 21:17:10
// ----- // -----
// Copyright (c) 2022 // Copyright (c) 2022
@ -67,7 +67,8 @@ class AES implements Cipher {
List.empty(); List.empty();
return CipherText.fromPairIvAndBytes( return CipherText.fromPairIvAndBytes(
cipherText, cipherText,
dataLength: cipherText.last.length, dataLength: cipherText.last.length - 16,
tagLength: 16,
); );
} }