[][src]Module pqcrypto_hqc::hqc1281cca2

hqc-128-1-cca2

These bindings use the leaktime version from PQClean

Example

use pqcrypto_hqc::hqc1281cca2::*;
let (pk, sk) = keypair();
let (ss1, ct) = encapsulate(&pk);
let ss2 = decapsulate(&ct, &sk);
assert!(ss1 == ss2);

Structs

Ciphertext
PublicKey
SecretKey
SharedSecret

Functions

ciphertext_bytes

Get the number of bytes for the encapsulated ciphertext

decapsulate

Decapsulate the received hqc-128-1-cca2 ciphertext

encapsulate

Encapsulate to a hqc-128-1-cca2 public key

keypair

Generate a hqc-128-1-cca2 keypair

public_key_bytes

Get the number of bytes for a public key

secret_key_bytes

Get the number of bytes for a secret key

shared_secret_bytes

Get the number of bytes for the shared secret