RFR: 8341346: Add support for exporting TLS Keying Material [v12]

Bradford Wetmore wetmore at openjdk.org
Fri May 16 21:34:53 UTC 2025


On Thu, 15 May 2025 04:22:42 GMT, Bradford Wetmore <wetmore at openjdk.org> wrote:

>> src/java.base/share/classes/sun/security/ssl/SSLSessionImpl.java line 1650:
>> 
>>> 1648:                     emptyHash = md.digest();
>>> 1649:                 } catch (NoSuchAlgorithmException nsae) {
>>> 1650:                     throw new RuntimeException(
>> 
>> We usually throw a `ProviderException` here, when some weird configuration removes a basic hash algorithm.
>
> I can do a `ProviderException` if you like, but our JSSE code is all over the place.  Sometimes it's a `RuntimeException`, other times we wrap it into into a `SSLException`, and sometimes we directly do a `fatal()`.  I'd say we do `RuntimeException` a little more often than `ProviderException`.

Updated to to `ProviderException` since the point does fit the description of the class better.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/24976#discussion_r2093697971


More information about the net-dev mailing list