opnsense-src/sbin/ping/tests
Dag-Erling Smørgrav 8b55607a7f ping: Simplify protocol selection.
* Interrupt the option loop as soon as we have an indication of which
  protocol is intended.
* If we end up having to perform a DNS lookup, loop over the entire
  result looking for either IPv4 or IPv6 addresses.

Sponsored by:	NetApp, Inc.
Sponsored by:	Klara, Inc.
Reviewed by:	rscheff, kevans, allanjude
Differential Revision:	https://reviews.freebsd.org/D42137

(cherry picked from commit 7fd2c91a291bd518e012b438d6ca6fdd04d39dbf)

ping: Consistently use EX_NOHOST for DNS failures.

Traditionally, ping returned exit code EX_NOHOST if a DNS lookup failed.
That is still the case for the legacy code in the new merged ping, but
not for IPv6 targets, nor when a DNS lookup is performed in order to
determine which version of the tool to invoke.

While here, also make sure that the error message is consistent.

Sponsored by:	NetApp, Inc.
Sponsored by:	Klara, Inc.
Reviewed by:	kevans
Differential Revision:	https://reviews.freebsd.org/D42159

(cherry picked from commit c4ffb80ef18f6b581dc28c14bc579e0e7c73438c)

ping: Add missing ATF boilerplate.

Reviewed by:	kevans
Differential Revision:	https://reviews.freebsd.org/D42161

(cherry picked from commit fc7143b48341fb16ef5b2262c7cd5b5c47056112)
2023-12-13 17:41:46 +01:00
..
in_cksum_test.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
injection.py Add test cases for ping with IP options in the response 2022-12-25 22:59:58 -07:00
Makefile Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
ping_6_c1_s8_t1.out ping: Unify ping/ping6 statistics section 2023-11-06 11:45:43 -05:00
ping_c1_s8_t1_S1.out ping: Unify ping/ping6 statistics section 2023-11-06 11:45:43 -05:00
ping_c1_s56_t1.out ping: By default, don't reverse lookup IP addresses 2019-08-22 18:57:24 +00:00
ping_c1_s56_t1_S127.out ping: if -S srcaddr uses a numeric address, use that protocol 2022-05-20 18:30:47 -05:00
ping_test.sh ping: Simplify protocol selection. 2023-12-13 17:41:46 +01:00
test_ping.py ping: Require root user for pytests 2023-11-06 11:45:44 -05:00