-
Notifications
You must be signed in to change notification settings - Fork 4
/
constrained-voucher-13.txt
3080 lines (2066 loc) · 106 KB
/
constrained-voucher-13.txt
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
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
anima Working Group M. Richardson
Internet-Draft Sandelman Software Works
Intended status: Standards Track P. van der Stok
Expires: 26 January 2022 vanderstok consultancy
P. Kampanakis
Cisco Systems
E. Dijk
IoTconsultancy.nl
25 July 2021
Constrained Voucher Artifacts for Bootstrapping Protocols
draft-ietf-anima-constrained-voucher-13
Abstract
This document defines a protocol to securely assign a Pledge to an
owner and to enroll it into the owner's network. The protocol uses
an artifact that is signed by the Pledge's manufacturer. This
artifact is known as a "voucher".
This document builds upon the work in [RFC8366] and [BRSKI], but
defines an encoding of the voucher in CBOR rather than JSON, and
enables the Pledge to perform its transactions using CoAP rather than
HTTPS.
The use of Raw Public Keys instead of X.509 certificates for security
operations is also explained.
Status of This Memo
This Internet-Draft is submitted in full conformance with the
provisions of BCP 78 and BCP 79.
Internet-Drafts are working documents of the Internet Engineering
Task Force (IETF). Note that other groups may also distribute
working documents as Internet-Drafts. The list of current Internet-
Drafts is at https://datatracker.ietf.org/drafts/current/.
Internet-Drafts are draft documents valid for a maximum of six months
and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference
material or to cite them other than as "work in progress."
This Internet-Draft will expire on 26 January 2022.
Richardson, et al. Expires 26 January 2022 [Page 1]
Internet-Draft Constrained Voucher July 2021
Copyright Notice
Copyright (c) 2021 IETF Trust and the persons identified as the
document authors. All rights reserved.
This document is subject to BCP 78 and the IETF Trust's Legal
Provisions Relating to IETF Documents (https://trustee.ietf.org/
license-info) in effect on the date of publication of this document.
Please review these documents carefully, as they describe your rights
and restrictions with respect to this document. Code Components
extracted from this document must include Simplified BSD License text
as described in Section 4.e of the Trust Legal Provisions and are
provided without warranty as described in the Simplified BSD License.
Table of Contents
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3
2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 4
3. Requirements Language . . . . . . . . . . . . . . . . . . . . 4
4. Overview of Protocol . . . . . . . . . . . . . . . . . . . . 5
5. BRSKI-EST Protocol . . . . . . . . . . . . . . . . . . . . . 6
5.1. Discovery, URIs and Content Formats . . . . . . . . . . . 6
5.2. Extensions to BRSKI . . . . . . . . . . . . . . . . . . . 8
5.3. Extensions to EST-coaps . . . . . . . . . . . . . . . . . 9
5.3.1. Pledge Extensions . . . . . . . . . . . . . . . . . . 9
5.3.2. Registrar Extensions . . . . . . . . . . . . . . . . 10
6. BRSKI-MASA Protocol . . . . . . . . . . . . . . . . . . . . . 10
7. Pinning in Voucher Artifacts . . . . . . . . . . . . . . . . 11
7.1. Registrar Identity Selection and Encoding . . . . . . . . 11
7.2. MASA Pinning Policy . . . . . . . . . . . . . . . . . . . 12
7.3. Pinning of Raw Public Keys . . . . . . . . . . . . . . . 13
8. Artifacts . . . . . . . . . . . . . . . . . . . . . . . . . . 14
8.1. Voucher Request artifact . . . . . . . . . . . . . . . . 14
8.1.1. Tree Diagram . . . . . . . . . . . . . . . . . . . . 15
8.1.2. SID values . . . . . . . . . . . . . . . . . . . . . 15
8.1.3. YANG Module . . . . . . . . . . . . . . . . . . . . . 16
8.1.4. Example voucher request artifact . . . . . . . . . . 20
8.2. Voucher artifact . . . . . . . . . . . . . . . . . . . . 20
8.2.1. Tree Diagram . . . . . . . . . . . . . . . . . . . . 20
8.2.2. SID values . . . . . . . . . . . . . . . . . . . . . 21
8.2.3. YANG Module . . . . . . . . . . . . . . . . . . . . . 21
8.2.4. Example voucher artifacts . . . . . . . . . . . . . . 24
8.3. Signing voucher and voucher-request artifacts with
COSE . . . . . . . . . . . . . . . . . . . . . . . . . . 25
9. Design Considerations . . . . . . . . . . . . . . . . . . . . 26
10. Raw Public Key Use Considerations . . . . . . . . . . . . . . 26
10.1. The Registrar Trust Anchor . . . . . . . . . . . . . . . 26
10.2. The Pledge Voucher Request . . . . . . . . . . . . . . . 27
Richardson, et al. Expires 26 January 2022 [Page 2]
Internet-Draft Constrained Voucher July 2021
10.3. The Voucher Response . . . . . . . . . . . . . . . . . . 27
11. Security Considerations . . . . . . . . . . . . . . . . . . . 27
11.1. Clock Sensitivity . . . . . . . . . . . . . . . . . . . 27
11.2. Protect Voucher PKI in HSM . . . . . . . . . . . . . . . 28
11.3. Test Domain Certificate Validity when Signing . . . . . 28
12. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 28
12.1. Resource Type Registry . . . . . . . . . . . . . . . . . 28
12.2. The IETF XML Registry . . . . . . . . . . . . . . . . . 28
12.3. The YANG Module Names Registry . . . . . . . . . . . . . 28
12.4. The RFC SID range assignment sub-registry . . . . . . . 29
12.5. Media Types Registry . . . . . . . . . . . . . . . . . . 29
12.5.1. application/voucher-cose+cbor . . . . . . . . . . . 29
12.6. CoAP Content-Format Registry . . . . . . . . . . . . . . 30
13. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 30
14. Changelog . . . . . . . . . . . . . . . . . . . . . . . . . . 30
15. References . . . . . . . . . . . . . . . . . . . . . . . . . 31
15.1. Normative References . . . . . . . . . . . . . . . . . . 31
15.2. Informative References . . . . . . . . . . . . . . . . . 33
Appendix A. Library support for BRSKI . . . . . . . . . . . . . 34
A.1. OpensSSL . . . . . . . . . . . . . . . . . . . . . . . . 35
A.2. mbedTLS . . . . . . . . . . . . . . . . . . . . . . . . . 36
A.3. wolfSSL . . . . . . . . . . . . . . . . . . . . . . . . . 37
Appendix B. Constrained BRSKI-EST messages . . . . . . . . . . . 37
B.1. enrollstatus . . . . . . . . . . . . . . . . . . . . . . 37
B.2. voucher_status . . . . . . . . . . . . . . . . . . . . . 38
Appendix C. COSE examples . . . . . . . . . . . . . . . . . . . 38
C.1. Pledge, Registrar and MASA keys . . . . . . . . . . . . . 42
C.1.1. Pledge private key . . . . . . . . . . . . . . . . . 42
C.1.2. Registrar private key . . . . . . . . . . . . . . . . 42
C.1.3. MASA private key . . . . . . . . . . . . . . . . . . 43
C.2. Pledge, Registrar and MASA certificates . . . . . . . . . 43
C.2.1. Pledge IDevID certificate . . . . . . . . . . . . . . 43
C.2.2. Registrar Certificate . . . . . . . . . . . . . . . . 45
C.2.3. MASA Certificate . . . . . . . . . . . . . . . . . . 47
C.3. COSE signed voucher request from Pledge to Registrar . . 49
C.4. COSE signed voucher request from Registrar to MASA . . . 51
C.5. COSE signed voucher from MASA to Pledge via Registrar . . 53
Contributors . . . . . . . . . . . . . . . . . . . . . . . . . . 54
Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 54
1. Introduction
Secure enrollment of new nodes into constrained networks with
constrained nodes presents unique challenges. There are network
bandwidth and code size issues to contend with. A solution for
autonomous enrollment such as BRSKI [BRSKI] may be too large in terms
of code size or bandwidth required.
Richardson, et al. Expires 26 January 2022 [Page 3]
Internet-Draft Constrained Voucher July 2021
Therefore, this document defines a constrained version of the voucher
artifact [RFC8366], along with a constrained version of [BRSKI] that
makes use of the constrained CoAP-based version of EST, EST-coaps
[I-D.ietf-ace-coap-est] rather than EST over HTTPS [RFC7030].
While the [RFC8366] voucher is by default serialized to JSON with a
signature in CMS, this document defines a new voucher serialization
to CBOR ([RFC7049]) with a signature in COSE
[I-D.ietf-cose-rfc8152bis-struct]. This COSE-signed CBOR-encoded
voucher can be transported using secured CoAP or HTTP. The CoAP
connection (between Pledge and Registrar) is to be protected by
either OSCORE+EDHOC or DTLS (CoAPS). The HTTP connection (between
Registrar and MASA) is to be protected using TLS (HTTPS).
This document specifies a constrained voucher-request artifact based
on Section 3 of [BRSKI], and voucher(-request) transport over CoAP
based on Section 3 of [BRSKI] and on [I-D.ietf-ace-coap-est].
The CBOR definitions for the constrained voucher format are defined
using the mechanism described in [I-D.ietf-core-yang-cbor] using the
SID mechanism explained in [I-D.ietf-core-sid]. As the tooling to
convert YANG documents into a list of SID keys is still in its
infancy, the table of SID values presented here MUST be considered
normative rather than the output of the pyang tool.
There is additional work when the voucher is integrated into the key-
exchange, described in [I-D.selander-ace-ake-authz]. This work is
not in scope for this document.
2. Terminology
The following terms are defined in [RFC8366], and are used
identically as in that document: artifact, domain, imprint, Join
Registrar/Coordinator (JRC), Manufacturer Authorized Signing
Authority (MASA), Pledge, Registrar, Trust of First Use (TOFU), and
Voucher.
The following terms from [BRSKI] are used identically as in that
document: Domain CA, enrollment, IDevID, Join Proxy, LDevID,
manufacturer, nonced, nonceless, PKIX.
3. Requirements Language
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and
"OPTIONAL" in this document are to be interpreted as described in
BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all
capitals, as shown here.
Richardson, et al. Expires 26 January 2022 [Page 4]
Internet-Draft Constrained Voucher July 2021
4. Overview of Protocol
[RFC8366] provides for vouchers that assert proximity, that
authenticate the Registrar and that can offer varying levels of anti-
replay protection.
This document does not make any extensions to the semantic meaning of
vouchers, only the encoding has been changed to optimize for
constrained devices and networks. The two main parts of the BRSKI
protocol are named separately in this document: BRSKI-EST for the
protocol between Pledge and Registrar, and BRSKI-MASA for the
protocol between the Registrar and the MASA.
Time-based vouchers are supported in this definition, but given that
constrained devices are extremely unlikely to have accurate time,
their use will be uncommon. Most Pledges using these constrained
vouchers will be online during enrollment and will use live nonces to
provide anti-replay protection rather than expiry times.
[RFC8366] defines the voucher artifact, while the Voucher Request
artifact was defined in [BRSKI]. This document defines both a
constrained voucher and a constrained voucher-request. They are
presented in the order "voucher-request", followed by a "voucher"
response as this is the order that they occur in the protocol.
The constrained voucher request MUST be signed by the Pledge. It
signs using the private key associated with its IDevID X.509
certificate, or if an IDevID is not available, then the private key
associated with its manufacturer-installed raw public key (RPK).
Section 10 provides additional details on PKIX-less operations.
The constrained voucher MUST be signed by the MASA.
For the constrained voucher request this document defines two
distinct methods for the Pledge to identify the Registrar: using
either the Registrar's X.509 certificate, or using a raw public key
(RPK) of the Registrar.
For the constrained voucher also these two methods are supported to
indicate (pin) a trusted domain identity: using either a pinned
domain X.509 certificate, or a pinned raw public key (RPK).
The BRSKI architectures mandates that the MASA be aware of the
capabilities of the pledge. This is not a hardship as the pledges
are constructed by a manufacturer who also arranges for the MASA to
be aware of the inventory of devices.
Richardson, et al. Expires 26 January 2022 [Page 5]
Internet-Draft Constrained Voucher July 2021
The MASA therefore knows if the pledge supports PKIX operations, PKIX
format certificates, or if the pledge is limited to Raw Public Keys
(RPK). Based upon this, the MASA can select which attributes to use
in the voucher for certain operations, like the pinning of the
Registrar identity. This is described in more detail in
Section 8.2.3, Section 7 and Section 7.3 (for RPK specifically).
5. BRSKI-EST Protocol
This section describes the constrained BRSKI extensions to EST-coaps
[I-D.ietf-ace-coap-est] to transport the voucher between Registrar
and Pledge (optionally via a Join Proxy) over CoAP. The extensions
are targeting low-resource networks with small packets.
The constrained BRSKI-EST protocol described in this section is
between the Pledge and the Registrar only.
5.1. Discovery, URIs and Content Formats
To keep the protocol messages small the EST-coaps and constrained-
BRSKI URIs are shorter than the respective EST and BRSKI URIs.
The EST-coaps server URIs differ from the EST URIs by replacing the
scheme https by coaps and by specifying shorter resource path names.
Below are some examples; the first two using a discovered short path
name and the last one using the well-known URI of EST which requires
no discovery.
coaps://server.example.com/est/<short-name>
coaps://server.example.com/e/<short-name>
coaps://server.example.com/.well-known/est/<short-name>
Similarly the constrained BRSKI server URIs differ from the BRSKI
URIs by replacing the scheme https by coaps and by specifying shorter
resource path names. Below are some examples; the first two using a
discovered short path name and the last one using the well-known URI
prefix which requires no discovery. This is the same "/.well-known/
brski" prefix as defined in [BRSKI] Section 5.
coaps://server.example.com/brski/<short-name>
coaps://server.example.com/b/<short-name>
coaps://server.example.com/.well-known/brski/<short-name>
Richardson, et al. Expires 26 January 2022 [Page 6]
Internet-Draft Constrained Voucher July 2021
Figure 5 in section 3.2.2 of [RFC7030] enumerates the operations
supported by EST, for which Table 1 in Section 5.1 of
[I-D.ietf-ace-coap-est] enumerates the corresponding EST-coaps short
path names. Similarly, Table 1 provides the mapping from the
supported BRSKI extension URI paths to the constrained-BRSKI URI
paths.
+=================+============================+
| BRSKI resource | constrained-BRSKI resource |
+=================+============================+
| /requestvoucher | /rv |
+-----------------+----------------------------+
| /voucher_status | /vs |
+-----------------+----------------------------+
| /enrollstatus | /es |
+-----------------+----------------------------+
Table 1: BRSKI URI paths mapping to
constrained BRSKI URI paths
Note that /requestvoucher indicated above occurs between the Pledge
and Registrar (in scope of the BRSKI-EST protocol), but it also
occurs between Registrar and MASA. However, as described in
Section 5, this section and above table addresses only the BRSKI-EST
protocol.
Pledges that wish to discover the available BRSKI bootstrap options/
formats, or reduce the size of the CoAP headers by eliminating the
"/.well-known/brski" path, can do a discovery operation using
[RFC6690] Section 4 by sending a discovery query to the Registrar.
For example, if the Registrar supports a short BRSKI URL (/b) and
supports the voucher format "application/voucher-cose+cbor" (TBD3),
and status reporting in both CBOR and JSON formats:
REQ: GET /.well-known/core?rt=brski*
RES: 2.05 Content
Content-Format: 40
Payload:
</b>;rt=brski,
</b/rv>;rt=brski.rv;ct=TBD3,
</b/vs>;rt=brski.vs;ct="50 60",
</b/es>;rt=brski.es;ct="50 60"
The Registrar is under no obligation to provide shorter URLs, and MAY
respond to this query with only the "/.well-known/brski/<short-name>"
end points for the short names as defined in Table 1.
Richardson, et al. Expires 26 January 2022 [Page 7]
Internet-Draft Constrained Voucher July 2021
Registrars that have implemented shorter URLs MUST also respond in
equivalent ways to the corresponding "/.well-known/brski/<short-
name>" URLs, and MUST NOT distinguish between them. In particular, a
Pledge MAY use the longer and shorter URLs in combination.
When responding to a discovery request for BRSKI resources, the
server MAY in addition return the full resource paths and the content
types which are supported at those end-points as shown in above
example. This is useful when multiple content types are specified
for a particular resource on the server. The server responds with
only the root path for the BRSKI resource (rt=brski, resource /b in
above example) and no others in case the client queries for only
rt=brski type resources. (So, a query for rt=brski, without the
wildcard character.)
The return of multiple content-types in the "ct" attribute allows the
Pledge to choose the most appropriate one. Note that Content-Format
TBD3 ("application/voucher-cose+cbor") is defined in this document.
The Content-Format 50 ("application/json") MAY be supported and
Content-Format 60 ("application/cbor") MUST be supported by the
Registrar for the /vs and /es resources. Content-Format TBD3 MUST be
supported by the Registrar for the /rv resource. If the "ct"
attribute is not indicated for the /rv resource in the link format
description, this implies that at least TBD3 is supported.
The Pledge and MASA need to support one or more formats (at least
TBD3) for the voucher and for the voucher request. The MASA needs to
support all formats that the Pledge, produced by that manufacturer,
supports.
5.2. Extensions to BRSKI
A Pledge that only supports the BRSKI bootstrap method and already
knows the IP address and port of a Registrar or Join Proxy to use
SHOULD NOT use discovery. In such case it is more efficient to just
try its supported bootstrap method (e.g. /rv) via the well-known
BRSKI resource on the known address and port. This avoids the Pledge
having to unnecessarily implement CoRE Link Format parsing. The
method via which the Pledge learns the address/port of a Registrar or
Join Proxy to use is out of scope of this document.
A Registrar SHOULD host any discoverable BRSKI resources on the same
(UDP) server port that the Pledge's initial DTLS connection is using.
This avoids the overhead of the Pledge having to reconnect using
DTLS, in order to access discovered resource(s).
Richardson, et al. Expires 26 January 2022 [Page 8]
Internet-Draft Constrained Voucher July 2021
5.3. Extensions to EST-coaps
A Pledge that already is DTLS-connected to either a Join Proxy or
Registrar, and which only supports the EST-coaps enrollment method,
SHOULD NOT use discovery for EST-coaps resources. This is because it
is more efficient to just try its supported enrollment method (e.g.
/sen) via the well-known EST resource on the current DTLS connection.
This avoids an additional round-trip of packets and avoids the Pledge
having to unnecessarily implement CoRE Link Format parsing.
A Registrar SHOULD host any discoverable EST-coaps resources on the
same (UDP) server port that the Pledge's DTLS initial connection is
using. This avoids the Pledge having to reconnect using DTLS, in
order to proceed with EST enrollment after the BRSKI bootstrap. [TBD
EDNOTE: a Registrar that does host EST resources on another port
won't be able to onboard Pledges that skip the discovery, so not
interoperable. Should we fix this?]
5.3.1. Pledge Extensions
A constrained Pledge SHOULD NOT support the optional EST "CSR
attributes request" (/att) to minimize network traffic and reduce
code size.
When creating the CSR, the Pledge selects which attributes to
include. One or more Subject Distinguished Name fields MUST be
included. If the Pledge has no specific information on what
attributes/fields are desired in the CSR, it MUST use the Subject
Distinguished Name fields from its IDevID unmodified. The Pledge can
receive such information via the voucher (encoded in a vendor-
specific way) or some other, out-of-band means.
A constrained Pledge MAY use the following optimized EST-coaps
procedure to minimize both network traffic and code size:
1. if the voucher, that validates the current Registrar, contains a
single pinned domain CA certificate, the Pledge provisionally
considers this certificate as the EST trust anchor, in other
words, it provisionally accepts this CA certificate as if it were
the result of "CA certificates request" (/crts) to the Registrar.
2. Using this CA certificate as trust anchor it proceeds with EST
simple enrollment (/sen) to obtain its provisionally trusted
LDevID.
Richardson, et al. Expires 26 January 2022 [Page 9]
Internet-Draft Constrained Voucher July 2021
3. If the Pledge validates that the trust anchor CA was used to sign
its LDevID, the Pledge accepts the pinned domain CA certificate
as the legitimate trust anchor CA for the Registrar's domain and
accepts the associated LDevID.
4. If the trust anchor CA was NOT used to sign its LDevID, the
Pledge MUST perform an actual "CA certificates request" (/crts)
to the EST server to obtain the EST CA trust anchor(s) since
these differ from the (temporary) pinned domain CA.
5. When doing this /crts request, the Pledge MAY use a CoAP Accept
Option with value TBD287 ("application/pkix-cert") to limit the
number of returned EST CA trust anchors to only one.
6. If the Pledge cannot obtain the single CA certificate or the
finally validated CA certificate cannot be chained to the LDevID,
then the Pledge MUST abort the enrollment process and report the
error using the enrollment status telemetry (/es).
5.3.2. Registrar Extensions
The Content-Format 50 MAY be supported and 60 MUST be supported by
the Registrar for the /vs and /es resources. Content-Format TBD3
MUST be supported by the Registrar for the /rv resource.
When a Registrar receives a "CA certificates request" (/crts) request
with a CoAP Accept Option with value TBD287 ("application/pkix-cert")
it SHOULD return only the single CA certificate that is the
envisioned or actual authority for the current, authenticated Pledge
making the request. The only exception case is when the Registrar is
configured to not support a request for a single CA certificate for
operational or security reasons, e.g. because every device enrolled
into the domain needs to use multiple CAs. In such exception case
the Registrar returns the CoAP response 4.06 Not Acceptable to
indicate that only the default Content-Format of 281 "application/
pkcs7-mime;smime-type=certs-only" which supports multiple
certificates is available.
6. BRSKI-MASA Protocol
[BRSKI] section 5.4 describes a connection between the Registrar and
the MASA as being a normal TLS connection using HTTPS. This document
does not change that. The Registrar MAY use the new format
"application/voucher-cose+cbor" in its voucher request to MASA, or
the existing BRSKI format "application/voucher-cms+json" defined by
[BRSKI]. The MASA MUST support both formats. The Registrar
indicates the voucher format it wants to receive from MASA using the
HTTP Accept header.
Richardson, et al. Expires 26 January 2022 [Page 10]
Internet-Draft Constrained Voucher July 2021
At the moment of writing the creation of coaps based MASAs is deemed
unrealistic. The use of CoAP for the BRSKI-MASA connection can be
the subject of another document. Some consideration was made to
specify CoAP support for consistency, but:
* the Registrar is not expected to be so constrained that it cannot
support HTTPS client connections.
* the technology and experience to build Internet-scale HTTPS
responders (which the MASA is) is common, while the experience
doing the same for CoAP is much less common.
* in many Enterprise networks, outgoing UDP connections are often
treated as suspicious, and there seems to be no advantage to using
CoAP in that environment.
* a Registrar is likely to provide onboarding services to both
constrained and non-constrained devices. Such a Registrar would
need to speak HTTPS anyway.
* similarly, a manufacturer is likely to offer both constrained and
non-constrained devices, so there may in practice be no situation
in which the MASA could be CoAP-only. Additionally, as the MASA
is intended to be a function that can easily be oursourced to a
third-party service provider, reducing the complexity would also
seem to reduce the cost of that function.
7. Pinning in Voucher Artifacts
The voucher is a statement by the MASA for use by the Pledge that
provide the identity of the Pledge's owner. This section describes
how the owner's identity is determined and how it is encoded within
the voucher.
7.1. Registrar Identity Selection and Encoding
Section 5.5 of [BRSKI] describes BRSKI policies for selection of the
owner identity. It indicates some of the flexibility that is
possible for the Registrar. The recommendation made there is for the
Registrar to include only certificates in the voucher request (CMS)
signing structure that participate in the certificate chain that is
to be pinned.
Richardson, et al. Expires 26 January 2022 [Page 11]
Internet-Draft Constrained Voucher July 2021
The MASA is expected to evaluate the certificates included by the
Registrar in its voucher request, forming them into a chain with the
Registrar's (signing) identity on one end. Then, it pins a
certificate selected from the chain. For instance, for a domain with
a two-level certification authority (see Figure 1), where the
voucher-request has been signed by "Registrar", its signing structure
includes two additional CA certificates:
.------------------.
| domain CA (1) |
| trust anchor |
'------------------'
|
v
.------------.
| domain (2) |
| Sub-CA |
'------------'
|
|
v
.----------------.
| domain |
| Registrar (3) |
| EE certificate |
'----------------'
Figure 1: Two-Level CA PKI
When the Registrar is using a COSE-signed constrained voucher request
towards MASA, instead of a regular CMS-signed voucher request, the
COSE_Sign1 object contains a protected and an unprotected header.
The Registrar MUST place all the certificates for the chain in an
"x5bag" attribute in the unprotected header [I-D.ietf-cose-x509].
7.2. MASA Pinning Policy
The MASA, having assembled and verified the chain in the signing
structure of the voucher request, will now need to select a
certificate to pin. (For the case that only the Registrar's End-
Entity certificate is included, only this certificate can be selected
and this section does not apply.) The BRSKI policy for pinning by
the MASA as described in Section 5.5.2 of [BRSKI] leaves much
flexibility to the manufacturer. The present document adds the
following rules to the MASA pinning policy to reduce the network
load:
Richardson, et al. Expires 26 January 2022 [Page 12]
Internet-Draft Constrained Voucher July 2021
1. for a voucher containing a nonce, it SHOULD select the most
specific (lowest-level) CA certificate in the chain.
2. for a nonceless voucher, it SHOULD select the least-specific
(highest-level) CA certificate in the chain that is allowed under
the MASA's policy for this specific domain.
The rationale for 1. is that in case of a voucher with nonce, the
voucher is valid only in scope of the present DTLS connection between
Pledge and Registrar anyway, so it would have no benefit to pin a
higher-level CA. By pinning the most specific CA the constrained
Pledge can validate its DTLS connection using less crypto operations.
The rationale for pinning a CA instead of the Registrar's End-Entity
certificate directly is the following benefit on constrained
networks: the pinned certificate in the voucher can in common cases
be re-used as a Domain CA trust anchor during the EST enrollment and
during the operational phase that follows after EST enrollment, as
explained in Section 5.3.1.
The rationale for 2. follows from the flexible BRSKI trust model for,
and purpose of, nonceless vouchers (Sections 5.5.* and 7.4.1 of
[BRSKI]).
Using the previous example of a domain with a two-level certification
authority, the most specific CA ("Sub-CA") is the identity that is
pinned by MASA in a nonced voucher. A Registrar that wished to have
only the Registrar's End-Entity certificate pinned would omit the
"domain CA" and "Sub-CA" certificates from the voucher-request.
In case of a nonceless voucher, the MASA would depending on trust
level pin only "Registrar" certificate (low trust in customer), or
the "Sub-CA" certificate (in case of medium trust, implying that any
Registrar of that sub-domain is acceptable), or even the "domain CA"
certificate (in case of high trust in the customer, and possibly a
pre-agreed need of the customer to obtain flexible long-lived
vouchers).
7.3. Pinning of Raw Public Keys
Specifically for constrained use cases, the pinning of the raw public
key (RPK) of the Registrar is also supported in the constrained
voucher, instead of an X.509 certificate. If an RPK is pinned it
MUST be the RPK of the Registrar.
When the Pledge is known by MASA to support RPK but not X.509
certificates, the voucher produced by the MASA pins the RPK of the
Registrar in either the "pinned-domain-pubk" or "pinned-domain-pubk-
sha256" field of a voucher. This is described in more detail in
Richardson, et al. Expires 26 January 2022 [Page 13]
Internet-Draft Constrained Voucher July 2021
Section 8.2.3. A Pledge that does not support X.509 certificates
cannot use EST to enroll; it has to use another method for enrollment
without certificates and the Registrar has to support this method
also. It is possible that the Pledge will not enroll, but instead
only a network join operation will occur, such as described in
[I-D.ietf-6tisch-minimal-security]. How the Pledge discovers this
method and details of the enrollment method are out of scope of this
document.
When the Pledge is known by MASA to support PKIX format certificates,
the "pinned-domain-cert" field present in a voucher typically pins a
domain certificate. That can be either the End-Entity certificate of
the Registrar, or the certificate of a domain CA of the Registrar's
domain as specified in Section 7.2. However, if the Pledge is known
to also support RPK pinning and the MASA intends to pin the
Registrar's identity (not a CA), then MASA SHOULD pin the RPK (RPK3
in Figure 2) of the Registrar instead of the Registrar's End-Entity
certificate to save space in the voucher.
.------------.
| pub-CA (1) |
'------------'
|
v
.------------.
| sub-CA (2) |
'------------'
|
v
.--------------.
| Registrar(3) |
| RPK3 |
'--------------'
Figure 2: Raw Public Key pinning
8. Artifacts
This section describes for both the voucher request and the voucher
first the abstract (tree) definition as explained in
[I-D.ietf-netmod-yang-tree-diagrams]. This provides a high-level
view of the contents of each artifact.
Then the assigned SID values are presented. These have been assigned
using the rules in [I-D.ietf-core-sid].
8.1. Voucher Request artifact
Richardson, et al. Expires 26 January 2022 [Page 14]
Internet-Draft Constrained Voucher July 2021
8.1.1. Tree Diagram
The following diagram is largely a duplicate of the contents of
[RFC8366], with the addition of the fields proximity-registrar-pubk,
proximity-registrar-pubk-sha256, proximity-registrar-cert, and prior-
signed-voucher-request.
prior-signed-voucher-request is only used between the Registrar and
the MASA. proximity-registrar-pubk or proximity-registrar-pubk-sha256
optionally replaces proximity-registrar-cert for the most constrained
cases where RPK is used by the Pledge.
module: ietf-constrained-voucher-request
grouping voucher-request-constrained-grouping
+-- voucher
+-- created-on? yang:date-and-time
+-- expires-on? yang:date-and-time
+-- assertion enumeration
+-- serial-number string
+-- idevid-issuer? binary
+-- pinned-domain-cert? binary
+-- domain-cert-revocation-checks? boolean
+-- nonce? binary
+-- last-renewal-date? yang:date-and-time
+-- proximity-registrar-pubk? binary
+-- proximity-registrar-pubk-sha256? binary
+-- proximity-registrar-cert? binary
+-- prior-signed-voucher-request? binary
8.1.2. SID values
Richardson, et al. Expires 26 January 2022 [Page 15]
Internet-Draft Constrained Voucher July 2021
SID Assigned to
--------- --------------------------------------------------
2501 data /ietf-constrained-voucher-request:voucher
2502 data .../assertion
2503 data .../created-on
2504 data .../domain-cert-revocation-checks
2505 data .../expires-on
2506 data .../idevid-issuer
2507 data .../last-renewal-date
2508 data /ietf-constrained-voucher-request:voucher/nonce
2509 data .../pinned-domain-cert
2510 data .../prior-signed-voucher-request
2511 data .../proximity-registrar-cert
2513 data .../proximity-registrar-pubk
2512 data .../proximity-registrar-pubk-sha256
2514 data .../serial-number
WARNING, obsolete definitions
8.1.3. YANG Module
In the constrained-voucher-request YANG module, the voucher is
"augmented" within the "used" grouping statement such that one
continuous set of SID values is generated for the constrained-
voucher-request module name, all voucher attributes, and the
constrained-voucher-request attributes. Two attributes of the
voucher are "refined" to be optional.
<CODE BEGINS> file "[email protected]"
module ietf-constrained-voucher-request {
yang-version 1.1;
namespace
"urn:ietf:params:xml:ns:yang:ietf-constrained-voucher-request";
prefix "constrained";
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";
}
import ietf-voucher {
prefix "v";
}
Richardson, et al. Expires 26 January 2022 [Page 16]
Internet-Draft Constrained Voucher July 2021
organization
"IETF ANIMA Working Group";
contact
"WG Web: <http://tools.ietf.org/wg/anima/>
WG List: <mailto:[email protected]>
Author: Michael Richardson
<mailto:[email protected]>
Author: Peter van der Stok
<mailto: [email protected]>
Author: Panos Kampanakis
<mailto: [email protected]>";
description
"This module defines the format for a voucher request,
which is produced by a pledge to request a voucher.
The voucher-request is sent to the potential owner's
Registrar, which in turn sends the voucher request to
the manufacturer or its delegate (MASA).
A voucher is then returned to the pledge, binding the
pledge to the owner. This is a constrained version of the
voucher-request present in
{{I-D.ietf-anima-bootstrap-keyinfra}}
This version provides a very restricted subset appropriate
for very constrained devices.
In particular, it assumes that nonce-ful operation is
always required, that expiration dates are rather weak, as no
clocks can be assumed, and that the Registrar is identified
by either a pinned Raw Public Key of the Registrar, or by a
pinned X.509 certificate of the Registrar or domain CA.
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.";
revision "2021-04-15" {
description
"Initial version";
reference
"RFC XXXX: Voucher Profile for Constrained Devices";
}
rc:yang-data voucher-request-constrained-artifact {
// YANG data template for a voucher.
uses voucher-request-constrained-grouping;
Richardson, et al. Expires 26 January 2022 [Page 17]
Internet-Draft Constrained Voucher July 2021
}
// Grouping defined for future usage
grouping voucher-request-constrained-grouping {
description
"Grouping to allow reuse/extensions in future work.";
uses v:voucher-artifact-grouping {
refine voucher/created-on {
mandatory false;
}
refine voucher/pinned-domain-cert {
mandatory false;
}
augment "voucher" {
description "Base the constrained voucher-request upon the
regular one";
leaf proximity-registrar-pubk {
type binary;
description
"The proximity-registrar-pubk replaces
the proximity-registrar-cert in constrained uses of
the voucher-request.
The proximity-registrar-pubk is the
Raw Public Key of the Registrar. This field is encoded
as specified in RFC7250, section 3.
The ECDSA algorithm MUST be supported.
The EdDSA algorithm as specified in
draft-ietf-tls-rfc4492bis-17 SHOULD be supported.
Support for the DSA algorithm is not recommended.
Support for the RSA algorithm is a MAY, but due to
size is discouraged.";
}
leaf proximity-registrar-pubk-sha256 {
type binary;
description
"The proximity-registrar-pubk-sha256
is an alternative to both