OpenSSLCipher: multiple calls to updateAAD were ignored
Do to a missing assignment statement, only the first call to updateAAD
was honored and the rest were discarded.
(cherry picked from commit a23b05b327b9d8fefc44276c2fa80278ef210c0f)
Bug: 27371173
Change-Id: I77ad7800b0905f72d5abe76b56352a94056ceb9c
diff --git a/src/main/java/org/conscrypt/OpenSSLCipher.java b/src/main/java/org/conscrypt/OpenSSLCipher.java
index 305f174..571c8cb 100644
--- a/src/main/java/org/conscrypt/OpenSSLCipher.java
+++ b/src/main/java/org/conscrypt/OpenSSLCipher.java
@@ -1059,6 +1059,7 @@
byte[] newaad = new byte[newSize];
System.arraycopy(aad, 0, newaad, 0, aad.length);
System.arraycopy(input, inputOffset, newaad, aad.length, inputLen);
+ aad = newaad;
}
}