generated from martinthomson/internet-draft-template
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathsd-cwt-example.cbor-diag
82 lines (82 loc) · 3.4 KB
/
sd-cwt-example.cbor-diag
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
/ cose-sign1 / 18( / sd_kbt / [
/ KBT protected / << {
/ alg / 1 : -7 / ES256 /,
/ typ / 16 : "application/kb+cwt",
/ kcwt / 13: << 18([ / issuer SD-CWT /
/ CWT protected / << {
/ alg / 1 : -35, / ES384 /
/ typ / 16 : "application/sd+cwt",
/ kid / 4 : 'https://issuer.example/cwt-key3',
/ sd_alg / 18 : -16 / SHA256 /
} >>,
/ CWT unprotected / {
/ sd_claims / 17 : [ /these are the disclosures/
<<[
/salt/ h'8d5c15fa86265d8ff77a0e92720ca837',
/claim/ 501, / inspector_license_number /
/value/ "ABCD-123456"
]>>,
<<[
/salt/ h'86c84b9c3614ba27073c7e5a475a2a13',
/value/ 1549560720 / inspected 7-Feb-2019 /
]>>,
<<[
/salt/ h'30eef86edeaa197df7bd3d17dd89cd87',
/claim/ "region",
/value/ "ca" /California/
]>>
],
},
/ CWT payload / << {
/ iss / 1 : "https://issuer.example",
/ sub / 2 : "https://device.example",
/ aud / 3 : "https://verifier.example",
/ exp / 4 : 1883000000,
/ iat / 6 : 1683000000,
/ cnf / 8 : {
/ cose key / 1 : {
/ alg: ES256 / 3: 35,
/ kty: EC2 / 1: 2,
/ crv: P-256 / -1: 1,
/ x / -2: h'768ed88626',
/ y / -3: h'6a48ccfd5d'
}
},
/most_recent_inspection_passed/ 500: true,
/ redacted_claim_keys / 59(0) : [
/ redacted inspector_license_number /
h'7e6e350907d0ba3aa7ae114f8da5b360' +
h'601c0bb7995cd40049b98e4f58fb6ec0'
],
/inspection_dates/ 502 : [
/ redacted inspection date 7-Feb-2019 /
60(h'a0f74264a8c97655c958aff3687f1390' +
h'ed0ab6f64cd78ba43c3fefee0de7b835')
/ redacted inspection date 4-Feb-2021 /
60(h'1e7275bcda9bc183079cd4515c5c0282' +
h'a2a0e9105b660933e2e68f9a3f40974b')
1674004740, / 2023-01-17T17:19:00 /
],
/ inspection_location / 503 : {
"country" : "us", / United States /
/ redacted_claim_keys / 59(0) : [
/ redacted region /
h'c47e3b047c1cd6d9d1e1e01514bc2ec9' +
h'ed010ac9ae1c93403ec72572bb1e00e7',
/ redacted postal_code /
h'0b616e522a05d8d134a834979710120d' +
h'41ac1522b056d5f9509cf7e850047302'
]
}
} >>, / end of issuer_sd_cwt payload /
/ CWT signature / h'3337af2e66959614'
])>>, / end of issuer SD-CWT /
}>>, / end of KBT protected header
/ KBT unprotected / {},
/ KBT payload / << {
/ cnonce / 39 : h'e0a156bb3f',
/ aud / 3 : "https://verifier.example",
/ iat / 6 : 1783000000
} >>, / end of kbt payload /
/ KBT signature / h'1237af2e678945'
]) / end of kbt /