diff options
author | Seth David Schoen <schoen@loyalty.org> | 2021-01-25 20:08:34 -0800 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2021-01-26 17:52:16 -0800 |
commit | 9b0b7837b9f1b29e89de8c5e321dc94601fda4b5 (patch) | |
tree | 343ae871db84659aa02b3c1be5256f1336f2514f /tools/testing/selftests/net/Makefile | |
parent | 285715ac9a81209540bfdb2495e3a005b701bef8 (diff) | |
download | linux-9b0b7837b9f1b29e89de8c5e321dc94601fda4b5.tar.bz2 |
selftests: add IPv4 unicast extensions tests
Add selftests for kernel behavior with regard to various classes of
unallocated/reserved IPv4 addresses, checking whether or not these
addresses can be assigned as unicast addresses on links and used in
routing.
Expect the current kernel behavior at the time of this patch. That is:
* 0/8 and 240/4 may be used as unicast, with the exceptions of 0.0.0.0
and 255.255.255.255;
* the lowest address in a subnet may only be used as a broadcast address;
* 127/8 may not be used as unicast (the route_localnet option, which is
disabled by default, still leaves it treated slightly specially);
* 224/4 may not be used as unicast.
Signed-off-by: Seth David Schoen <schoen@loyalty.org>
Suggested-by: John Gilmore <gnu@toad.com>
Acked-by: Dave Taht <dave.taht@gmail.com>
Reviewed-by: David Ahern <dsahern@kernel.org>
Link: https://lore.kernel.org/r/20210126040834.GR24989@frotz.zork.net
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'tools/testing/selftests/net/Makefile')
-rw-r--r-- | tools/testing/selftests/net/Makefile | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/testing/selftests/net/Makefile b/tools/testing/selftests/net/Makefile index fa5fa425d148..25f198bec0b2 100644 --- a/tools/testing/selftests/net/Makefile +++ b/tools/testing/selftests/net/Makefile @@ -22,6 +22,7 @@ TEST_PROGS += devlink_port_split.py TEST_PROGS += drop_monitor_tests.sh TEST_PROGS += vrf_route_leaking.sh TEST_PROGS += bareudp.sh +TEST_PROGS += unicast_extensions.sh TEST_PROGS_EXTENDED := in_netns.sh TEST_GEN_FILES = socket nettest TEST_GEN_FILES += psock_fanout psock_tpacket msg_zerocopy reuseport_addr_any |