Skip to main content

Crate bssl_crypto

Crate bssl_crypto 

Source
Expand description

Rust BoringSSL bindings

Modules§

aead
Authenticated Encryption with Additional Data.
aes
Advanced Encryption Standard.
cipher
Ciphers.
digest
Hash functions.
ec
Definitions of NIST elliptic curves.
ecdh
Elliptic Curve Diffie-Hellman operations.
ecdsa
Elliptic Curve Digital Signature Algorithm.
ed25519
Ed25519, a signature scheme.
hkdf
Implements the HMAC-based Key Derivation Function from https://datatracker.ietf.org/doc/html/rfc5869.
hmac
Hash-based message authentication from https://datatracker.ietf.org/doc/html/rfc2104.
hpke
Hybrid Public Key Encryption
rsa
RSA signatures.
slhdsa
SLH-DSA-SHA2-128s.
x25519
Diffie-Hellman over curve25519.

Structs§

Buffer
Buffer represents an owned chunk of memory on the BoringSSL heap. Call as_ref() to get a &[u8] from it.
InvalidSignatureError
Error type for when a “signature” (either a public-key signature or a MAC) is incorrect.

Functions§

constant_time_compare
Returns true iff a and b contain the same bytes. It takes an amount of time dependent on the lengths, but independent of the contents of the slices a and b. The return type is a bool, since unlike memcmp in C this function cannot be used to put elements into a defined order.
rand_array
Returns an array of random bytes.
rand_bytes
Fills buf with random bytes.