From ef49c2830eabd2d2880e2f0b5bdd121d3de0071c Mon Sep 17 00:00:00 2001 From: Orie Steele Date: Wed, 8 Nov 2023 10:20:31 +0100 Subject: [PATCH] updates --- draft-steele-cose-hash-envelope.md | 39 ++++++++++++++++++++++++++++-- 1 file changed, 37 insertions(+), 2 deletions(-) diff --git a/draft-steele-cose-hash-envelope.md b/draft-steele-cose-hash-envelope.md index 3559879..b48be7d 100644 --- a/draft-steele-cose-hash-envelope.md +++ b/draft-steele-cose-hash-envelope.md @@ -49,6 +49,7 @@ For large payloads this is a problem. This draft addresses this problem by descr ## Usage +### Protected Header ~~~~ cbor-diag { / Algorithm / @@ -58,12 +59,38 @@ For large payloads this is a problem. This draft addresses this problem by descr / typ of the envelope / TBD 0: application/hashed+cose / Hash algorithm of the payload / - TBD 1: sha-256 + TBD 1: 1 / sha-256 / / cty of the preimage of the payload / TBD 2: application/jwk+json } ~~~~ +### Attached Payload + +~~~~ cbor-diag +18( / COSE Sign 1 / + [ + h'a4013822...3a616263', / Protected / + {} / Unprotected / + h'317cedc7...c494e772', / Payload / + h'15280897...93ef39e5' / Signature / + ] +) +~~~~ + +### Detached Payload + +~~~~ cbor-diag +18( / COSE Sign 1 / + [ + h'a4013822...3a616263', / Protected / + {} / Unprotected / + nil, / Detached payload / + h'15280897...93ef39e5' / Signature / + ] +) +~~~~ + # Conventions and Definitions @@ -73,11 +100,19 @@ For large payloads this is a problem. This draft addresses this problem by descr TODO Security +## Choice of Hash Function + +Choose a good one. # IANA Considerations -This document has no IANA actions. +#### COSE Header Algorithm Parameters +* Name: payload hash algorithm +* Label: TBD_1 +* Value type: int +* Value registry: https://www.iana.org/assignments/named-information/named-information.xhtml +* Description: Hash algorithm used to produce the payload. --- back