|
Botan 3.11.0
Crypto and TLS for C&
|
#include <ml_kem_impl.h>
Public Member Functions | |
| std::pair< KyberSharedSecret, KyberEncryptionRandomness > | G (StrongSpan< const KyberMessage > msg, StrongSpan< const KyberHashedPublicKey > pubkey_hash) const |
| std::pair< KyberSeedRho, KyberSeedSigma > | G (StrongSpan< const KyberSeedRandomness > seed, const KyberConstants &mode) const |
| KyberHashedCiphertext | H (StrongSpan< const KyberCompressedCiphertext > r) const |
| KyberMessage | H (StrongSpan< const KyberMessage > m) const |
| KyberHashedPublicKey | H (StrongSpan< const KyberSerializedPublicKey > pk) const |
| KyberSharedSecret | J (StrongSpan< const KyberImplicitRejectionValue > rejection_value, StrongSpan< const KyberCompressedCiphertext > ciphertext) const |
| void | KDF (StrongSpan< KyberSharedSecret > out, StrongSpan< const KyberSharedSecret > shared_secret, StrongSpan< const KyberHashedCiphertext > hashed_ciphertext) const |
| KyberSamplingRandomness | PRF (KyberSigmaOrEncryptionRandomness seed, const uint8_t nonce, const size_t outlen) const |
| void | setup_PRF (std::unique_ptr< Botan::XOF > &xof, std::span< const uint8_t > seed, uint8_t nonce) const |
| Setup a seeded PRF XOF for polynomial sampling. | |
| void | setup_XOF (std::unique_ptr< Botan::XOF > &xof, StrongSpan< const KyberSeedRho > seed, std::tuple< uint8_t, uint8_t > matrix_position) const |
| Setup an XOF object for matrix sampling. | |
Protected Member Functions | |
| std::unique_ptr< HashFunction > | create_G () const override |
| std::unique_ptr< HashFunction > | create_H () const override |
| std::unique_ptr< HashFunction > | create_J () const override |
| std::unique_ptr< HashFunction > | create_KDF () const override |
| std::unique_ptr< Botan::XOF > | create_PRF (std::span< const uint8_t > seed, const uint8_t nonce) const override |
| std::unique_ptr< Botan::XOF > | create_XOF (std::span< const uint8_t > seed, std::tuple< uint8_t, uint8_t > matrix_position) const override |
| void | init_PRF (Botan::XOF &xof, std::span< const uint8_t > seed, const uint8_t nonce) const override |
| void | init_XOF (Botan::XOF &xof, std::span< const uint8_t > seed, std::tuple< uint8_t, uint8_t > matrix_position) const override |
| std::optional< std::array< uint8_t, 1 > > | seed_expansion_domain_separator (const KyberConstants &mode) const override |
Definition at line 57 of file ml_kem_impl.h.
|
inlineoverrideprotectedvirtual |
Implements Botan::Kyber_Symmetric_Primitives.
Definition at line 67 of file ml_kem_impl.h.
References Botan::HashFunction::create_or_throw().
|
inlineoverrideprotectedvirtual |
Implements Botan::Kyber_Symmetric_Primitives.
Definition at line 69 of file ml_kem_impl.h.
References Botan::HashFunction::create_or_throw().
|
inlineoverrideprotectedvirtual |
Implements Botan::Kyber_Symmetric_Primitives.
Definition at line 71 of file ml_kem_impl.h.
References Botan::HashFunction::create_or_throw().
|
inlineoverrideprotectedvirtual |
Implements Botan::Kyber_Symmetric_Primitives.
Definition at line 75 of file ml_kem_impl.h.
|
inlineoverrideprotectedvirtual |
Implements Botan::Kyber_Symmetric_Primitives.
Definition at line 79 of file ml_kem_impl.h.
References Botan::XOF::create_or_throw(), and init_PRF().
|
inlineoverrideprotectedvirtual |
Implements Botan::Kyber_Symmetric_Primitives.
Definition at line 91 of file ml_kem_impl.h.
References Botan::XOF::create_or_throw(), and init_XOF().
|
inlineinherited |
Definition at line 53 of file kyber_symmetric_primitives.h.
|
inlineinherited |
Definition at line 44 of file kyber_symmetric_primitives.h.
References seed_expansion_domain_separator().
Referenced by Botan::Kyber_KEM_Decryptor::decapsulate(), Botan::ML_KEM_Decryptor::decapsulate(), and Botan::Kyber_Algos::expand_keypair().
|
inlineinherited |
Definition at line 36 of file kyber_symmetric_primitives.h.
References create_H().
|
inlineinherited |
Definition at line 33 of file kyber_symmetric_primitives.h.
References create_H().
|
inlineinherited |
Definition at line 40 of file kyber_symmetric_primitives.h.
References create_H().
|
inlineoverrideprotectedvirtual |
Implements Botan::Kyber_Symmetric_Primitives.
Definition at line 85 of file ml_kem_impl.h.
References Botan::XOF::clear(), Botan::store_be(), and Botan::XOF::update().
Referenced by create_PRF().
|
inlineoverrideprotectedvirtual |
Implements Botan::Kyber_Symmetric_Primitives.
Definition at line 98 of file ml_kem_impl.h.
References Botan::XOF::clear(), Botan::make_uint16(), Botan::store_be(), and Botan::XOF::update().
Referenced by create_XOF().
|
inlineinherited |
Definition at line 58 of file kyber_symmetric_primitives.h.
References create_J().
|
inlineinherited |
Definition at line 67 of file kyber_symmetric_primitives.h.
References create_KDF().
|
inlineinherited |
Definition at line 76 of file kyber_symmetric_primitives.h.
References create_PRF().
|
inlineoverrideprotectedvirtual |
Implements Botan::Kyber_Symmetric_Primitives.
Definition at line 59 of file ml_kem_impl.h.
References Botan::KyberConstants::k().
|
inlineinherited |
Setup a seeded PRF XOF for polynomial sampling.
Definition at line 95 of file kyber_symmetric_primitives.h.
References create_PRF(), and init_PRF().
|
inlineinherited |
Setup an XOF object for matrix sampling.
Definition at line 84 of file kyber_symmetric_primitives.h.
References create_XOF(), and init_XOF().