https://github.com/torvalds/linux
Revision 0cb7498f234e4e7d75187a8cae6c7c2053f2488a authored by Ahmed Abdelsalam on 04 May 2020, 14:42:11 UTC, committed by David S. Miller on 07 May 2020, 00:21:35 UTC
The Segment Routing Header (SRH) which defines the SRv6 dataplane is defined
in RFC8754.

RFC8754 (section 4.1) defines the SR source node behavior which encapsulates
packets into an outer IPv6 header and SRH. The SR source node encodes the
full list of Segments that defines the packet path in the SRH. Then, the
first segment from list of Segments is copied into the Destination address
of the outer IPv6 header and the packet is sent to the first hop in its path
towards the destination.

If the Segment list has only one segment, the SR source node can omit the SRH
as he only segment is added in the destination address.

RFC8754 (section 4.1.1) defines the Reduced SRH, when a source does not
require the entire SID list to be preserved in the SRH. A reduced SRH does
not contain the first segment of the related SR Policy (the first segment is
the one already in the DA of the IPv6 header), and the Last Entry field is
set to n-2, where n is the number of elements in the SR Policy.

RFC8754 (section 4.3.1.1) defines the SRH processing and the logic to
validate the SRH (S09, S10, S11) which works for both reduced and
non-reduced behaviors.

This patch updates seg6_validate_srh() to validate the SRH as per RFC8754.

Signed-off-by: Ahmed Abdelsalam <ahabdels@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 6e0ddb6
History
Tip revision: 0cb7498f234e4e7d75187a8cae6c7c2053f2488a authored by Ahmed Abdelsalam on 04 May 2020, 14:42:11 UTC
seg6: fix SRH processing to comply with RFC8754
Tip revision: 0cb7498
File Mode Size
Documentation
LICENSES
arch
block
certs
crypto
drivers
fs
include
init
ipc
kernel
lib
mm
net
samples
scripts
security
sound
tools
usr
virt
.clang-format -rw-r--r-- 15.8 KB
.cocciconfig -rw-r--r-- 59 bytes
.get_maintainer.ignore -rw-r--r-- 71 bytes
.gitattributes -rw-r--r-- 62 bytes
.gitignore -rw-r--r-- 1.7 KB
.mailmap -rw-r--r-- 15.1 KB
COPYING -rw-r--r-- 496 bytes
CREDITS -rw-r--r-- 97.4 KB
Kbuild -rw-r--r-- 1.3 KB
Kconfig -rw-r--r-- 595 bytes
MAINTAINERS -rw-r--r-- 539.4 KB
Makefile -rw-r--r-- 59.9 KB
README -rw-r--r-- 727 bytes

README

back to top