On Fri, 12 Mar 2021 22:04:35 GMT, Ziyi Luo <luoz...@openjdk.org> wrote:

>> My understanding is that the problem here is the 2 `isAssignableFrom` checks 
>> are in wrong order. The parent class RSA_PRIV_KEYSPEC_CLS should be checked 
>> first.
>> 
>> BTW, please add a regression test to the fix. Thanks.
>
> Hi @wangweij Thanks for your review. As @SalusaSecondus commented, 
> RSAPrivateKeyCrtSpec should be favored over RSAPrivateKeySpec when the 
> PrivateKey is a Crt Key. I just modified our JTreg test to include all four 
> cases described in the PR description.

I still cannot understand why CRT is always preferred. The original 
implementation also hadn't done that.

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

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

Reply via email to