Module chacha20_poly1305_openssh

Source
Expand description

The [email protected] AEAD-ish construct.

This should only be used by SSH implementations. It has a similar, but different API from aws_lc_rs::aead because the construct cannot use the same API as aws_lc_rs::aead due to the way the construct handles the encrypted packet length.

The concatenation of a and b is denoted a||b. K_1 and K_2 are defined in the [email protected] specification. packet_length, padding_length, payload, and random padding are defined in RFC 4253. The term plaintext is used as a shorthand for padding_length||payload||random padding.

ยงFIPS

The APIs offered in this module must not be used.

Structsยง

Key ๐Ÿ”’
OpeningKey
A key for opening packets.
SealingKey
A key for sealing packets.

Constantsยง

KEY_LEN
The length of key.
PACKET_LENGTH_LEN
The length in bytes of the packet_length field in a SSH packet.
TAG_LEN
The length in bytes of an authentication tag.

Functionsยง

derive_poly1305_key ๐Ÿ”’
make_nonce ๐Ÿ”’
verify ๐Ÿ”’