Skip to content

Conversation

@nstilt1
Copy link
Contributor

@nstilt1 nstilt1 commented Sep 4, 2025

Fixes #454

If XChaCha is supposed to use the legacy/djb construction then we might need to add xchacha into the mix.

@nstilt1
Copy link
Contributor Author

nstilt1 commented Sep 4, 2025

We could alternatively have a module for the DJB construction so that way there's only one #[cfg statement instead of 3. And then maybe a pub use legacy::Legacy; to preserve the structure.

@nstilt1 nstilt1 changed the title adding the proper features for using legacy/djb construction chacha20 - adding the proper features for using legacy/djb construction Sep 4, 2025
@tarcieri tarcieri merged commit d43c405 into RustCrypto:master Sep 4, 2025
27 checks passed
@nstilt1
Copy link
Contributor Author

nstilt1 commented Sep 4, 2025

We could alternatively have a module for the DJB construction so that way there's only one #[cfg statement instead of 3. And then maybe a pub use legacy::Legacy; to preserve the structure.

I change my mind about making a new module. I'm pretty sure we would need 2 cfg statements per variant instead of 1, which is almost as bad as 3 cfg statements, so it would not be that good to use more modules

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 this pull request may close these issues.

chacha20: RNG is gated behind legacy feature + rng feature

2 participants