pqc-ml-kem

Crates.iopqc-ml-kem
lib.rspqc-ml-kem
version0.8.0
created_at2025-05-15 15:27:11.283481+00
updated_at2025-05-20 17:51:57.133608+00
descriptionA library for Module-Lattice Key Encryption Mechanism (ML-KEM)
homepage
repositoryhttps://github.com/Godspower-Eze/ml_kem.rs
max_upload_size
id1675234
size2,466,625
Godspower Eze (Godspower-Eze)

documentation

README

Project Status

pqc-ml-kem.rs

A rust library for ML-KEM(Module-Lattice-Based Key-Encapsulation Mechanism)

🚧 Project Status

This project is currently under active development. Expect breaking changes and incomplete features.

Features

  • keygen() - generate a key pair (ek, dk)
  • encaps(ek) - generate a key and ciphertext pair (key, ciphertext)
  • decaps(dk, ciphertext)- generate the shared key key

How to Use

To install, use:

cargo add pqc-ml-kem

To use

use pqc_ml_kem::{ML_KEM_512, ML_KEM_768, ML_KEM_1024};

let (ek, dk) = ML_KEM_512.keygen();

let (key_1, ct) = ML_KEM_512.encaps(&ek);

let key_2 = ML_KEM_512.decaps(&dk, &ct);

assert_eq(key_1, key_2)

Acknowledgements

  • kyber.py for serving as an initial reference.

License

This project is licensed under the MIT license.

See LICENSE for more information.

Commit count: 61

cargo fmt