On Fri, 30 Jul 2021 18:40:14 GMT, Smita Kamath <svkam...@openjdk.org> wrote:
>> src/java.base/share/classes/com/sun/crypto/provider/GaloisCounterMode.java >> line 717: >> >>> 715: in = new byte[Math.min(PARALLEL_LEN, srcLen)]; >>> 716: out = new byte[Math.min(PARALLEL_LEN, srcLen)]; >>> 717: } >> >> Move this down to else-block below just like the 'ct' variable. > > I've kept this code as is and not moved as recommended. If we move this line > to the else part, the case where srcLen is less than PARALLEL_LEN but greater > than BlockSize, in[] is null. As a result, three tests in > test/jdk/../Cipher/AEAD were failing on src.get(in, 0, rlen) line. Do let me > know if that's okay. Thanks. Hmm, I see. Sure, fine to keep it as is then. ------------- PR: https://git.openjdk.java.net/jdk/pull/4019