RFR: 8360564: Implement JEP 524: PEM Encodings of Cryptographic Objects (Second Preview) [v7]

Sean Mullan mullan at openjdk.org
Wed Oct 22 12:45:21 UTC 2025


On Wed, 22 Oct 2025 04:38:53 GMT, Anthony Scarpino <ascarpino at openjdk.org> wrote:

>> Unfortunately `generateEncoding` also assigned the result to the internal field `encodedKey`.
>
> @wangweij is correct, `generateEncoding()` is setting the instance variable `encodedKey`.    A finally-block is likely necessary if an exception happens after `privateKeyMaterial` is set in `generateEncoding()`

Ok, that could be fixed by creating another method that just does the encoding (and change `generateEncoding` to call that), but maybe we can fix that later.

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

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


More information about the security-dev mailing list