RFR: 8255557: Decouple GCM from CipherCore [v3]

Anthony Scarpino ascarpino at openjdk.java.net
Fri May 21 00:25:34 UTC 2021


On Tue, 18 May 2021 22:46:58 GMT, Valerie Peng <valeriep at openjdk.org> wrote:

>> Anthony Scarpino has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   cleanup
>
> src/java.base/share/classes/com/sun/crypto/provider/GaloisCounterMode.java line 168:
> 
>> 166:     // return tag length in bytes
>> 167:     int getTagLen() {
>> 168:         return this.tagLenBytes;
> 
> Doesn't seem too useful if all it does is just returning the 'tagLenBytes' field? With your current code, tagLenBytes is initialized with 16 and is set in init(). When a GCMParameterSpec is not specified, it uses the tagLenBytes value from earlier init() instead of a fixed default. This seems incorrect?

Agreed.. I was probably trying to follow the getIv() idea, but never implemented it elsewhere

-------------

PR: https://git.openjdk.java.net/jdk/pull/4072



More information about the security-dev mailing list