forked from fgont/ipv6-ehs-packet-drops
-
Notifications
You must be signed in to change notification settings - Fork 0
/
draft-ietf-v6ops-ipv6-ehs-packet-drops-03.xml
898 lines (695 loc) · 45.7 KB
/
draft-ietf-v6ops-ipv6-ehs-packet-drops-03.xml
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
<?xml version="1.0" encoding="US-ASCII"?>
<!DOCTYPE rfc SYSTEM "rfc2629.dtd">
<?xml-stylesheet type="text/xsl" href="rfc2629.xslt" ?>
<?rfc toc="yes" ?>
<?rfc toc="yes"?>
<?rfc tocompact="yes"?>
<?rfc tocdepth="2"?>
<?rfc symrefs="yes" ?>
<?rfc sortrefs="yes"?>
<?rfc strict="no" ?>
<rfc
ipr="trust200902"
category="info"
docName="draft-ietf-v6ops-ipv6-ehs-packet-drops-03">
<front>
<title abbrev="IPv6 Extension Headers">Operational Implications of IPv6 Packets with Extension Headers</title>
<author fullname="Fernando Gont" initials="F." surname="Gont">
<organization abbrev="SI6 Networks">SI6 Networks</organization>
<address>
<postal>
<street>Segurola y Habana 4310, 7mo Piso</street>
<!-- <code>1706</code> -->
<city>Villa Devoto</city>
<region>Ciudad Autonoma de Buenos Aires</region>
<country>Argentina</country>
</postal>
<!-- <phone>+54 11 4650 8472</phone> -->
<email>[email protected]</email>
<uri>https://www.si6networks.com</uri>
</address>
</author>
<author fullname="Nick Hilliard" initials="N" surname="Hilliard">
<organization>INEX</organization>
<address>
<postal>
<street>4027 Kingswood Road</street>
<city>Dublin</city>
<code>24</code>
<country>IE</country>
</postal>
<email>[email protected]</email>
</address>
</author>
<author fullname="Gert Doering" initials="G" surname="Doering">
<organization>SpaceNet AG</organization>
<address>
<postal>
<street>Joseph-Dollinger-Bogen 14</street>
<city>Muenchen</city>
<code>D-80807</code>
<country>Germany</country>
</postal>
<email>[email protected]</email>
</address>
</author>
<author fullname="Warren Kumari" initials="W." surname="Kumari">
<organization>Google</organization>
<address>
<postal>
<street>1600 Amphitheatre Parkway</street>
<city>Mountain View, CA</city>
<code>94043</code>
<country>US</country>
</postal>
<email>[email protected]</email>
</address>
</author>
<author fullname="Geoff Huston" initials="G." surname="Huston">
<organization abbrev="APNIC"/>
<address>
<email>[email protected]</email>
<uri>http://www.apnic.net</uri>
</address>
</author>
<author fullname="Will (Shucheng) Liu" initials="W." surname="Liu">
<organization>Huawei Technologies</organization>
<address>
<postal>
<street>Bantian, Longgang District</street>
<city>Shenzhen</city>
<code>518129</code>
<country>P.R. China</country>
</postal>
<email>[email protected]</email>
</address>
</author>
<date/>
<area>Operations and Management</area>
<workgroup>IPv6 Operations Working Group (v6ops)</workgroup>
<abstract>
<t>
This document summarizes the operational implications of IPv6 extension headers specified in the IPv6 protocol specification (RFC8200), and attempts to analyze reasons why packets with IPv6 extension headers are often dropped in the public Internet.
</t>
</abstract>
</front>
<middle>
<section title="Introduction" anchor="intro">
<t>
IPv6 Extension Headers (EHs) allow for the extension of the IPv6 protocol, and provide support for core functionality such as IPv6 fragmentation. However, common implementation limitations suggest that EHs present a challenge for IPv6 packet routing equipment and middle-boxes, and evidence exists that IPv6 packets with EHs are intentionally dropped in the public Internet in some network deployments.
</t>
<!--
<t>Discussions about the security and operational implications of IPv6 extension headers are a regular feature in IETF working groups and other places. Often in these discussions, important security and operational issues are overlooked.</t>
<t>The authors of this document have been involved in numerous discussions about IPv6 extension headers (both within the IETF and in other fora), and have noticed that the security and operational implications associated with IPv6 EHs were unknown to the larger audience participating in these discussions.
</t>
-->
<t>This document has the following goals:
<list style="symbols">
<t>Raise awareness about the operational and security implications of IPv6 Extension Headers specified in <xref target="RFC8200"/>, and present reasons why some networks resort to intentionally dropping packets containing IPv6 Extension Headers.</t>
<t>Highlight areas where current IPv6 support by networking devices maybe sub-optimal, such that the aforementioned support is improved.</t>
<t>Highlight operational issues associated with IPv6 extension headers, such that those issues are considered in IETF standardization efforts.</t>
</list>
</t>
<t>
<xref target="background"/> provides background information about the IPv6 packet structure and associated implications. <xref target="previous-work"/> of this document summarizes the previous work that has been carried out in the area of IPv6 extension headers. <xref target="pfe-constraints"/> discusses packet forwarding engine constraints in contemporary routers. <xref target="inability"/> discusses why contemporary routers and middle-boxes may need to access Layer-4 information to make a forwarding decision. Finally, <xref target="operational-implications"/> discusses the operational implications of IPv6 EHs. <!--Finally, <xref target="future-work"/> suggests a possible action plan for improving the state of affairs with respect to IPv6 extension headers. -->
</t>
</section>
<section title="Disclaimer" anchor="disclaimer">
<t>This document analyzes the operational challenges represented by packets that employ IPv6 Extension Headers, and documents some of the operational reasons why these packets are often dropped in the public Internet. This document is not a recommendation to drop such packets, but rather an analysis of why they are dropped.
</t>
</section>
<section title="Background Information" anchor="background">
<t>
It is useful to compare the basic structure of IPv6 packets against that of IPv4 packets, and analyze the implications of the two different packet structures.
</t>
<t>
IPv4 packets have a variable-length header size, that allows for the
use of IPv4 "options" -- optional information that may be of use by
nodes processing IPv4 packets. The IPv4 header length is specified
in the IHL header field of the mandatory IPv4 header, and must be in
the range from 20 octets (the minimum IPv4 header size) to 60 octets
(accommodating at most 40 octets of options). The upper-layer protocol type is specified via the "Protocol" field of the mandatory IPv4 header.
</t>
<t>
<figure title="IPv4 Packet Structure" anchor="ipv4-packet"><artwork><![CDATA[
Protocol, IHL
+--------+
| |
| v
+------//-----+------------------------+
| | |
| IPv4 | Upper-Layer |
| Header | Protocol |
| | |
+-----//------+------------------------+
variable length
<------------->
]]></artwork></figure>
</t>
<t>
IPv6 took a different approach to the IPv6 packet structure. Rather than employing a variable-length header as IPv4 does, IPv6 employs a linked-list-like packet structure, where a mandatory fixed-length IPv6 header is followed by an arbitrary number of optional extension headers, with the upper-layer header being the last header in the IPv6 header chain. Each extension header typically specifies its length (unless it is implicit from the extension header type), and the "next header" type that follows in the IPv6 IPv6 header chain.
</t>
<t>
<figure title="IPv6 Packet Structure" anchor="ipv6-packet"><artwork><![CDATA[
NH NH, EH-length NH, EH-length
+-------+ +------+ +-------+
| | | | | |
| v | v | v
+-------------+-------------+-//-+---------------+--------------+
| | | | | |
| IPv6 | Ext. | | Ext. | Upper-Layer |
| header | Header | | Header | Protocol |
| | | | | |
+-------------+-------------+-//-+---------------+--------------+
fixed length variable number of EHs & length
<------------> <-------------------------------->
]]></artwork></figure>
</t>
<t>This packet structure has the following implications:
<list style="symbols">
<t><xref target="RFC8200"/> requires the entire IPv6 header chain to be contained in the first fragment of a packet, therefore limiting the IPv6 extension header chain to the size of the path MTU.
</t>
<t>Other than the path MTU constraints, there are no other limits to the number of IPv6 EHs that may be present in a packet. Therefore, there is no upper-limit regarding "how deep into the IPv6 packet" the upper-layer may be found.
</t>
<t>The only way for a node to obtain the upper-layer protocol
type or find the upper-layer protocol header is to parse and
process the entire IPv6 header chain, in sequence, starting from
the mandatory IPv6 header, until the last header in the IPv6
header chain is found.
</t>
</list>
</t>
</section>
<section title="Previous Work on IPv6 Extension Headers" anchor="previous-work">
<t>Some of the operational implications of IPv6 Extension Headers have been discussed at the IETF:
<list style="symbols">
<t><xref target="I-D.taylor-v6ops-fragdrop"/> discusses a rationale for which operators drop IPv6 fragments.</t>
<t> <xref target="I-D.wkumari-long-headers"/> discusses possible issues arising from "long" IPv6 header chains.</t>
<t><xref target="I-D.kampanakis-6man-ipv6-eh-parsing"/> describes how inconsistencies in the way IPv6 packets with extension headers are parsed by different implementations could result in evasion of security controls, and presents guidelines for parsing IPv6 extension headers with the goal of providing a common and consistent parsing methodology for IPv6 implementations.
</t>
<t><xref target="I-D.ietf-opsec-ipv6-eh-filtering"/> analyzes the security implications of IPv6 EHs, and the operational implications of dropping packets that employ IPv6 EHs and associated options.
</t>
<t><xref target="RFC7113"/> discusses how some popular RA-Guard implementations are subject to evasion by means of IPv6 extension headers.</t>
<t><xref target="RFC8900"/> analyzes the fragility introduced by IP fragmentation.</t>
</list>
</t>
<t>A number of recent RFCs have discussed issues related to IPv6 extension headers, specifying updates to a previous revision of the IPv6 standard (<xref target="RFC2460"/>), many of which have now been incorporated into the current IPv6 core standard (<xref target="RFC8200"/>) or the IPv6 Node Requirements (<xref target="RFC8504"/>). Namely,
<list style="symbols">
<t><xref target="RFC5095"/> discusses the security implications of Routing Header Type 0 (RTH0), and deprecates it.</t>
<t><xref target="RFC5722"/> analyzes the security implications of overlapping fragments, and provides recommendations in this area.</t>
<t><xref target="RFC7045"/> clarifies how intermediate nodes should deal with IPv6 extension headers.</t>
<t><xref target="RFC7112"/> discusses the issues arising in a specific fragmentation case where the IPv6 header chain is fragmented into two or more fragments (and formally forbids such fragmentation case).</t>
<t><xref target="RFC6946"/> discusses a flawed (but common) processing of the so-called IPv6 "atomic fragments", and specified improved processing of such packets.</t>
<t><xref target="RFC8021"/> deprecates the generation of IPv6 atomic fragments.</t>
<t><xref target="RFC8504"/> clarifies processing rules for packets with extension headers, and also allows hosts to enforce limits on the number of options included in IPv6 EHs.</t>
<t><xref target="RFC7739"/> discusses the security implications of predictable fragment Identification values, and provides recommendations for the generation of these values.</t>
<t><xref target="RFC6980"/> analyzes the security implications of employing IPv6 fragmentation with Neighbor Discovery for IPv6, and formally recommends against such usage.</t>
</list>
</t>
<t>Additionally, <xref target="RFC8200"/> has relaxed the requirement that "all nodes examine and process the Hop-by-Hop Options header" from <xref target="RFC2460"/>, by specifying that only nodes that have been explicitly configured to process the Hop-by-Hop Options header are required to do so.</t>
<t>A number of studies have measured the extent to which packets employing IPv6 extension headers are dropped in the public Internet:
<list style="symbols">
<t><xref target="PMTUD-Blackholes"/><!--, <xref target="Gont-IEPG88"/>, <xref target="Gont-Chown-IEPG89"/>,--> and <xref target="Linkova-Gont-IEPG90"/> presented some preliminary measurements regarding the extent to which packet containing IPv6 EHs are dropped in the public Internet.</t>
<t><xref target="RFC7872"/> presents more comprehensive results and documents the methodology used to obtain these results.</t>
<t><xref target="Huston-2017"/> and <xref target="Huston-2020"/> measured packet drops resulting from IPv6 fragmentation when communicating with DNS servers.</t>
</list>
</t>
</section>
<section title="Packet Forwarding Engine Constraints" anchor="pfe-constraints">
<t>
Most contemporary routers use dedicated hardware (e.g. ASICs or NPUs) to
determine how to forward packets across their internal fabrics (see <xref target="IEPG94-Scudder"/> and <xref target="APNIC-Scudder"/> for details). One of the
common methods of handling next-hop lookup is to send a small portion of the
ingress packet to a lookup engine with specialised hardware (e.g. ternary
CAM or RLDRAM) to determine the packet's next-hop. Technical constraints
mean that there is a trade-off between the amount of data sent to the lookup
engine and the overall performance of the lookup engine. If more data is
sent, the lookup engine can inspect further into the packet, but the overall
performance of the system will be reduced. If less data is sent, the
overall performance of the router will be increased but the packet lookup
engine may not be able to inspect far enough into a packet to determine how
it should be handled.
</t>
<t>
<list style="hanging">
<!-- [fgont] This note was flagged as "FIX ME" -->
<t hangText="NOTE:"><vspace blankLines="0"/>For example, contemporary high-end
routers can use up to 192 bytes
of header (Cisco ASR9000 Typhoon) or 384 bytes of header (Juniper MX Trio).
</t>
</list>
</t>
<t> If a hardware forwarding engine on a contemporary router cannot make a
forwarding decision about a packet because critical information is not sent
to the look-up engine, then the router will normally drop the packet.
<list style="hanging">
<!-- [fgont] This note was flagged as "FIX ME" -->
<t hangText="NOTE:"><vspace blankLines="0"/><xref target="inability"/> discusses some of the reasons for which a contemporary router might need to access layer-4 information to make a forwarding decision.</t>
</list>
Historically, some packet forwarding engines punted packets of this form to
the control plane for more in-depth analysis, but this is unfeasible on most
contemporary router architectures as a result of the vast difference between the hardware
forwarding capacity of the router and processing capacity of the control plane and the size of the management link which
connects the control plane to the forwarding plane. </t>
<t>
If an IPv6 header chain is sufficiently long that it exceeds the
packet look-up capacity of the router, the router could resort to dropping the packet, as a result of being unable to determine how the packet should be handled.
</t>
<section title="Recirculation" anchor="recirculation">
<t>
Although TLV chains are amenable to iterative processing on architectures
that have packet look-up engines with deep inspection capabilities, some
packet forwarding engines manage IPv6 Extension Header chains using
recirculation. This approach processes Extension Headers one at a time:
when processing on one Extension Header is completed, the packet is looped
back through the processing engine again. This recirculation process
continues repeatedly until there are no more Extension Headers left to be
processed.
</t>
<t>
Recirculation is typically used on packet forwarding engines with limited
look-up capability, because it allows arbitrarily long header chains to be
processed without the complexity and cost associated with packet forwarding
engines which have deep look-up capabilities. However, recirculation can
impact the forwarding capacity of hardware, as each packet will pass through
the processing engine multiple times. Depending on configuration, the type
of packets being processed, and the hardware capabilities of the packet
forwarding engine, this could impact data-plane throughput performance on the
router.
</t>
</section>
</section>
<section title="Requirement to Process Layer-3/layer-4 information in Intermediate Systems" anchor="inability">
<t>The following subsections discuss some of the reasons for which contemporary routers and middle-boxes may need to process Layer-3/layer-4 information to make a forwarding decision.</t>
<section title="ECMP and Hash-based Load-Sharing" anchor="ecmp-load-balancing">
<t>In the case of ECMP (equal cost multi path) load sharing, the router on
the sending side of the link needs to make a decision regarding which of the links to
use for a given packet. Since round-robin usage of the links is usually
avoided to prevent packet reordering, forwarding engines need to
use a mechanism that will consistently forward the same data streams down
the same forwarding paths. Most forwarding engines achieve this by
calculating a simple hash using an n-tuple gleaned from a combination of
layer-2 through to layer-4 packet header information. This n-tuple will
typically use the src/dst MAC address, src/dst IP address, and if possible
further layer-4 src/dst port information.
</t>
<t>In the IPv6 world, flows are expected to be identified by means of the IPv6 Flow Label <xref target="RFC6437"/>. Thus, ECMP and Hash-based Load-Sharing should be possible without the need to process the entire IPv6 header chain to obtain upper-layer information to identify flows. Historically, many IPv6 implementations failed to set the Flow Label, and ECMP / hash-based load-sharing devices also did not employ the Flow Label for performing their task. Clearly, widespread support of <xref target="RFC6437"/> would relieve middle-boxes from having to process the entire IPv6 header chain, making Flow Label-based ECMP and Hash-based Load-Sharing <xref target="RFC6438"/> feasible.</t>
<t>While support of <xref target="RFC6437"/> is currently widespread for current versions of all popular host implementations, there is still only marginal usage of the IPv6 Flow Label for ECMP and load balancing <xref target="Cunha-2020"/>. A contributing factor could be the issues that have been found in host implementations and middle-boxes <xref target="Jaeggli-2018"/>.</t>
</section>
<section title="Enforcing infrastructure ACLs" anchor="enforcing-infrastructure-acls">
<t>Infrastructure ACLs (iACLs) drop unwanted packets destined
to a network's infrastructure IP addresses. Typically, iACLs are deployed because external direct access to a network's infrastructure addresses is operationally unnecessary, and can be used for attacks of different sorts against router
control planes. To this end, traffic usually needs to be differentiated on the basis of layer-3
or layer-4 criteria to achieve a useful balance of protection and functionality. For example, an infrastructure may be configured with the following policy:
<list style="symbols">
<t>Permit some amount of ICMP echo (ping) traffic towards a router's
addresses for troubleshooting.</t>
<t>Permit BGP sessions on the shared network of an exchange point (potentially differentiating between the amount of packets/seconds permitted for established sessions and connection establishment), but do not permit other traffic from the same peer IP addresses.</t>
</list>
</t>
</section>
<section title="DDoS Management and Customer Requests for Filtering" anchor="ddos-management">
<t>The case of customer DDoS protection and edge-to-core customer protection
filters is similar in nature to the iACL protection. Similar
to iACL protection, layer-4 ACLs generally need to be applied as close to the
edge of the network as possible, even though the intent is usually to protect the
customer edge rather than the provider core. Application of layer-4 DDoS protection
to a network edge is often automated using Flowspec <xref target="RFC5575"/>.
</t>
<t>For example, a web site that normally only handled traffic on TCP ports
80 and 443 could be subject to a volumetric DDoS attack using NTP and DNS
packets with randomised source IP address, thereby rendering
traditional <xref target="RFC5635"/> source-based real-time black hole
mechanisms useless. In this situation, DDoS protection ACLs could be configured to
block all UDP traffic at the network edge without impairing the web server
functionality in any way. Thus, being able to block arbitrary
protocols at the network edge can avoid DDoS-related problems both in the provider
network and on the customer edge link.
</t>
</section>
<section title="Network Intrusion Detection and Prevention" anchor="nids">
<t>Network Intrusion Detection Systems (NIDS) examine network traffic and try to identify traffic patterns that can be correlated to network-based attacks. These systems generally inspect application-layer traffic (if possible), but at the bare minimum inspect layer-4 flows. When attack activity is inferred, the operator is notified of the potential intrusion attempt.
</t>
<t>Network Intrusion Prevention Systems (IPS) operate similarly to NIDS's, but they can also prevent intrusions by reacting to detected attack attempts by e.g., triggering packet filtering policies at firewalls and other devices.</t>
<t>Use of extension headers can be problematic for NIDS/IPS, since:
<list style="symbols">
<t>Extension headers increase the complexity of resulting traffic, and the associated work and system requirements to process it.</t>
<t>Use of unknown extension headers can prevent an NIDS/IPS from processing layer-4 information</t>
<t>Use of IPv6 fragmentation requires a stateful fragment-reassembly operation, even for decoy traffic employing forged source addresses (see e.g. <xref target="nmap"/>).</t>
</list>
</t>
<t>As a result, in order to increase the efficiency or effectiveness of these systems, packets employing IPv6 extension headers are often dropped at the network ingress point(s) of networks that deploy these systems.</t>
</section>
<section title="Firewalling" anchor="firewalls">
<t>Firewalls enforce security policies by means of packet filtering. These systems usually inspect layer-3 and layer-4 traffic, but can often also examine application-layer traffic flows.</t>
<t>As with NIDS/IPS (<xref target="nids"/>), use of IPv6 extension headers can represent a challenge to network firewalls, since:
<list style="symbols">
<t>Extension headers increase the complexity of resulting traffic, and the associated work and system requirements to process it (see e.g. <xref target="Zack-FW-Benchmark"/>).</t>
<t>Use of unknown extension headers can prevent firewalls from processing layer-4 information.</t>
<t>Use of IPv6 fragmentation requires a stateful fragment-reassembly operation, even for decoy traffic employing forged source addresses (see e.g. <xref target="nmap"/>).</t>
</list>
</t>
<t>Additionally, a common firewall filtering policy is the so-called "default deny", where all traffic is blocked (by default), and only expected traffic is added to an "allow/accept list".</t>
<t>As a result, whether because of the challenges represented by extension headers or because the use of IPv6 extension headers has not been explicitly allowed, packets employing IPv6 extension headers are often dropped by network firewalls.</t>
</section>
</section>
<section title="Operational Implications" anchor="operational-implications">
<!--
[fgont] Isn't this already discussed in the "ddos-management" section?
<t>FIXME: Implementation of edge-to-core customer sanitisation filters</t>
-->
<section title="Inability to Find Layer-4 Information" anchor="inability-layer-4-info">
<t>As discussed in <xref target="inability"/>, routers and middle-boxes that need to find the layer-4 header must process the entire IPv6 extension header chain. When such devices are unable to obtain the required information, the forwarding device has the option to drop the packet unconditionally, forward the packet unconditionally, or process the packet outside the normal forwarding path. Forwarding packets unconditionally will usually allow for the circumvention of security controls (see e.g. <xref target="firewalls"/>), while processing packets outside of the normal forwarding path will usually open the door to DoS attacks (see e.g. <xref target="pfe-constraints"/>). Thus, in these scenarios, devices often simply resort to dropping such packets unconditionally.
</t>
</section>
<section title="Route-Processor Protection" anchor="route-processor-protection">
<t>Most contemporary routers have a fast hardware-assisted forwarding plane
and a loosely coupled control plane, connected together with a link that
has much less capacity than the forwarding plane could handle. Traffic
differentiation cannot be performed by the control plane, because this would
overload the internal link connecting the forwarding plane to the control
plane.
</t>
<t>The Hop-by-Hop Options header has been particularly challenging since in most circumstances, the corresponding packet is punted to the control plane for processing. As a result, operators usually drop IPv6 packets containing this extension header. <xref target="RFC6192"/> provides advice regarding protection of a router's control plane.</t>
</section>
<section title="Inability to Perform Fine-grained Filtering" anchor="finer-grained">
<t>Some router implementations do not have support for fine-grained filtering of IPv6 extension headers. For example, an operator that wishes to drop packets containing Routing Header Type 0 (RHT0), may only be able to filter on the extension header type (Routing Header). This could result in an operator enforcing a more coarse filtering policy (e.g. "drop all packets containing a Routing Header" vs. "only drop packets that contain a Routing Header Type 0").
</t>
<!--
<t>Some router implementations lack fine-grained filtering of IPv6 extension headers. For example, an operator may want to drop packets containing Routing Header Type 0 (RHT0) but may only be able to filter on the extension header type (Routing Header). As a result, the operator may end up enforcing a more coarse filtering policy (e.g. "drop all packets containing a Routing Header" vs. "only drop packets that contain a Routing Header Type 0").
</t>
-->
</section>
<section title="Security Concerns Associated with IPv6 Extension Headers" anchor="security-implications">
<t>The security implications of IPv6 Extension Headers generally fall into one or more of these categories:
<list style="symbols">
<t>Evasion of security controls</t>
<t>DoS due to processing requirements</t>
<t>DoS due to implementation errors</t>
<t>Extension Header-specific issues</t>
</list>
</t>
<!-- IPv4 packets that contain limited space for IPv4 options and an "Internet Header Length" (IHL) field where the upper-layer protocols c -->
<t>Unlike IPv4 packets where the upper-layer protocol can be trivially found by means of the "IHL" ("Internet Header Length") IPv4 header field, the structure of IPv6 packets is more flexible and complex. This can represent a challenge for devices that need to find this information, since locating upper-layer protocol information requires that all IPv6 extension headers be examined. In turn, this presents implementation difficulties, since some packet filtering mechanisms that require upper-layer information (even if just the upper layer protocol type) can be trivially circumvented by inserting IPv6 Extension Headers between the main IPv6 header and the upper layer protocol. <xref target="RFC7113"/> describes this issue for the RA-Guard case, but the same techniques could be employed to circumvent other IPv6 firewall and packet filtering mechanisms. Additionally, implementation inconsistencies in packet forwarding engines can result in evasion of security controls <xref target="I-D.kampanakis-6man-ipv6-eh-parsing"/> <xref target="Atlasis2014"/> <xref target="BH-EU-2014"/>.
</t>
<t>Sometimes packets with IPv6 Extension Headers can impact throughput performance on routers and middleboxes. Unless appropriate mitigations are put in place (e.g., packet dropping and/or rate-limiting), an attacker could simply send a large amount of IPv6 traffic employing IPv6 Extension Headers with the purpose of performing a Denial of Service (DoS) attack (see <xref target="operational-implications"/> for further details).
<list style="hanging">
<t hangText="NOTE:"><vspace blankLines="0"/>In the most trivial case, a packet that includes a Hop-by-Hop Options header might go through the slow forwarding path, to be processed by the router's CPU. Alternatively, a router configured to enforce an ACL based on upper-layer information (e.g., upper layer protocol or TCP Destination Port) may need to process the entire IPv6 header chain in order to find the required information, thereby causing the packet to be processed in the slow path <xref target="Cisco-EH-Cons"/>. We note that, for obvious reasons, the aforementioned performance issues can affect other devices such as firewalls, Network Intrusion Detection Systems (NIDS), etc. <xref target="Zack-FW-Benchmark"/>. The extent to which performance is affected on these devices is implementation-dependent.
</t>
</list>
</t>
<t>IPv6 implementations, like all other software, tend to mature with time and wide-scale deployment. While the IPv6 protocol itself has existed for over 20 years, serious bugs related to IPv6 Extension Header processing continue to be discovered (see e.g. <xref target="Cisco-Frag1"/>, <xref target="Cisco-Frag2"/>, and <xref target="FreeBSD-SA"/>). Because there is currently little operational reliance on IPv6 Extension headers, the corresponding code paths are rarely exercised, and there is the potential for bugs that still remain to be discovered in some implementations.</t>
<t>IPv6 Fragment Headers are employed to allow fragmentation of IPv6 packets. While many of the security implications of the fragmentation / reassembly mechanism are known from the IPv4 world, several related issues have crept into IPv6 implementations. These range from denial of service attacks to information leakage, as discussed in <xref target="RFC7739"/>, <xref target="Bonica-NANOG58"/> and <xref target="Atlasis2012"/>).
</t>
</section>
</section>
<!--
<section title="Conclusions" anchor="conclusions">
<t>This document suggests that, in a number of scenarios that involve packets that must traverse the public Internet, operators may resort to dropping IPv6 packets that contain IPv6 extension headers. Thus, in such scenarios, the use of IPv6 extension headers may lead to packet drops and introduce network unreliability. Previous research, such as that referenced in <xref target="previous-work"/> of this document, seems to back this assessment.</t>
<t>On the other hand, we note that in scenarios where the user or operator has control over all the involved network elements (as in the "limited domains" concept defined in <xref target="RFC8799"/>), use of IPv6 extension headers need not result in packet drops and associated network unreliability.</t>
</section>
-->
<!--
<section title="Performance Implications" anchor="performance-implications">
<t>FIXME: Some IPv6 router implementations suffer from a negative performance impact when IPv6 Extension Headers are employed.</t>
<t>In the most trivial case, a packet that includes a Hop-by-Hop Options header will typically go through the slow forwarding path, and be processed by the router's CPU. Another case is that in which a router that has been configured to enforce an ACL based on upper-layer information (e.g., upper layer protocol or TCP Destination Port). In such case, the router will need to process the entire IPv6 header chain in order to find the required information, and this may cause the packet to be processed in the slow path <xref target="Cisco-EH-Cons"/>.</t>
<t>Processing a large amounts of traffic in the slow path may cause the router to be unable to handle the same traffic loads when compared to normal packets, and may result in Denial of Service (DoS) scenarios.</t>
<t>We note that, for obvious reasons, the aforementioned performance issues may also affect other devices such as firewalls, Network Intrusion Detection Systems (NIDS), etc. <xref target="Zack-FW-Benchmark"/>.</t>
</section>
-->
<!--
<section title="Possible Future Work" anchor="future-work">
<t>Based on the discussion provided in this document, we note that the following (*non*-mutually exclusive) actions might help to improve the state of affairs of IPv6 extension headers:
<list style="symbols">
<t>Providing support for better granularity in the specification of filters for IPv6 extension headers, such that filters for specific EH types and subtypes (e.g. RHT0 vs. RHT2) can be specified without affecting other extension header types/subtypes unnecessarily (please see <xref target="finer-grained"/>).</t>
<t>Providing advice on the filtering of IPv6 packets that contain IPv6 extension headers (as in <xref target="I-D.ietf-opsec-ipv6-eh-filtering"/>).</t>
<t>Enforcing a cap on the maximum length of an IPv6 EH chain (e.g., as proposed in <xref target="I-D.wkumari-long-headers"/>) should be evaluated. If not at the protocol specification level (i.e., "Standards Track"), such a cap could be recommended as operational advice of the form "IPv6 implementations are expected to support EH chains as long as the they fit in the path MTU for the corresponding packets (see <xref target="RFC7112"/>).
</t>
</list>
</t>
</section>
-->
<section title="IANA Considerations" anchor="iana-cons">
<t>There are no IANA registries within this document. The RFC-Editor can remove this section before publication of this document as an RFC.
</t>
</section>
<section title="Security Considerations">
<t>The security implications of IPv6 extension headers are discussed in <xref target="security-implications"/>. This document does not introduce any new security issues.
</t>
</section>
<section title="Acknowledgements">
<t>The authors would like to thank (in alphabetical order) Mikael Abrahamsson, Fred Baker, Dale W. Carder, Brian Carpenter, Tim Chown, Owen DeLong, Gorry Fairhurst, Tom Herbert, Lee Howard, Tom Petch, Sander Steffann, Eduard Vasilenko, Eric Vyncke, Jingrong Xie, and Andrew Yourtchenko, for providing valuable comments on earlier versions of this document. </t>
<t>Fernando Gont would like to thank Jan Zorz / Go6 Lab <https://go6lab.si/>, Jared Mauch, and Sander Steffann <https://steffann.nl/>, for providing access to systems and networks that were employed to perform experiments and measurements involving packets with IPv6 Extension Headers.</t>
</section>
</middle>
<back>
<references title='Normative References'>
<?rfc include="reference.RFC.6946" ?>
<?rfc include="reference.RFC.5095" ?>
<?rfc include="reference.RFC.5722" ?>
<?rfc include="reference.RFC.7112" ?>
<?rfc include="reference.RFC.8021" ?>
<?rfc include="reference.RFC.8200" ?>
<?rfc include="reference.RFC.8504" ?>
<?rfc include="reference.RFC.6980" ?>
</references>
<references title='Informative References'>
<?rfc include="reference.RFC.2460" ?>
<?rfc include="reference.RFC.5575" ?>
<?rfc include="reference.RFC.5635" ?>
<?rfc include="reference.RFC.6192" ?>
<?rfc include="reference.RFC.6437" ?>
<?rfc include="reference.RFC.6438" ?>
<?rfc include="reference.RFC.7045" ?>
<?rfc include="reference.RFC.7113" ?>
<?rfc include="reference.I-D.taylor-v6ops-fragdrop" ?>
<?rfc include="reference.I-D.wkumari-long-headers" ?>
<?rfc include="reference.I-D.kampanakis-6man-ipv6-eh-parsing" ?>
<?rfc include="reference.RFC.7739" ?>
<?rfc include="reference.RFC.7872" ?>
<?rfc include="reference.I-D.ietf-opsec-ipv6-eh-filtering" ?>
<!-- <?rfc include="reference.RFC.8799" ?> -->
<?rfc include="reference.RFC.8900" ?>
<reference anchor="Atlasis2014" target="http://www.insinuator.net/2014/05/a-novel-way-of-abusing-ipv6-extension-headers-to-evade-ipv6-security-devices/">
<front>
<title>A Novel Way of Abusing IPv6 Extension Headers to Evade IPv6 Security Devices</title>
<author initials="A.A." surname="Atlasis" fullname="Antonios Atlasis">
<organization></organization>
</author>
<date month="May" year="2014"/>
</front>
</reference>
<reference anchor="nmap" target="https://nmap.org/book/man-bypass-firewalls-ids.html">
<front>
<title>Dealing with IPv6 fragmentation in the DNS</title>
<author fullname="Fyodor" initials="" surname="Fyodor">
</author>
<date/>
</front>
<seriesInfo name="" value="Firewall/IDS Evasion and Spoofing"/>
</reference>
<reference anchor="Huston-2017" target="https://blog.apnic.net/2017/08/22/dealing-ipv6-fragmentation-dns/">
<front>
<title>Dealing with IPv6 fragmentation in the DNS</title>
<author fullname="Geoff Huston" initials="G." surname="Huston">
<organization abbrev="APNIC"/>
<address>
<email>[email protected]</email>
<uri>http://www.apnic.net</uri>
</address>
</author>
<date year="2017"/>
</front>
<seriesInfo name="" value="APNIC Blog"/>
</reference>
<reference anchor="Huston-2020" target="https://www.cmand.org/workshops/202006-v6/slides/2020-06-16-xtn-hdrs.pdf">
<front>
<title>Measurement of IPv6 Extension Header Support</title>
<author fullname="Geoff Huston" initials="G." surname="Huston">
<organization abbrev="APNIC"/>
<address>
<email>[email protected]</email>
<uri>http://www.apnic.net</uri>
</address>
</author>
<date year="2020"/>
</front>
<seriesInfo name="" value="NPS/CAIDA 2020 Virtual IPv6 Workshop"/>
</reference>
<reference anchor="Jaeggli-2018" target="https://blog.apnic.net/2018/01/11/ipv6-flow-label-misuse-hashing/">
<front>
<title>Dealing with IPv6 fragmentation in the DNS</title>
<author fullname="Joel Jaeggli" initials="G." surname="Jaeggli">
<organization abbrev="APNIC"/>
</author>
<date year="2018"/>
</front>
<seriesInfo name="" value="APNIC Blog"/>
</reference>
<reference anchor="Cunha-2020" target="https://www.cmand.org/workshops/202006-v6/slides/cunha.pdf">
<front>
<title>IPv4 vs IPv6 load balancing in Internet routes</title>
<author fullname="Italo Cunha" initials="I." surname="Cunha">
<organization abbrev="UFMG"/>
</author>
<date year="2020"/>
</front>
<seriesInfo name="" value="NPS/CAIDA 2020 Virtual IPv6 Workshop"/>
</reference>
<reference anchor="BH-EU-2014" target="https://www.ernw.de/download/eu-14-Atlasis-Rey-Schaefer-briefings-Evasion-of-HighEnd-IPS-Devices-wp.pdf">
<front>
<title>Evasion of High-End IDPS Devices at the IPv6 Era</title>
<author initials="A.a." surname="Atlasis" fullname="Antonios Atlasis">
<organization></organization>
</author>
<author initials="E.R." surname="Rey" fullname="Enno Rey">
<organization></organization>
</author>
<author initials="R.S." surname="Schaefer" fullname="Rafael Schaefer">
<organization></organization>
</author>
<date year="2014"/>
</front>
<seriesInfo name="" value="BlackHat Europe 2014"/>
</reference>
<reference anchor="Atlasis2012" target="https://media.blackhat.com/bh-eu-12/Atlasis/bh-eu-12-Atlasis-Attacking_IPv6-Slides.pdf">
<front>
<title>Attacking IPv6 Implementation Using Fragmentation</title>
<author initials="A.A." surname="Atlasis" fullname="Antonios Atlasis">
<organization></organization>
</author>
<date year=""/>
</front>
<seriesInfo name="" value="BlackHat Europe 2012. Amsterdam, Netherlands. March 14-16, 2012"/>
</reference>
<!--
<reference anchor="Gont-IEPG88" target="http://www.iepg.org/2013-11-ietf88/fgont-iepg-ietf88-ipv6-frag-and-eh.pdf">
<front>
<title>Fragmentation and Extension header Support in the IPv6 Internet</title>
<author initials="F." surname="Gont" fullname="Fernando Gont">
<organization></organization>
</author>
<date year=""/>
</front>
<seriesInfo name="" value="IEPG 88. Vancouver, BC, Canada. November 13, 2013"/>
</reference>
<reference anchor="Gont-Chown-IEPG89" target="http://www.iepg.org/2014-03-02-ietf89/fgont-iepg-ietf89-eh-update.pdf">
<front>
<title>A Small Update on the Use of IPv6 Extension Headers</title>
<author initials="F." surname="Gont" fullname="Fernando Gont">
<organization></organization>
</author>
<author initials="T." surname="Chown" fullname="Tim Chown">
<organization></organization>
</author>
<date year="IEPG 89. London, UK. March 2, 2014"/>
</front>
</reference>
-->
<reference anchor="Linkova-Gont-IEPG90" target="http://www.iepg.org/2014-07-20-ietf90/iepg-ietf90-ipv6-ehs-in-the-real-world-v2.0.pdf">
<front>
<title>IPv6 Extension Headers in the Real World v2.0</title>
<author initials="J." surname="Linkova" fullname="Jen Linkova">
<organization></organization>
</author>
<author initials="F." surname="Gont" fullname="Fernando Gont">
<organization></organization>
</author>
<date year=""/>
</front>
<seriesInfo name="" value="IEPG 90. Toronto, ON, Canada. July 20, 2014"/>
</reference>
<reference anchor="IEPG94-Scudder" target="http://www.iepg.org/2015-11-01-ietf94/IEPG-RouterArchitecture-jgs.pdf">
<front>
<title>Modern Router Architecture for Protocol Designers</title>
<author initials="B." surname="Petersen" fullname="Brian Petersen">
<organization>Juniper Networks</organization>
</author>
<author initials="J." surname="Scudder" fullname="John Scudder">
<organization>Juniper Networks</organization>
</author>
<date year=""/>
</front>
<seriesInfo name="" value="IEPG 94. Yokohama, Japan. November 1, 2015"/>
</reference>
<reference anchor="APNIC-Scudder" target="https://blog.apnic.net/2020/06/04/modern-router-architecture-and-ipv6/">
<front>
<title>Modern router architecture and IPv6</title>
<author initials="J." surname="Scudder" fullname="John Scudder">
<organization>Juniper Networks</organization>
</author>
<date year=""/>
</front>
<seriesInfo name="" value="APNIC Blog, June 4, 2020"/>
</reference>
<reference anchor="Bonica-NANOG58" target="https://www.nanog.org/sites/default/files/mon.general.fragmentation.bonica.pdf">
<front>
<title>IPV6 FRAGMENTATION: The Case For Deprecation</title>
<author initials="R." surname="Bonica" fullname="Ron Bonica">
<organization></organization>
</author>
<date year=""/>
</front>
<seriesInfo name="" value="NANOG 58. New Orleans, Louisiana, USA. June 3-5, 2013"/>
</reference>
<reference anchor="Cisco-Frag1" target="http://tools.cisco.com/security/center/content/CiscoSecurityAdvisory/cisco-sa-20130925-ipv6vfr">
<front>
<title>Cisco IOS Software IPv6 Virtual Fragmentation Reassembly Denial of Service Vulnerability</title>
<author initials="" surname="Cisco" fullname="Cisco">
<organization></organization>
</author>
<date month="September" year="2013"/>
</front>
</reference>
<reference anchor="Cisco-Frag2" target="http://tools.cisco.com/security/center/content/CiscoSecurityAdvisory/cisco-sa-20150611-iosxr">
<front>
<title>Cisco IOS XR Software Crafted IPv6 Packet Denial of Service Vulnerability</title>
<author initials="" surname="Cisco" fullname="Cisco">
<organization></organization>
</author>
<date month="June" year="2015"/>
</front>
</reference>
<reference anchor="FreeBSD-SA" target="https://www.freebsd.org/security/advisories/FreeBSD-SA-20:24.ipv6.asc">
<front>
<title>FreeBSD Security Advisory FreeBSD-SA-20:24.ipv6: IPv6 Hop-by-Hop options use-after-free bug</title>
<author initials="" surname="FreeBSD" fullname="FreeBSD">
<organization></organization>
</author>
<date day="2" month="September" year="2020"/>
</front>
</reference>
<reference anchor="Cisco-EH-Cons" target="http://www.cisco.com/en/US/technologies/tk648/tk872/technologies_white_paper0900aecd8054d37d.pdf">
<front>
<title>IPv6 Extension Headers Review and Considerations</title>
<author initials="" surname="Cisco" fullname="Cisco">
<organization></organization>
</author>
<date month="October" year="2006"/>
</front>
</reference>
<reference anchor="Zack-FW-Benchmark" target="https://www.ipv6hackers.org/files/meetings/ipv6-hackers-1/zack-ipv6hackers1-firewall-security-assessment-and-benchmarking.pdf">
<front>
<title abbrev="Firewall Benchmarking">Firewall Security Assessment and Benchmarking IPv6 Firewall Load Tests</title>
<author initials="E." surname="Zack" fullname="Eldad Zack">
</author>
<date year=""/>
</front>
<seriesInfo name="" value="IPv6 Hackers Meeting #1, Berlin, Germany. June 30, 2013"/>
<!-- July 27 - August 1 -->
</reference>
<reference anchor="PMTUD-Blackholes" target="http://www.nlnetlabs.nl/downloads/publications/pmtu-black-holes-msc-thesis.pdf">
<front>
<title>Discovering Path MTU black holes on the Internet using RIPE Atlas</title>
<author initials="M." surname="De Boer" fullname="Maikel De Boer">
<organization></organization>
</author>
<author initials="J." surname="Bosma" fullname="Jeffrey Bosma">
<organization></organization>
</author>
<date month="July" year="2012"/>
</front>
</reference>
</references>
</back>
</rfc>