On Wed, 4 May 2022 16:29:09 GMT, Sean Mullan <mul...@openjdk.org> wrote:

>> Hai-May Chao has updated the pull request incrementally with one additional 
>> commit since the last revision:
>> 
>>   Skip alg constraint check for PBE secret key entry
>
> src/java.base/share/classes/sun/security/tools/keytool/Main.java line 2208:
> 
>> 2206:                  * is not really a new issue as details about secret 
>> key entries
>> 2207:                  * other than the fact they exist as entries are not 
>> listed ,
>> 2208:                  * presumably because we may not have the right 
>> password.
> 
> I would leave out this last sentence as that was more of an editorial comment 
> by me. In the first sentence, I would add at the end "... and we will not be 
> able to check the constraints because we do not have the keyPass for this 
> operation."

Comment updated.

> src/java.base/share/classes/sun/security/tools/keytool/Main.java line 5286:
> 
>> 5284:         @Override
>> 5285:         public Set<Key> getKeys() {
>> 5286:             return (key == null) ? Set.of() : Set.of(key);
> 
> key should never be null, so you don't need to check for this.

Removed the extra check.

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

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

Reply via email to