]> git.baikalelectronics.ru Git - kernel.git/commit
mpls: Enforce payload type of traffic sent using explicit NULL
authorRobert Shearman <rshearma@brocade.com>
Thu, 6 Aug 2015 10:04:56 +0000 (11:04 +0100)
committerDavid S. Miller <davem@davemloft.net>
Mon, 10 Aug 2015 05:51:42 +0000 (22:51 -0700)
commit38964cd08aca1d95c3cc5145be7251c659f9b7a0
tree165c54e4e2079c7dab2446535f1e1510df0de783
parentc290a95857ad1c2c6eae325acf7a74c76aead8ef
mpls: Enforce payload type of traffic sent using explicit NULL

RFC 4182 s2 states that if an IPv4 Explicit NULL label is the only
label on the stack, then after popping the resulting packet must be
treated as a IPv4 packet and forwarded based on the IPv4 header. The
same is true for IPv6 Explicit NULL with an IPv6 packet following.

Therefore, when installing the IPv4/IPv6 Explicit NULL label routes,
add an attribute that specifies the expected payload type for use at
forwarding time for determining the type of the encapsulated packet
instead of inspecting the first nibble of the packet.

Signed-off-by: Robert Shearman <rshearma@brocade.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/mpls/af_mpls.c