Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ml-kem: make encapsulation_key() public #39

Closed
commial opened this issue Jul 26, 2024 · 4 comments · Fixed by #48
Closed

ml-kem: make encapsulation_key() public #39

commial opened this issue Jul 26, 2024 · 4 comments · Fixed by #48

Comments

@commial
Copy link

commial commented Jul 26, 2024

Hello,

For easier integration with others crates and simplify some ml-kem use cases, it would be nice to have a way to obtain the encapsulation key from the decapsulation one.
It seems that this is already possible and done inside the crate, but the related function is not published publicly:

pub(crate) fn encapsulation_key(&self) -> &EncapsulationKey<P> {

Would it be possible to make it widely available, or am I missing an already existing method to obtain the encapsulating key from the decapsulation key?

@tarcieri
Copy link
Member

tarcieri commented Jul 26, 2024

FWIW we had some discussion of traits for this here: RustCrypto/traits#1559 (comment)

cc @rozbb @incertia

@tarcieri
Copy link
Member

tarcieri commented Aug 1, 2024

Barring some resolution on what the traits should look like, I think we can start by making encapsulation_key public

cc @bifurcation

@incertia
Copy link
Contributor

I don't see anything wrong with making it public, although I'm not the original owner of this code.

@tarcieri
Copy link
Member

If someone wants to open a PR we can move forward on making it public

@tarcieri tarcieri changed the title Make encapsulation_key() public ml-kem: make encapsulation_key() public Aug 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants