Structs§
Enums§
Constants§
- BETA
- BETA_
I32 - CRHBYTES
- D
- ETA
- ETA_I32
- GAMMA1
- GAMMA2
- GAMM
A1_ I32 - GAMM
A1_ SUB_ BETA - GAMM
A2_ I32 - K
- L
- L_U16
- N
- N_U32
- OMEGA
- OMEGA_
U8 - POLYETA_
PACKEDBYTES - POLY
T0_ PACKEDBYTES - POLY
T1_ PACKEDBYTES - POLYVECH_
PACKEDBYTES - POLY
W1_ PACKEDBYTES - POLYZ_
PACKEDBYTES - PUBLICKEYBYTES
- Q
- Q_I32
- RANDOMIZED_
SIGNING - ROOT_
OF_ UNITY - SECRETKEYBYTES
- SEEDBYTES
- SIGNBYTES
- TAU
Functions§
- a2
- Process a salt and key material input (password) with Argon2.
- decrypt_
key - Read the ciphertext key file and decrypt it, returning the private key data to the function caller for signing.
- derive_
key - This function includes the fixed salt and mixes the salt with the provided input material (password). The salt and password go through Argon2, and then SHAKE256.
- encrypt_
key - This function encrypts the Dilithium secret key with the resulting key material, writing the ciphertext to a file.
- keygen
- This function generates new Dilithium keys, keeping the private protected. The protection is from AES256 on the private key, writing only the ciphertext to disk for re-use. The secret key for the secret key (AES256 key) is generated using password input as key material generated by Argon2 hashing with a fixed salt. See the aesrest module (aesrest.rs) for more related to this private key protection cryptogaphy.
- verify
- Verify a signature by supplying the signature, message, and public key as &u8.