linux/tools
Justin Iurman 968691c777 selftests: net: Test for the IOAM insertion with IPv6
This test evaluates the IOAM insertion for IPv6 by checking the IOAM data
integrity on the receiver.

The topology is formed by 3 nodes: Alpha (sender), Beta (router in-between)
and Gamma (receiver). An IOAM domain is configured from Alpha to Gamma only,
which means not on the reverse path. When Gamma is the destination, Alpha
adds an IOAM option (Pre-allocated Trace) inside a Hop-by-hop and fills the
trace with its own IOAM data. Beta and Gamma also fill the trace. The IOAM
data integrity is checked on Gamma, by comparing with the pre-defined IOAM
configuration (see below).

    +-------------------+            +-------------------+
    |                   |            |                   |
    |    alpha netns    |            |    gamma netns    |
    |                   |            |                   |
    |  +-------------+  |            |  +-------------+  |
    |  |    veth0    |  |            |  |    veth0    |  |
    |  |  db01::2/64 |  |            |  |  db02::2/64 |  |
    |  +-------------+  |            |  +-------------+  |
    |         .         |            |         .         |
    +-------------------+            +-------------------+
              .                                .
              .                                .
              .                                .
    +----------------------------------------------------+
    |         .                                .         |
    |  +-------------+                  +-------------+  |
    |  |    veth0    |                  |    veth1    |  |
    |  |  db01::1/64 | ................ |  db02::1/64 |  |
    |  +-------------+                  +-------------+  |
    |                                                    |
    |                      beta netns                    |
    |                                                    |
    +--------------------------+-------------------------+

~~~~~~~~~~~~~~~~~~~~~~
| IOAM configuration |
~~~~~~~~~~~~~~~~~~~~~~

Alpha
+-----------------------------------------------------------+
| Type                | Value                               |
+-----------------------------------------------------------+
| Node ID             | 1                                   |
+-----------------------------------------------------------+
| Node Wide ID        | 11111111                            |
+-----------------------------------------------------------+
| Ingress ID          | 0xffff (default value)              |
+-----------------------------------------------------------+
| Ingress Wide ID     | 0xffffffff (default value)          |
+-----------------------------------------------------------+
| Egress ID           | 101                                 |
+-----------------------------------------------------------+
| Egress Wide ID      | 101101                              |
+-----------------------------------------------------------+
| Namespace Data      | 0xdeadbee0                          |
+-----------------------------------------------------------+
| Namespace Wide Data | 0xcafec0caf00dc0de                  |
+-----------------------------------------------------------+
| Schema ID           | 777                                 |
+-----------------------------------------------------------+
| Schema Data         | something that will be 4n-aligned   |
+-----------------------------------------------------------+

Note: When Gamma is the destination, Alpha adds an IOAM Pre-allocated Trace
      option inside a Hop-by-hop, where 164 bytes are pre-allocated for the
      trace, with 123 as the IOAM-Namespace and with 0xfff00200 as the trace
      type (= all available options at this time). As a result, and based on
      IOAM configurations here, only both Alpha and Beta should be capable of
      inserting their IOAM data while Gamma won't have enough space and will
      set the overflow bit.

Beta
+-----------------------------------------------------------+
| Type                | Value                               |
+-----------------------------------------------------------+
| Node ID             | 2                                   |
+-----------------------------------------------------------+
| Node Wide ID        | 22222222                            |
+-----------------------------------------------------------+
| Ingress ID          | 201                                 |
+-----------------------------------------------------------+
| Ingress Wide ID     | 201201                              |
+-----------------------------------------------------------+
| Egress ID           | 202                                 |
+-----------------------------------------------------------+
| Egress Wide ID      | 202202                              |
+-----------------------------------------------------------+
| Namespace Data      | 0xdeadbee1                          |
+-----------------------------------------------------------+
| Namespace Wide Data | 0xcafec0caf11dc0de                  |
+-----------------------------------------------------------+
| Schema ID           | 0xffffff (= None)                   |
+-----------------------------------------------------------+
| Schema Data         |                                     |
+-----------------------------------------------------------+

