Skip to main content

Module cipher

Module cipher 

Source
Expand description

TLS message encryption/decryption interfaces.

Structs§

AeadKey
A key for an AEAD algorithm.
EncryptBuffer
A fixed-size buffer into which a RecordEncrypter writes an encrypted record payload.
InboundOpaque
A borrowed payload buffer.
Iv
A write or read IV.
KeyBlockShape
How a TLS1.2 key_block is partitioned.
Nonce
A nonce. This is unique for all records on a connection.
Record
A TLS record with encoded (but not necessarily encrypted) payload.
UnsupportedOperationError
An error indicating that the AEAD algorithm does not support the requested operation.

Enums§

EncodableVersion
A protocol version that can be encoded.
OutboundPlain
A collection of borrowed plaintext slices.
Payload
An externally length’d payload
RecordError
Errors from trying to parse a TLS record.

Constants§

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

Traits§

RecordDecrypter
Objects with this trait can decrypt TLS records.
RecordEncrypter
Objects with this trait can encrypt TLS records.
Tls12AeadAlgorithm
Factory trait for building RecordEncrypter and RecordDecrypter for a TLS1.2 cipher suite.
Tls13AeadAlgorithm
Factory trait for building RecordEncrypter and RecordDecrypter 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.