fn pad_key(key_bytes: &mut Vec<u8>, min_length: u8)Expand description
Pad a key to a minimum length using PKCS7-like padding. The last N bytes of the padded bytes all have the value N. For example, padded to size 4, the value 0,0 becomes 0,0,2,2.
COSE-serialized keys must be distinguishable from SymmetricCryptoKey::Aes256CbcHmacKey keys when encoded as byte arrays with no additional content format. Padding ensures that the byte representation uniquely separates keys by size. The previous key types SymmetricCryptoKey::Aes256CbcHmacKey and SymmetricCryptoKey::Aes256CbcKey are 64 and 32 bytes long respectively.