Module cipher

Source
Expand description

TLS message encryption/decryption interfaces.

Structs§

AeadKey
A key for an AEAD algorithm.
BorrowedPayload
InboundOpaqueMessage
A TLS frame, named TLSPlaintext in the standard.
InboundPlainMessage
A TLS frame, named TLSPlaintext in the standard.
Iv
A write or read IV.
KeyBlockShape
How a TLS1.2 key_block is partitioned.
Nonce
A nonce. This is unique for all messages on a connection.
OutboundOpaqueMessage
A TLS frame, named TLSPlaintext in the standard.
OutboundPlainMessage
A TLS frame, named TLSPlaintext in the standard.
PlainMessage
A decrypted TLS frame
PrefixedPayload
UnsupportedOperationError
An error indicating that the AEAD algorithm does not support the requested operation.

Enums§

OutboundChunks
A collection of borrowed plaintext slices.

Constants§

NONCE_LEN
Size of TLS nonces (incorrectly termed “IV” in standard) for all supported ciphersuites (AES-GCM, Chacha20Poly1305)

Traits§

MessageDecrypter
Objects with this trait can decrypt TLS messages.
MessageEncrypter
Objects with this trait can encrypt TLS messages.
Tls12AeadAlgorithm
Factory trait for building MessageEncrypter and MessageDecrypter for a TLS1.2 cipher suite.
Tls13AeadAlgorithm
Factory trait for building MessageEncrypter and MessageDecrypter for a TLS1.3 cipher suite.

Functions§

make_tls12_aad
Returns a TLS1.2 additional_data encoding.
make_tls13_aad
Returns a TLS1.3 additional_data encoding.