-
Notifications
You must be signed in to change notification settings - Fork 0
/
draft-richardson-6tisch-minimal-rekey.txt
672 lines (459 loc) · 22.2 KB
/
draft-richardson-6tisch-minimal-rekey.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
6TiSCH Working Group M. Richardson
Internet-Draft Sandelman Software Works
Intended status: Standards Track August 23, 2017
Expires: February 24, 2018
Minimal Security rekeying mechanism for 6TiSCH
draft-richardson-6tisch-minimal-rekey-02
Abstract
This draft describes a mechanism to rekey the networks used by 6TISCH
nodes. It leverages the security association created during an
enrollment protocol. The rekey mechanism permits incremental
deployment of new sets of keys, followed by a rollover to a new key.
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 http://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 February 24, 2018.
Copyright Notice
Copyright (c) 2017 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
(http://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.
Richardson Expires February 24, 2018 [Page 1]
Internet-Draft 6tisch-minimal-rekey August 2017
Table of Contents
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2
2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 3
3. Tree diagram notation . . . . . . . . . . . . . . . . . . . . 3
4. An approach to rekeying . . . . . . . . . . . . . . . . . . . 3
5. YANG models . . . . . . . . . . . . . . . . . . . . . . . . . 4
5.1. Tree diagram . . . . . . . . . . . . . . . . . . . . . . 5
5.2. YANG model for keys . . . . . . . . . . . . . . . . . . . 5
5.3. YANG model for short-address . . . . . . . . . . . . . . 8
6. Security of CoMI link . . . . . . . . . . . . . . . . . . . . 9
7. Rekey of master connection . . . . . . . . . . . . . . . . . 10
8. Privacy Considerations . . . . . . . . . . . . . . . . . . . 10
9. Security Considerations . . . . . . . . . . . . . . . . . . . 10
10. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 10
11. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 11
12. References . . . . . . . . . . . . . . . . . . . . . . . . . 11
12.1. Normative References . . . . . . . . . . . . . . . . . . 11
12.2. Informative References . . . . . . . . . . . . . . . . . 11
Appendix A. Example . . . . . . . . . . . . . . . . . . . . . . 12
Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 12
1. Introduction
6TiSCH networks of nodes often use a pair of keys, K1/K2 to
authenticate beacons (K1), encrypt broadcast traffic (K1) and encrypt
unicast traffic (K2). These keys need to occasionally be refreshed
for a number of reasons:
o cryptographic hygiene: the keys must be replaced before the ASN
roles over or there could be repeated use of the same key.
o to remove nodes from the group: replacing the keys excludes any
nodes that are suspect, or which are known to have left the
network
o to recover short-addresses: if the JRC is running out of short
(2-byte) addresses, it can rekey the network in order to garbage
collect the set of addresses.
This protocol uses the CoMI [I-D.ietf-core-comi] to present the set
of 127 key pairs.
In addition to providing for rekey, this protocol includes access to
the allocated short-address.
Richardson Expires February 24, 2018 [Page 2]
Internet-Draft 6tisch-minimal-rekey August 2017
2. Terminology
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
document are to be interpreted as described in [RFC2119]. These
words may also appear in this document in lowercase, absent their
normative meanings.
The reader is expected to be familiar with the terms and concepts
defined in [I-D.ietf-6tisch-terminology], [RFC7252],
[I-D.ietf-core-object-security], and
[I-D.ietf-anima-bootstrapping-keyinfra].
3. Tree diagram notation
A simplified graphical representation of the data models is used in
this document. The meaning of the symbols in these diagrams is as
follows:
o Brackets "[" and "]" enclose list keys.
o Braces "{" and "}" enclose feature names, and indicate that the
named feature must be present for the subtree to be present.
o Abbreviations before data node names: "rw" (read-write) represents
configuration data and "ro" (read-only) represents state data.
o Symbols after data node names: "?" means an optional node, "!"
means a presence container, and "*" denotes a list and leaf-list.
o Parentheses enclose choice and case nodes, and case nodes are also
marked with a colon (":").
o Ellipsis ("...") stands for contents of subtrees that are not
shown.
4. An approach to rekeying
Rekeying of the network requires that all nodes be updated with the
new keys. This can take time as the network is constrained, and this
management traffic is not highest priority.
The JRC must reach out to all nodes that it is aware of. As the JRC
has originally provided the keys via either zero-touch
[I-D.ietf-6tisch-dtsecurity-secure-join] or
[I-D.ietf-6tisch-minimal-security] protocol, and in each case, the
JRC assigned the short-address to the node, so it knows about all the
nodes.
Richardson Expires February 24, 2018 [Page 3]
Internet-Draft 6tisch-minimal-rekey August 2017
The data model presented in this document provides for up to 127 K1/
K2 keys, as each key requires a secKeyId, which is allocated from a
255-element palette provides by [IEEE8021542015]. Keys are to be
updated in pairs, and the pairs are associated in the following way:
the K1 key is always the odd numbered key (1,3,5), and the K2 key is
the even numbered key that follows (2,4,6). A secKeyId value of 0 is
invalid, and the secKeyId value of 255 is unused in this process.
Nodes MAY support up to all 127 key pair slots, but MUST support a
minimum of 6 keys (3 slot-pairs). When fewer than 127 are supported,
the node MUST support secKeyId values from 1 to 254 in a sparse array
fashion.
A particular key slot-pair is considered active, and this model
provides a mechanism to query and also to explicitely set the active
pair.
Nodes decrypt any packets for which they have keys, but MUST continue
to send using only the keypair which is considered active. Receipt
of a packet which is encrypted (or authenticated in the case of a
broadcast) with a secKeyId larger (taking consideration that secKeyId
wraps at 254) than the active slot-pair causes the node to change
active slot pairs.
This mechanism permits the JRC to provision new keys into all the
nodes while the network continues to use the existing keys. When the
JRC is certain that all (or enough) nodes have been provisioned with
the new keys, then the JRC causes a packet to be sent using the new
key. This can be the JRC sending the next Enhanced Beacon or unicast
traffic using the new key if the JRC is also a regular member of the
LLN. In the likely case that the JRC has no direct connection to the
LLN, then the JRC updates the active key to the new key pair using a
CoMI message.
The frame goes out with the new keys, and upon receipt (and
decryption) of the new frame all receiving nodes will switch to the
new active key. Beacons or unicast traffic leaving those nodes will
then update additional peers, and the network will switch over in a
flood-fill fashion.
((EDNOTE: do we need an example?))
5. YANG models
Richardson Expires February 24, 2018 [Page 4]
Internet-Draft 6tisch-minimal-rekey August 2017
5.1. Tree diagram
A diagram of the two YANG modules looks like:
module: ietf-6tisch-symmetric-keying
+--rw ietf6tischkeypairs* [counter]
| +--rw counter uint16
| +--rw ietf6tischkey1
| | +--rw secKeyDescriptor
| | | +--rw secKey? binary
| | +--rw secKeyIndex? uint8
| +--rw ietf6tischkey2
| +--rw secKeyDescriptor
| | +--rw secKey? binary
| +--rw secKeyIndex? uint8
+--ro secKeyUsage
+--ro txPacketsSent? uint32
+--ro rxPacketsSuccess? uint32
+--ro rxPacketsReceived? uint32
module: ietf-6tisch-short-address
+--ro ietf6shortaddresses
+--ro shortaddress binary
+--ro validuntil uint32
+--ro effectiveat? uint32
Figure 1: Tree diagrams of two rekey modules
5.2. YANG model for keys
module ietf-6tisch-symmetric-keying {
yang-version 1.1;
namespace
"urn:ietf:params:xml:ns:yang:ietf-6tisch-symmetric-keying";
prefix "ietf6keys";
//import ietf-yang-types { prefix yang; }
//import ietf-inet-types { prefix inet; }
organization
"IETF 6tisch Working Group";
contact
"WG Web: <http://tools.ietf.org/wg/6tisch/>
WG List: <mailto:6tisch@ietf.org>
Author: Michael Richardson
Richardson Expires February 24, 2018 [Page 5]
Internet-Draft 6tisch-minimal-rekey August 2017
<mailto:mcr+ietf@sandelman.ca>";
description
"This module defines the format for a set of network-wide 802.15.4
keys used in 6tisch networks. There are 128 sets of key pairs,
with one keypair (K1) used to authenticate (and sometimes encrypt)
multicast traffic, and another keypair (K2) used to encrypt unicast
traffic. The 128 key pairs are numbered by the (lower) odd
keyindex, which otherwise is a 0-255 value. Keyindex 0 is
not valid. This module is a partial expression of the tables in
https://mentor.ieee.org/802.15/dcn/15/15-15-0106-07-0mag-security-section-pictures.pdf.
To read and write the key pairs, a monotonically increasing counter is added. A new key pair must be added with current_counter = last_counter+1. The current specification allows overwriting of earlier key pairs. It is up to the server to remove old key pairs, such that only the last three (two) pairs are stored and visible to the client.";
revision "2017-03-01" {
description
"Initial version";
reference
"RFC XXXX: 6tisch minimal security";
}
// list of key pairs
list ietf6tischkeypairs {
key counter;
description
"a list of key pairs with unique index: counter.";
leaf counter {
type uint16{
range "0..256"; // for the moment 256 items
}
mandatory "true";
description
"unique reference to the key pair for client access.";
} // counter
// key descriptor for FIRST part of pair
container ietf6tischkey1 {
description
"A voucher that can be used to assign one or more
devices to an owner.";
// this container is pretty empty, a leaf would do the job.
container secKeyDescriptor {
// I assume this needs to be extended, why else a container?
description
"This container describes the details of a
specific cipher key";
leaf secKey {
type binary;
Richardson Expires February 24, 2018 [Page 6]
Internet-Draft 6tisch-minimal-rekey August 2017
description "The actual encryption key.
This value is write only, and is not returned in a
read, or returns all zeroes.";
} // secKey
} // secKeyDescriptor
// leaf secKeyIdMode is always 1, not described here.
leaf secKeyIndex {
type uint8;
description
"The keyIndex for this keySet.
A number between 1 and 255.";
reference
"IEEE802.15.4";
} // secKeyIndex
} // ietf6tischkey1
// key descriptor for SECOND part of pair
container ietf6tischkey2 {
description
"A voucher that can be used to assign one or more
devices to an owner.";
container secKeyDescriptor {
// I assume this needs to be extended, why else a container?
description
"This container describes the details of a
specific cipher key";
leaf secKey {
type binary;
description "The actual encryption key.
This value is write only, and is not returned in a
read, or returns all zeroes.";
} // secKey
} // secKeyDescriptor
// leaf secKeyIdMode is always 1, not described here.
leaf secKeyIndex {
type uint8;
description
"The keyIndex for this keySet.
A number between 1 and 255.";
reference
"IEEE802.15.4";
} // secKeyIndex
} // ietf6tischkey2
} //ietf6tischkeypairs
// the usage is over all pairs
Richardson Expires February 24, 2018 [Page 7]
Internet-Draft 6tisch-minimal-rekey August 2017
container secKeyUsage {
config false; // cannot be set by client
description
"statistics of sent and received packets.";
leaf txPacketsSent {
type uint32;
description "Number of packets sent with this key.";
} // txPacketsSent
leaf rxPacketsSuccess {
type uint32;
description "Number of packets received with this key that were
successfully decrypted and authenticated.";
}// rxPacketsSuccess
leaf rxPacketsReceived {
type uint32;
description "Number of packets received with this key, both
successfully received, and unsuccessfully.";
} // rxPacketsReceived
} // secKeyUsage
} // module ietf-6tisch-symmetric-keying
5.3. YANG model for short-address
module ietf-6tisch-short-address {
yang-version 1.1;
namespace
"urn:ietf:params:xml:ns:yang:ietf-6tisch-short-address";
prefix "ietf6shortaddr";
//import ietf-yang-types { prefix yang; }
//import ietf-inet-types { prefix inet; }
organization
"IETF 6tisch Working Group";
contact
"WG Web: <http://tools.ietf.org/wg/6tisch/>
WG List: <mailto:6tisch@ietf.org>
Author: Michael Richardson
<mailto:mcr+ietf@sandelman.ca>";
description
"This module defines an interface to set and interrogate
the short (16-bit) layer-2 address used in 802.15.4
Richardson Expires February 24, 2018 [Page 8]
Internet-Draft 6tisch-minimal-rekey August 2017
TSCH mode networks. The short addresses are used
in L2 frames to save space. A lifetime is included
in terms of TSCH Absolute Slot Number, which acts
as a monotonically increasing clock. ";
revision "2017-03-01" {
description
"Initial version";
reference
"RFC XXXX: 6tisch minimal security";
}
// top-level container
container ietf6shortaddresses {
config false;
description
"A 16-bit short address for use by the node.";
leaf shortaddress {
type binary{
length 1..2;}
mandatory true;
description
"The two byte short address to be set.";
}
leaf validuntil {
type uint32;
mandatory true;
description "The Absolute Slot Number/256 at which
the address ceases to be valid.";
}
leaf effectiveat {
type uint32;
description "The Absolute Slot Number/256 at which
time the address was originally set.
This is a read-only attribute that
records the ASN when the shortaddress
element was last written or updated.";
}
}
}
6. Security of CoMI link
The CoMI resources presented here are protected by OSCOAP
([I-D.ietf-core-object-security]), secured using the EDHOC connection
used for joining. A unique application key is generated using an
Richardson Expires February 24, 2018 [Page 9]
Internet-Draft 6tisch-minimal-rekey August 2017
additional key generation process with the unique label "6tisch-
rekey".
7. Rekey of master connection
Should the OSCOAP connection need to be rekeyed, a new EDHOC process
will be necessary. This will need access to trusted authentication
keys, either the PSK used from a one-touch process, or the locally
significant domain certificates installed during a zero-touch
process.
8. Privacy Considerations
The rekey protocol itself runs over a network encrypted with the K2
key. The end to end protocol from JRC to node is also encrypted
using OSCOAP, so the keys are not visible, nor is the keying traffic
distinguished in anyway to an observer.
As the secKeyId is not confidential in the underlying 802.15.4
frames, an observer can determine what sets of keys are in use, and
when a rekey is activated by observing the change in the secKeyId.
The absolute value of the monitonically increasing secKeyId could
provide some information as to the age of the network.
9. Security Considerations
This protocol permits the underlying network keys to be set. Access
to all of the portions of this interface MUST be restricted to an
ultimately trusted peer, such as the JRC.
An implementation SHOULD not permit reading the network keys. Those
fields should be write-only.
The OSCOAP security for this interface is initialized by a join
mechanism, and so depends upon the initial credentials provided to
the node. The initial network keys would have been provided during
the join process; this protocol permits them to be updated.
10. IANA Considerations
This document allocates a SID number for the YANG model. There is no
IANA action required for this document.
Richardson Expires February 24, 2018 [Page 10]
Internet-Draft 6tisch-minimal-rekey August 2017
11. Acknowledgments
12. References
12.1. Normative References
[I-D.ietf-core-comi]
Veillette, M., Stok, P., Pelov, A., and A. Bierman, "CoAP
Management Interface", draft-ietf-core-comi-01 (work in
progress), July 2017.
[I-D.ietf-core-object-security]
Selander, G., Mattsson, J., Palombini, F., and L. Seitz,
"Object Security of CoAP (OSCOAP)", draft-ietf-core-
object-security-04 (work in progress), July 2017.
[I-D.ietf-cose-msg]
Schaad, J., "CBOR Object Signing and Encryption (COSE)",
draft-ietf-cose-msg-24 (work in progress), November 2016.
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
Requirement Levels", BCP 14, RFC 2119,
DOI 10.17487/RFC2119, March 1997, <https://www.rfc-
editor.org/info/rfc2119>.
[RFC7049] Bormann, C. and P. Hoffman, "Concise Binary Object
Representation (CBOR)", RFC 7049, DOI 10.17487/RFC7049,
October 2013, <https://www.rfc-editor.org/info/rfc7049>.
[RFC7252] Shelby, Z., Hartke, K., and C. Bormann, "The Constrained
Application Protocol (CoAP)", RFC 7252,
DOI 10.17487/RFC7252, June 2014, <https://www.rfc-
editor.org/info/rfc7252>.
12.2. Informative References
[I-D.ietf-6tisch-6top-protocol]
Wang, Q., Vilajosana, X., and T. Watteyne, "6top Protocol
(6P)", draft-ietf-6tisch-6top-protocol-07 (work in
progress), June 2017.
[I-D.ietf-6tisch-dtsecurity-secure-join]
Richardson, M., "6tisch Secure Join protocol", draft-ietf-
6tisch-dtsecurity-secure-join-01 (work in progress),
February 2017.
Richardson Expires February 24, 2018 [Page 11]
Internet-Draft 6tisch-minimal-rekey August 2017
[I-D.ietf-6tisch-minimal-security]
Vucinic, M., Simon, J., Pister, K., and M. Richardson,
"Minimal Security Framework for 6TiSCH", draft-ietf-
6tisch-minimal-security-03 (work in progress), June 2017.
[I-D.ietf-6tisch-terminology]
Palattella, M., Thubert, P., Watteyne, T., and Q. Wang,
"Terminology in IPv6 over the TSCH mode of IEEE
802.15.4e", draft-ietf-6tisch-terminology-09 (work in
progress), June 2017.
[I-D.ietf-anima-bootstrapping-keyinfra]
Pritikin, M., Richardson, M., Behringer, M., Bjarnason,
S., and K. Watsen, "Bootstrapping Remote Secure Key
Infrastructures (BRSKI)", draft-ietf-anima-bootstrapping-
keyinfra-07 (work in progress), July 2017.
[IEEE8021542015]
IEEE standard for Information Technology, ., "IEEE Std
802.15.4-2015 Standard for Low-Rate Wireless Personal Area
Networks (WPANs)", 2015.
Appendix A. Example
Example COMI requests/responses.
Author's Address
Michael Richardson
Sandelman Software Works
Email: mcr+ietf@sandelman.ca
Richardson Expires February 24, 2018 [Page 12]