Argyle-Software / kyber

A rust implementation of the Kyber post-quantum KEM
https://docs.rs/pqc_kyber/
Apache License 2.0
178 stars 40 forks source link

Add an option to use RustCrypto AES #9

Closed mberry closed 1 year ago

mberry commented 2 years ago

Use rustcrypto for the 90's mode AES functions.

Kyber uses some intermediate functions not exposed by the rustcrypto crate, namely aes256ctr_init and aes256ctr_squeezeblocks

The PRF is already implemented yet not in use.

https://github.com/Argyle-Software/kyber/blob/6e274dcd11ef85b7aa642be24054a3847683d293/src/symmetric.rs#L117-L129

mberry commented 1 year ago

Benchmarking this it seems best to only use the rustcrypto version, both for speed and a bitslice impl

mberry commented 1 year ago

Implemented with 90s-fixslice