History log of /src/tests/net/arp/
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: perseant-exfatfs-base-20250801 netbsd-11-base netbsd-10-1-RELEASE perseant-exfatfs-base-20240630 perseant-exfatfs-base netbsd-8-3-RELEASE netbsd-9-4-RELEASE netbsd-10-0-RELEASE netbsd-10-0-RC6 netbsd-10-0-RC5 netbsd-10-0-RC4 netbsd-10-0-RC3 netbsd-10-0-RC2 netbsd-10-0-RC1 netbsd-10-base netbsd-9-3-RELEASE cjep_sun2x-base1 cjep_sun2x-base cjep_staticlib_x-base1 netbsd-9-2-RELEASE cjep_staticlib_x-base netbsd-9-1-RELEASE phil-wifi-20200421 phil-wifi-20200411 is-mlppp-base phil-wifi-20200406 netbsd-8-2-RELEASE netbsd-9-0-RELEASE netbsd-9-0-RC2 netbsd-9-0-RC1 phil-wifi-20191119 netbsd-9-base phil-wifi-20190609 netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-merge-20190127 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226 pgoyette-compat-1126 pgoyette-compat-1020 pgoyette-compat-0930 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2 prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107
1.4 24-Nov-2016 ozaki-r

Reduce duplicate codes

Introduce net_common.sh that is to share common functions used in tests
for networking. This commit commonizes extract_new_packets. Other duplicate
codes will be moved to the file in further commits.


Revision tags: pgoyette-localcount-20161104 localcount-20160914 pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
1.3 30-Jul-2015 ozaki-r

branches: 1.3.2;
Fix TESTS_SH assignment


1.2 30-Jul-2015 ozaki-r

Add tests for IPv4 DAD


1.1 29-Jul-2015 ozaki-r

Add tests for ARP


1.49 18-Aug-2025 ozaki-r

tests: add tests for ARP address resolution


Revision tags: perseant-exfatfs-base-20250801 netbsd-11-base
1.48 09-Sep-2024 ozaki-r

branches: 1.48.2;
tests: add tests for ARP cache entry creations


1.47 09-Sep-2024 ozaki-r

tests: dedup t_arp.sh like others (NFC)


1.46 20-Aug-2024 ozaki-r

tests, arp: add tests for GARP on link up


Revision tags: perseant-exfatfs-base-20240630 perseant-exfatfs-base netbsd-10-0-RELEASE netbsd-10-0-RC6 netbsd-10-0-RC5 netbsd-10-0-RC4 netbsd-10-0-RC3 netbsd-10-0-RC2 netbsd-10-0-RC1 netbsd-10-base cjep_sun2x-base1 cjep_sun2x-base cjep_staticlib_x-base1 cjep_staticlib_x-base
1.45 18-Sep-2020 roy

branches: 1.45.6; 1.45.8;
arp tests: Delete ARP entry after failed ping test

As it might hang around in WAITDELETE for a few seconds.


1.44 17-Sep-2020 roy

arp_rtm: Only ping once

Pointless doing 10 pings.
On a slow system, it's possible that many RTM_MISS messages could
overflow into the next test.


1.43 15-Sep-2020 roy

Don't check lifetime when testing published


1.42 13-Sep-2020 roy

arp test: Use the ndp cache expiration test in place of the old one

As the logic is the same.
While here, GC some variables and comment out a redundant sleep.


Revision tags: phil-wifi-20200421 phil-wifi-20200411 phil-wifi-20200406
1.41 11-Mar-2020 roy

tests: check RTA_AUTHOR in messages


Revision tags: is-mlppp-base phil-wifi-20191119
1.40 09-Sep-2019 roy

t_arp: Wait for 10 seconds for RTM_MISS

Let's try increasing the ping timeout to try and fix PR misc/54525.


1.39 03-Sep-2019 roy

tests: fix ARP and NDP tests for RTM_* messages

While here add tests for RTM_MISS.


1.38 19-Aug-2019 ozaki-r

tests: use rump_server_add_iface to create interfaces


Revision tags: netbsd-9-base phil-wifi-20190609
1.37 13-May-2019 bad

branches: 1.37.2;
Get rid of all the -lrumpdev and -lrumpvfs that are no longer needed
after moving rump's mainbus from rumpdev to rumpkern.

Produces the same atf-run results as before.