Gamma
+-----------------------------------------------------------+
| Type                | Value                               |
+-----------------------------------------------------------+
| Node ID             | 3                                   |
+-----------------------------------------------------------+
| Node Wide ID        | 33333333                            |
+-----------------------------------------------------------+
| Ingress ID          | 301                                 |
+-----------------------------------------------------------+
| Ingress Wide ID     | 301301                              |
+-----------------------------------------------------------+
| Egress ID           | 0xffff (default value)              |
+-----------------------------------------------------------+
| Egress Wide ID      | 0xffffffff (default value)          |
+-----------------------------------------------------------+
| Namespace Data      | 0xdeadbee2                          |
+-----------------------------------------------------------+
| Namespace Wide Data | 0xcafec0caf22dc0de                  |
+-----------------------------------------------------------+
| Schema ID           | 0xffffff (= None)                   |
+-----------------------------------------------------------+
| Schema Data         |                                     |
+-----------------------------------------------------------+

Signed-off-by: Justin Iurman <justin.iurman@uliege.be>
Signed-off-by: David S. Miller <davem@davemloft.net>
2021-07-21 08:16:11 -07:00
..
accounting
arch tools headers UAPI: Synch KVM's svm.h header with the kernel 2021-07-01 16:14:37 -03:00
bootconfig bootconfig: Share the checksum function with tools 2021-06-10 13:41:26 -04:00
bpf tools: bpf: Fix error in 'make -C tools/ bpf_install' 2021-07-07 14:06:38 -07:00
build tools build: Fix quiet cmd indentation 2021-05-17 12:10:03 +09:00
cgroup tools/cgroup/slabinfo.py: updated to work on current kernel 2021-04-23 14:42:40 -07:00
debugging tools: Fix "the the" in a message in kernel-chktaint 2021-06-13 17:01:17 -06:00
edid
firewire
firmware
gpio tools: gpio-utils: fix various kernel-doc warnings 2021-03-26 14:56:19 +01:00
hv
iio iio: event_monitor: Enable events before monitoring 2021-03-25 19:13:52 +00:00
include Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next 2021-07-15 22:40:10 -07:00
io_uring
kvm/kvm_stat tools/kvm_stat: Fix documentation typo 2021-05-07 06:06:22 -04:00
laptop
leds
lib Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next 2021-07-15 22:40:10 -07:00
memory-model tools/memory-model: Fix smp_mb__after_spinlock() spelling 2021-05-10 16:27:20 -07:00
objtool A single ELF format fix for a section flags mismatch bug that breaks 2021-06-28 11:35:55 -07:00
pci
pcmcia
perf perf test: Add free() calls for scandir() returned dirent entries 2021-07-09 15:34:41 -03:00
power tools/power/x86/intel-speed-select: v1.10 release 2021-06-18 15:29:32 +02:00
rcu tools/rcu: Add drgn script to dump number of RCU callbacks 2021-05-10 15:39:19 -07:00
scripts tools build: Fix quiet cmd indentation 2021-05-17 12:10:03 +09:00
spi spi: tools: make a symbolic link to the header file spi.h 2021-04-22 16:30:39 +01:00
testing selftests: net: Test for the IOAM insertion with IPv6 2021-07-21 08:16:11 -07:00
thermal/tmon tools: do not include scripts/Kbuild.include 2021-04-25 05:26:13 +09:00
time
tracing tools/latency-collector: Remove unneeded semicolon 2021-03-18 12:58:26 -04:00
usb treewide: remove editor modelines and cruft 2021-05-07 00:26:34 -07:00
virtio
vm tools/vm/page_owner_sort.c: check malloc() return 2021-06-29 10:53:47 -07:00
wmi
Makefile