RFR 8048619: Implement tests for converting PKCS12 keystores
Wang Weijun
weijun.wang at oracle.com
Fri Sep 19 07:34:46 UTC 2014
In compareCerts(), you should not compare Certificate.toString(), its equals() method is more reliable. There is no need to define compareKeys() and compareCerts(). Instead, you should try not to repeat lines 223-231 on 252-260.
The two calls on lines 204 and 205 have keystore names exchanged but keypass order is the same. Also, with two calls it means the comparisons of keys and certs are duplicated. The else block on line 206 looks strange. Do you mean the size is always 1 here? If so, check it. Otherwise, there is no guarantee the aliases appear in the same order.
I would be glad to see a generalized comparison method no matter what the keystore size is.
Minor issues:
It will be clear if you divide the constant strings at the beginning into 2 parts, one for provider names, and one for algorithms.
Line 143 and 145, there should be spaces around the testCase name.
--Max
On Sep 19, 2014, at 11:04, zaiyao liu <zaiyao.liu at oracle.com> wrote:
> Hi Max,
>
> Can you help to review it?
>
> Thanks
>
> Kevin
> 于 2014/9/1 13:25, Wang Weijun 写道:
>> On vacation now. Can you look for someone else? I will be back in Sep 17 if you are not in a hurry.
>>
>> --Max
>>
>> On Sep 1, 2014, at 9:37, zaiyao liu <zaiyao.liu at oracle.com> wrote:
>>
>>> Hi Max,
>>>
>>> Please review the code change,the purpose of this fix is implement tests that convert PKCS12 keystores to other formats.
>>>
>>> Webrev: http://cr.openjdk.java.net/~tyan/kevin/JDK-8048619/webrev01/
>>> Bug: https://bugs.openjdk.java.net/browse/JDK-8048619
>>>
>>> Thanks
>>>
>>> Kevin
>
More information about the security-dev
mailing list