跳到主要内容

Module cipher

Module cipher 

Source
展开描述

TLS message encryption/decryption 接口。

结构体§

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.

枚举§

OutboundChunks
A collection of borrowed plaintext slices.

常量§

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

Trait§

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.

函数§

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