RFR: 8158111: Make handling of 3rd party providers more stable
Seán Coffey
sean.coffey at oracle.com
Mon May 30 16:06:20 UTC 2016
Looks good Ivan. Given that we know that the cipher transformation is
RSA/ECB/PKCS1Padding, maybe you can consider printing that in the
exception. As a result, maybe something like :
+ System.out.println("Retrieval of RSA/ECB/PKCS1Padding
cipher transformation" +
+ " provider caused exception " + e.getMessage());
The cipher.toString() call might be unnecessary as a result then. Will
leave that up to you/Xuelei.
You might want to consider marking the bug public.
Regards,
Sean.
On 30/05/16 10:14, Xuelei Fan wrote:
> Looks fine to me. Thanks!
>
> Xuelei
>
> On 5/30/2016 4:48 PM, Ivan Gerasimov wrote:
>> Hello!
>>
>> In the file
>> src/java.base/share/classes/sun/security/ssl/RSAClientKeyExchange.java:
>>
>> When doing the debug printing:
>> System.out.println("The Cipher provider " +
>> cipher.getProvider().getName() +
>> " caused exception: " + iue.getMessage());
>>
>> cipher.getProvider() may throw an exception, which will cause the
>> fail-over branch get skipped.
>>
>>
>> Furthermore, in the fail-over branch it is better to re-acquire an
>> instance of the cipher, as the previous call to init() might have left
>> the current instance in inconsistent state.
>>
>> Would you please help review the proposed fix?
>>
>> BUGURL: https://bugs.openjdk.java.net/browse/JDK-8158111
>> WEBREV: http://cr.openjdk.java.net/~igerasim/8158111/00/webrev/
>>
>>
>> With kind regards,
>> Ivan
>>
>>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/security-dev/attachments/20160530/82084ac4/attachment.htm>
More information about the security-dev
mailing list