-
Notifications
You must be signed in to change notification settings - Fork 5
245 lines (213 loc) · 9.09 KB
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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
module ietf-voucher {
yang-version 1.1;
namespace
"urn:ietf:params:xml:ns:yang:ietf-voucher";
prefix "vch";
import ietf-yang-types {
prefix yang;
reference "RFC 6991: Common YANG Data Types";
}
import ietf-restconf {
prefix rc;
description
"This import statement is only present to access
the yang-data extension defined in RFC 8040.";
reference "RFC 8040: RESTCONF Protocol";
}
organization
"IETF ANIMA Working Group";
contact
"WG Web: <http://tools.ietf.org/wg/anima/>
WG List: <mailto:[email protected]>
Author: Kent Watsen
<mailto:[email protected]>
Author: Max Pritikin
<mailto:[email protected]>
Author: Michael Richardson
<mailto:[email protected]>
Author: Toerless Eckert
<mailto:[email protected]>";
description
"This module defines the format for a voucher, which is produced by
a pledge's manufacturer or delegate (MASA) to securely assign a
pledge to an 'owner', so that the pledge may establish a secure
connection to the owner's network infrastructure.
The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL NOT',
'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'MAY', and 'OPTIONAL' in
the module text are to be interpreted as described in RFC 2119.
Copyright (c) 2017 IETF Trust and the persons identified as
authors of the code. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, is permitted pursuant to, and subject to the license
terms contained in, the Simplified BSD License set forth in Section
4.c of the IETF Trust's Legal Provisions Relating to IETF Documents
(http://trustee.ietf.org/license-info).
This version of this YANG module is part of RFC XXXX; see the RFC
itself for full legal notices.";
revision "2017-12-11" {
description
"Initial version";
reference
"RFC XXXX: Voucher Profile for Bootstrapping Protocols";
}
// Top-level statement
rc:yang-data voucher-artifact {
uses voucher-artifact-grouping;
}
// Grouping defined for future augmentations
grouping voucher-artifact-grouping {
description
"Grouping to allow reuse/extensions in future work.";
container voucher {
description
"A voucher assigns a pledge to an owner (pinned-domain-cert).";
leaf created-on {
type yang:date-and-time;
mandatory true;
description
"A value indicating the date this voucher was created. This
node is primarily for human consumption and auditing. Future
work MAY create verification requirements based on this
node.";
}
leaf expires-on {
type yang:date-and-time;
must "not(../nonce)";
description
"A value indicating when this voucher expires. The node is
optional as not all pledges support expirations, such as
pledges lacking a reliable clock.
If this field exists, then the the pledges MUST ensure that
the expires-on time has not yet passed. A pledge without
an accurate clock cannot meet this requirement.
The expires-on value MUST NOT exceed the expiration date
of any of the listed 'pinned-domain-cert' certificates.";
}
leaf assertion {
type enumeration {
enum verified {
description
"Indicates that the ownership has been positively
verified by the MASA (e.g., through sales channel
integration).";
}
enum logged {
description
"Indicates that the voucher has been issued after
minimal verification of ownership or control. The
issuance has been logged for detection of
potential security issues (e.g. recipients of
vouchers might verify for themselves that unexpected
vouchers are not in the log). This is similar to unsecured
trust-on-first-use principles but with the logging
providing a basis for detecting unexpected events.";
}
enum proximity {
description
"Indicates that the voucher has been issued after
the MASA verified a proximity proof provided by the
device and target domain. The issuance has been logged
for detection of potential security issues. This is
stronger than just logging, because it requires some
verification that the pledge and owner are
in communication, but is still dependent on analysis of
the logs to detect unexpected events.";
}
}
mandatory true;
description
"The assertion is a statement from the MASA regarding how
the owner was verified. This statement enables pledges
to support more detailed policy checks. Pledges MUST
ensure that the assertion provided is acceptable, per
local policy, before processing the voucher.";
}
leaf serial-number {
type string;
mandatory true;
description
"The serial number of the hardware. When processing a
voucher, a pledge MUST ensure that its serial number
matches this value. If no match occurs, then the
pledge MUST NOT process this voucher.";
}
leaf idevid-issuer {
type binary;
description
"The RFC5280 4.2.1.1 Authority Key Identifier OCTET STRING
from the pledge's IDevID certificate. Optional since some
serial-numbers are already unique within the scope of a
MASA. Inclusion of the statistically unique key identifier
ensures statistically unique identification of the hardware.
When processing a voucher, a pledge MUST ensure that its
IDevID Authority Key Identifier matches this value. If no
match occurs, then the pledge MUST NOT process this voucher.
When issuing a voucher, the MASA MUST ensure that this field
is populated for serial numbers that are not otherwise unique
within the scope of the MASA.";
}
leaf pinned-domain-cert {
type binary;
mandatory true;
description
"An X.509 v3 certificate structure as specified by RFC 5280,
Section 4 encoded using the ASN.1 distinguished encoding
rules (DER), as specified in ITU-T X.690.
This certificate is used by a pledge to trust a public key
infrastructure, in order to verify a domain certificate
supplied to the pledge separately by the bootstrapping
protocol. The domain certificate MUST have this certificate
somewhere in its chain of certificates. This certificate
MAY be an end-entity certificate, including a self-signed
entity.";
reference
"RFC 5280:
Internet X.509 Public Key Infrastructure Certificate
and Certificate Revocation List (CRL) Profile.
ITU-T X.690:
Information technology – ASN.1 encoding rules:
Specification of Basic Encoding Rules (BER),
Canonical Encoding Rules (CER) and Distinguished
Encoding Rules (DER).";
}
leaf domain-cert-revocation-checks {
type boolean;
must "../expires-on";
description
"A processing instruction to the pledge that it MUST verify
the revocation status for the domain certificate. This
instruction is only available for vouchers that expire. If
this field is not set, then normal PKIX behaviour applies
to validation of the domain certificate.";
}
leaf nonce {
type binary {
length "8..32";
}
must "not(../expires-on)";
description
"A value that can be used by a pledge in some bootstrapping
protocols to enable anti-replay protection. This node is
optional because it is not used by all bootstrapping
protocols.
When present, the pledge MUST compare the provided nonce
value with another value that the pledge randomly generated
and sent to a bootstrap server in an earlier bootstrapping
message. If the values do not match, then the pledge MUST
NOT process this voucher.";
}
leaf last-renewal-date {
type yang:date-and-time;
must "../expires-on";
description
"The date that the MASA projects to be the last date it
will renew a voucher on. This field is merely informative, it
is not processed by pledges.
Circumstances may occur after a voucher is generated that
may alter a voucher's validity period. For instance, a
vendor may associate validity periods with support contracts,
which may be terminated or extended over time.";
}
} // end voucher
} // end voucher-grouping
}