On Thu, 2 Oct 2025 21:26:41 GMT, Weijun Wang <[email protected]> wrote:

>> Anthony Scarpino has updated the pull request incrementally with one 
>> additional commit since the last revision:
>> 
>>   missed some decoder comments
>
> test/jdk/javax/crypto/EncryptedPrivateKeyInfo/GetKeyPair.java line 103:
> 
>> 101:             "PublicKey didn't match with decoded.");
>> 102:         Asserts.assertEqualsByteArray(kps.origPubEncoding, 
>> actualPubEncoding,
>> 103:             "PublicKey didn't match with decoded.");
> 
> There is no need to always compare public key encoding twice. You can compare 
> `kpOrig.getPublic()` and `mlkemKP.getPubic()` once after line 72.
> 
> Then you can just compare `mlkemKP` and `kp` and there is no need to invent a 
> new `KeyPairs` type.
> 
> I would more like to see this test and `GetKey` merged, probably also 
> covering `getKeySpec`.

I can clean this up.  But I don't plan to expand it to other tests.   getKey 
uses the same code, so it's pretty much covered.  Maybe something for the test 
plan to look into.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/27147#discussion_r2430789599

Reply via email to