Revision tags: pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226 pgoyette-compat-1126 pgoyette-compat-1020 pgoyette-compat-0930 pgoyette-compat-0906 pgoyette-compat-0728 phil-wifi-base pgoyette-compat-0625 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 pgoyette-compat-0415 pgoyette-compat-0407
1.36 06-Apr-2018 ozaki-r

branches: 1.36.2;
Add tests for GARP without DAD

Additionally make the existing tests for GARP more explicit.


1.35 06-Apr-2018 ozaki-r

Improve packet checks and error reporting


Revision tags: pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base
1.34 23-Nov-2017 kre

branches: 1.34.2;
Clean up the arp_rtm subtest...

1. Be assertive when claiming the pid of the background route monitor command,
not polite... (ie: $! will give you the pid, $? is just 0 there).
2. Since "wait 0" simply (always) exits with status 127, immediately (we
know without thinking that we have no child with pid 0) the waits were
ineffective - now (after fix #1) they work .. which requires the
route monitor that watches the arp -d to exit after 1 message, not 2,
as 1 is all it gets. (If there really should be 2, someone needs to
find out why the kernel is sending only 1 - I am not that someone).
3. The file contents need to be read only once, no matter how many patterns
we need to look for, save some work, and do it that way (this is not
really a bug,m but saving time for the ATF tests is always a good thing.)

Not sure if this will stop it randomly failing on bablyon5, but it might.
(The likely cause is that the "route.monitor" has not flushed its stdout
buffers at the time the "grep -A 3" [aside: why that way to read the file??]
is performed, so fails to find its expected output ... the route monitor would
get an extra message once interfaces start being destroyed, I assume, and
would exit then, flushing its buffer, but by then it is too late.
If that is/was the cause, then it should be fixed now.)


Revision tags: perseant-stdc-iso10646-base
1.33 28-Jun-2017 ozaki-r

Enable to remove multiple ARP/NDP entries for one destination

The kernel can have multiple ARP/NDP entries which have an indentical
destination on different interfaces. This is normal and can be
reproduce easily by ping -I or ping6 -S. We should be able to remove
such entries.

arp -d <ip> and ndp -d <ip> are changed to fetch all ARP/NDP entries
and remove matched entries. So we can remove multiple entries
described above. This fetch all and selective removal behavior is
the same as arp <ip> and ndp <ip>; they also do fetch all entries
and show only matched entries.

Related to PR 51179


1.32 28-Jun-2017 ozaki-r

Restore ARP/NDP entries to route show and netstat -r

Requested by dyoung@ some time ago


1.31 28-Jun-2017 ozaki-r

Drop RTF_LLINFO flag (now it's RTF_LLDATA) from local routes

They don't have llinfo anymore. And also the change fixes unexpected
behavior of ARP proxy.


1.30 26-Jun-2017 ozaki-r

Drop RTF_UP from a routing message of a deleted ARP/NDP entry


1.29 26-Jun-2017 ozaki-r

Improve backward compatibility of (fake) routing messages on adding an ARP/NDP entry

A message originally included only DST and GATEWAY. Restore it.


1.28 26-Jun-2017 ozaki-r

Fix usage of routing messages on arp -d and ndp -d

It didn't work as we expected; we should set RTA_GATEWAY not
RTA_IFP on RTM_GET to return an if_index and the kernel should
use it on RTM_DELETE.


1.27 22-Jun-2017 ozaki-r

Test implicit removals of ARP/NDP entries

One test case reproudces PR 51179.


1.26 21-Jun-2017 ozaki-r

Don't create a permanent L2 cache entry on adding an address to an interface

It was created to copy FreeBSD, however actually the cache isn't
necessary. Remove it to simplify the code and reduce the cost to
maintain it (e.g., keep a consistency with a corresponding local
route).


1.25 21-Jun-2017 ozaki-r

Set net.inet.arp.keep only if it's required


1.24 19-Jun-2017 ozaki-r

Add missing declarations for cleanup


1.23 16-Jun-2017 ozaki-r

Test routing messages emitted on operations of ARP/NDP entries


Revision tags: netbsd-8-base prg-localcount2-base3 prg-localcount2-base2 prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320 bouyer-socketcan-base pgoyette-localcount-20170107
1.22 25-Nov-2016 ozaki-r

branches: 1.22.6;
Share rump_server start/stop and interface creation/destruction functions

The common functions store socks of rump_servers, interfaces of rump_servers
and buses that intefaces connect and allow to destroy them with common
functions without specifying which socks, interfaces and buses we should
destroy.

This change reduces lots of similar setup/cleanup codes.


1.21 24-Nov-2016 ozaki-r

Move get_macaddr to net_common.sh


1.20 24-Nov-2016 ozaki-r

Move HIJACKING definition to net_common.sh


1.19 24-Nov-2016 ozaki-r

Reduce duplicate codes

Introduce net_common.sh that is to share common functions used in tests
for networking. This commit commonizes extract_new_packets. Other duplicate
codes will be moved to the file in further commits.


1.18 07-Nov-2016 ozaki-r

Accept DEBUG environment variable

By doing so, we can easily turn DEBUG on/off without modifying
the ATF scripts.


Revision tags: pgoyette-localcount-20161104 localcount-20160914
1.17 23-Aug-2016 christos

no functional change


Revision tags: pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
1.16 21-Jun-2016 ozaki-r

branches: 1.16.2;
Make a bunch of test names self-descriptive


1.15 18-Apr-2016 ozaki-r

Add a test case for static ARP

It tests receiving an ARP request that has a spa (i.e., IP address) whose
ARP entry already exists in the table as a static ARP entry.


1.14 04-Apr-2016 ozaki-r

Separate nexthop caches from the routing table

By this change, nexthop caches (IP-MAC address pair) are not stored
in the routing table anymore. Instead nexthop caches are stored in
each network interface; we already have lltable/llentry data structure
for this purpose. This change also obsoletes the concept of cloning/cloned
routes. Cloned routes no longer exist while cloning routes still exist
with renamed to connected routes.

Noticeable changes are:
- Nexthop caches aren't listed in route show/netstat -r
- sysctl(NET_RT_DUMP) doesn't return them
- If RTF_LLDATA is specified, it returns nexthop caches
- Several definitions of routing flags and messages are removed
- RTF_CLONING, RTF_XRESOLVE, RTF_LLINFO, RTF_CLONED and RTM_RESOLVE
- RTF_CONNECTED is added
- It has the same value of RTF_CLONING for backward compatibility
- route's -xresolve, -[no]cloned and -llinfo options are removed
- -[no]cloning remains because it seems there are users
- -[no]connected is introduced and recommended
to be used instead of -[no]cloning
- route show/netstat -r drops some flags
- 'L' and 'c' are not seen anymore
- 'C' now indicates a connected route
- Gateway value of a route of an interface address is now not
a L2 address but "link#N" like a connected (cloning) route
- Proxy ARP: "arp -s ... pub" doesn't create a route

You can know details of behavior changes by seeing diffs under tests/.

Proposed on tech-net and tech-kern:
http://mail-index.netbsd.org/tech-net/2016/03/11/msg005701.html


1.13 04-Mar-2016 ozaki-r

Improve tests of proxy arp

The tests make it clear how it behaves though, I don't know if the current
behavior is what it should be.


1.12 29-Feb-2016 ozaki-r

Add tests on activating a new MAC address


1.11 25-Feb-2016 ozaki-r

Add basic tests for Proxy ARP

The tests don't much enough and need more realitic tests, for example
tests for a setup using ppp found in PR 44032.


1.10 02-Dec-2015 ozaki-r

Make checks strict

rump.arp should fail with File exists (EEXIST).


1.9 31-Aug-2015 ozaki-r

Reflect the current ARP cache implementation in tests

net.inet.arp.prune and net.inet.arp.refresh were obsoleted.


1.8 13-Aug-2015 ozaki-r

Reflect a fix on rt_refcnt

The test was adjusted based on wrong behavior.


1.7 07-Aug-2015 ozaki-r

Check MAC address of ARP caches additionally


1.6 31-Jul-2015 ozaki-r

Return 0 explicitly to avoid unexpected failures when $DEBUG=false


1.5 31-Jul-2015 ozaki-r

Add tests of cache overwriting


1.4 31-Jul-2015 ozaki-r

Add tests for temp option


1.3 30-Jul-2015 ozaki-r

Add tests for arp -a option


1.2 30-Jul-2015 ozaki-r

Add tests for GARP


1.1 29-Jul-2015 ozaki-r

Add tests for ARP


Revision tags: perseant-exfatfs-base-20250801 netbsd-11-base
1.16 20-Aug-2024 ozaki-r

tests, arp: add tests of address duplications without DAD


Revision tags: perseant-exfatfs-base-20240630 perseant-exfatfs-base netbsd-8-3-RELEASE netbsd-9-4-RELEASE netbsd-10-0-RELEASE netbsd-10-0-RC6 netbsd-10-0-RC5 netbsd-10-0-RC4 netbsd-10-0-RC3 netbsd-10-0-RC2 netbsd-10-0-RC1 netbsd-10-base netbsd-9-3-RELEASE cjep_sun2x-base1 cjep_sun2x-base cjep_staticlib_x-base1 netbsd-9-2-RELEASE cjep_staticlib_x-base netbsd-9-1-RELEASE phil-wifi-20200421 phil-wifi-20200411 is-mlppp-base phil-wifi-20200406 netbsd-8-2-RELEASE netbsd-9-0-RELEASE netbsd-9-0-RC2 netbsd-9-0-RC1 phil-wifi-20191119 netbsd-9-base phil-wifi-20190609 netbsd-8-1-RELEASE netbsd-8-1-RC1 pgoyette-compat-merge-20190127 pgoyette-compat-20190127 pgoyette-compat-20190118 pgoyette-compat-1226 pgoyette-compat-1126 pgoyette-compat-1020 pgoyette-compat-0930 pgoyette-compat-0906 pgoyette-compat-0728 netbsd-8-0-RELEASE phil-wifi-base pgoyette-compat-0625 netbsd-8-0-RC2 pgoyette-compat-0521 pgoyette-compat-0502 pgoyette-compat-0422 netbsd-8-0-RC1 pgoyette-compat-0415 pgoyette-compat-0407 pgoyette-compat-0330 pgoyette-compat-0322 pgoyette-compat-0315 pgoyette-compat-base matt-nb8-mediatek-base perseant-stdc-iso10646-base netbsd-8-base prg-localcount2-base3 prg-localcount2-base2 prg-localcount2-base1 prg-localcount2-base pgoyette-localcount-20170426 bouyer-socketcan-base1 pgoyette-localcount-20170320
1.15 11-Mar-2017 ozaki-r

branches: 1.15.14; 1.15.22; 1.15.24;
Improve test stability and output messages on failure


1.14 08-Mar-2017 ozaki-r

Improve test stability and output messages on failure


Revision tags: bouyer-socketcan-base pgoyette-localcount-20170107
1.13 25-Nov-2016 ozaki-r

branches: 1.13.2;
Share rump_server start/stop and interface creation/destruction functions

The common functions store socks of rump_servers, interfaces of rump_servers
and buses that intefaces connect and allow to destroy them with common
functions without specifying which socks, interfaces and buses we should
destroy.

This change reduces lots of similar setup/cleanup codes.


1.12 24-Nov-2016 ozaki-r

Add missing bus argument for extract_new_packets


1.11 24-Nov-2016 ozaki-r

Move HIJACKING definition to net_common.sh


1.10 24-Nov-2016 ozaki-r

Reduce duplicate codes

Introduce net_common.sh that is to share common functions used in tests
for networking. This commit commonizes extract_new_packets. Other duplicate
codes will be moved to the file in further commits.


1.9 07-Nov-2016 ozaki-r

Accept DEBUG environment variable

By doing so, we can easily turn DEBUG on/off without modifying
the ATF scripts.


Revision tags: pgoyette-localcount-20161104
1.8 14-Sep-2016 christos

adjust for new ifconfig output.


Revision tags: localcount-20160914
1.7 10-Aug-2016 kre

+ -lrumpdev


Revision tags: pgoyette-localcount-20160806 pgoyette-localcount-20160726 pgoyette-localcount-base
1.6 25-Aug-2015 ozaki-r

branches: 1.6.2;
Give a chance to send a DAD announce packet

ifconfig -w ensures IP addresses have left tentative state, however,
it doesn't guarantee that a DAD announce packet is sent. The kernel
clears tentative flag and then sends the packet so that ifconfig -w
can return before the kernel sends the packet.


1.5 24-Aug-2015 ozaki-r

Disable another tentative state check

It's too ephemeral to check robustly.


1.4 17-Aug-2015 ozaki-r

Improve test stability

- Take a diff between packet dumps and use it for packet checking
- it's resistant against packet reorder
- Seep 2 sec to make sure a NS message is sent
- Disable tentative state check for now
- it's too ephemeral to check robustly


1.3 31-Jul-2015 ozaki-r

Remove remaining debug code


1.2 31-Jul-2015 ozaki-r

Fix cleanup; halt all running rump_servers


1.1 30-Jul-2015 ozaki-r

Add tests for IPv4 DAD