pub fn append_padding(plaintext: &mut Vec<u8>, trailer: usize)Available on crate feature
std only.Expand description
Append a padding trailer of trailer total bytes to plaintext:
(trailer − PAD_LEN_FIELD) zero bytes, then the big-endian u16 count of
those zero bytes. trailer must be ≥ PAD_LEN_FIELD and ≤ u16::MAX + PAD_LEN_FIELD (callers get trailer from padding_trailer_len, which
respects both). A trailer < PAD_LEN_FIELD is a no-op (defensive).