CoseStructures
The to-be-authenticated structures of COSE. OSCORE and EDHOC never send full COSE messages; they build these structures and feed them to the AEAD or signature algorithm.
Functions
Link copied to clipboard
fun encStructure(protected: ByteArray, externalAad: ByteArray, context: String = "Encrypt0"): ByteArray
Enc_structure = [ context, protected, external_aad ] (RFC 9052 §5.3), the AEAD associated data for COSE_Encrypt0. OSCORE (RFC 8613 §5.4) and EDHOC (RFC 9528 §5.3.2) use it with context "Encrypt0".
Link copied to clipboard