RFR: 8325448: Hybrid Public Key Encryption [v3]

Kevin Driver kdriver at openjdk.org
Fri Feb 28 16:44:59 UTC 2025


On Thu, 27 Feb 2025 03:22:18 GMT, Weijun Wang <weijun at openjdk.org> wrote:

>> Implement HPKE as defined in https://datatracker.ietf.org/doc/rfc9180/.
>> 
>> ![HPKEParameterSpec](https://github.com/user-attachments/assets/4f64567a-59b0-473e-8a3b-416565f5bca5)
>
> Weijun Wang has updated the pull request incrementally with one additional commit since the last revision:
> 
>   example and KAT

src/java.base/share/classes/com/sun/crypto/provider/HPKE.java line 292:

> 290:                     return kdf.deriveKey(algorithm, HKDFParameterSpec.expandOnly(exporter_secret,
> 291:                             DHKEM.labeledInfo(suite_id, "sec".getBytes(StandardCharsets.UTF_8),
> 292:                                     exporter_context, L), L));

See other comment about input validation on `L` and whether it is useful to detect the case where `L` < 0 separately in the method that throws `Exception`.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/18411#discussion_r1975710863


More information about the security-dev mailing list