Skip to content

Commit 4184183

Browse files
committed
Fix IV size in AesCipher
1 parent 9d20b5d commit 4184183

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

libsignal-service-dotnet/contacts/crypto/AesCipher.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ internal static AesEncryptedResult Encrypt(byte[] key, byte[]? aad, byte[] reque
3030
{
3131
try
3232
{
33-
byte[] iv = Util.GetSecretBytes(32);
33+
byte[] iv = Util.GetSecretBytes(12);
3434
var cipher = new GcmBlockCipher(new AesEngine());
3535
cipher.Init(true, new AeadParameters(new KeyParameter(key), TAG_LENGTH_BITS, iv));
3636
if (aad != null)

0 commit comments

Comments
 (0)