Skip to content

Commit bfa4cfd

Browse files
author
nedmsmith
committed
Update comid-5.diag
added examples for identity and attest-key triples that exercises the optional conditions map
1 parent 2351b72 commit bfa4cfd

File tree

1 file changed

+127
-3
lines changed

1 file changed

+127
-3
lines changed

cddl/examples/comid-5.diag

Lines changed: 127 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@
1616
/ layer / 3 : 1
1717
}
1818
},
19-
[
19+
/ key-list / [
2020
/ tagged-pkix-base64-key-type / 554("base64_key_X"),
21-
/ tagged-pkix-base64-cert-type / 555("base64_cert"),
22-
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path"),
21+
/ tagged-pkix-base64-cert-type / 555("base64_cert_Y"),
22+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_Z"),
2323
/ tagged-thumbprint-type / 557([
2424
/ alg / 1, / sha256 /
2525
/ value / h'44aa336af4cb14a879432e53dd6571c7fa9bccafb75f488259262d6ea3a4d91b'
@@ -38,6 +38,130 @@
3838
/ value / h'66aa336af4cb14a879432e53dd6571c7fa9bccafb75f488259262d6ea3a4d91b'
3939
])
4040
]
41+
],
42+
[
43+
/ environment-map / {
44+
/ class / 0 : {
45+
/ class-id / 0 :
46+
/ tagged-uuid-type / 37( h'67b28b6c34cc40a19117ab5b05911e38' )
47+
}
48+
},
49+
/ key-list / [
50+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_X"),
51+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_Y")
52+
],
53+
/ conditions / {
54+
/ mkey / 0 : "thing 1"
55+
}
56+
],
57+
[
58+
/ environment-map / {
59+
/ class / 0 : {
60+
/ class-id / 0 :
61+
/ tagged-uuid-type / 37( h'67b28b6c34cc40a19117ab5b05911e39' )
62+
}
63+
},
64+
/ key-list / [
65+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_X"),
66+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_Y")
67+
],
68+
/ conditions / {
69+
/ mkey / 0 : "thing 2",
70+
/ authorized-by / 1: [
71+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_A"),
72+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_B")
73+
]
74+
}
75+
],
76+
[
77+
/ environment-map / {
78+
/ class / 0 : {
79+
/ class-id / 0 :
80+
/ tagged-uuid-type / 37( h'67b28b6c34cc40a19117ab5b05911e40' )
81+
}
82+
},
83+
/ key-list / [
84+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_X"),
85+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_Y")
86+
],
87+
/ conditions / {
88+
/ authorized-by / 1: [
89+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_A"),
90+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_B")
91+
]
92+
}
93+
]
94+
],
95+
/ attest-key-triples / 3 : [
96+
[
97+
/ environment-map / {
98+
/ class / 0 : {
99+
/ class-id / 0 :
100+
/ tagged-uuid-type / 37(
101+
h'67b28b6c34cc40a19117ab5b05911e37'
102+
),
103+
/ vendor / 1 : "ACME Inc.",
104+
/ model / 2 : "ACME RoadRunner",
105+
/ layer / 3 : 1
106+
}
107+
},
108+
/ key-list / [
109+
/ tagged-pkix-base64-key-type / 554("base64_key_X"),
110+
/ tagged-pkix-base64-cert-type / 555("base64_cert_Y"),
111+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_Z")
112+
]
113+
],
114+
[
115+
/ environment-map / {
116+
/ class / 0 : {
117+
/ class-id / 0 :
118+
/ tagged-uuid-type / 37( h'67b28b6c34cc40a19117ab5b05911e30' )
119+
}
120+
},
121+
/ key-list / [
122+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_X"),
123+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_Y")
124+
],
125+
/ conditions / {
126+
/ mkey / 0 : "thing 1"
127+
}
128+
],
129+
[
130+
/ environment-map / {
131+
/ class / 0 : {
132+
/ class-id / 0 :
133+
/ tagged-uuid-type / 37( h'67b28b6c34cc40a19117ab5b05911e31' )
134+
}
135+
},
136+
/ key-list / [
137+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_X"),
138+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_Y")
139+
],
140+
/ conditions / {
141+
/ mkey / 0 : "thing 2",
142+
/ authorized-by / 1: [
143+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_A"),
144+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_B")
145+
]
146+
}
147+
],
148+
[
149+
/ environment-map / {
150+
/ class / 0 : {
151+
/ class-id / 0 :
152+
/ tagged-uuid-type / 37( h'67b28b6c34cc40a19117ab5b05911e32' )
153+
}
154+
},
155+
/ key-list / [
156+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_X"),
157+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_Y")
158+
],
159+
/ conditions / {
160+
/ authorized-by / 1: [
161+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_A"),
162+
/ tagged-pkix-base64-cert-path-type / 556("base64_cert_path_B")
163+
]
164+
}
41165
]
42166
]
43167
}

0 commit comments

Comments
 (0)