Lines Matching +full:short +full:- +full:ping
2 # SPDX-License-Identifier: BSD-2-Clause
53 atf_check -s exit:0 -o ignore ping -c 1 -t 1 192.0.2.2
55 # Now enable. Ping should fail.
56 jexec alcatraz pfctl -e
58 atf_check -s exit:2 -o ignore ping -c 1 -t 1 192.0.2.2
63 atf_check -s exit:2 -o ignore ping -c 1 -t 1 192.0.2.2
68 atf_check -s exit:0 -o ignore ping -c 1 -t 1 192.0.2.2
73 atf_check -s exit:2 -o ignore ping -c 1 -t 1 192.0.2.2
78 atf_check -s exit:2 -o ignore ping -c 1 -t 1 192.0.2.2
83 atf_check -s exit:0 -o ignore ping -c 1 -t 1 192.0.2.2
88 atf_check -s exit:0 -o ignore ping -c 1 -t 1 192.0.2.2
92 atf_check -s exit:0 -o ignore ping -c 1 -t 1 192.0.2.2
97 atf_check -s exit:0 -o ignore ping -c 1 -t 1 192.0.2.2
102 atf_check -s exit:2 -o ignore ping -c 1 -t 1 192.0.2.2
107 jexec alcatraz pfctl -se
108 atf_check -s exit:2 -o ignore ping -c 1 -t 1 192.0.2.2
110 epair_prefix=$(echo $epair_a_mac | cut -c-8)
113 atf_check -s exit:2 -o ignore ping -c 1 -t 1 192.0.2.2
117 atf_check -s exit:2 -o ignore ping -c 1 -t 1 192.0.2.2
119 # Check '-F ethernet' works
120 jexec alcatraz pfctl -F ethernet
121 atf_check -s exit:0 -o ignore ping -c 1 -t 1 192.0.2.2
150 jexec alcatraz pfctl -e
152 atf_check -s exit:0 -o ignore ping -c 1 -t 1 192.0.2.2
157 atf_check -s exit:2 -o ignore ping -c 1 -t 1 192.0.2.2
162 arp -d 192.0.2.2
163 atf_check -s exit:2 -o ignore ping -c 1 -t 1 192.0.2.2
194 jexec alcatraz pfctl -e
196 arp -d 192.0.2.2
197 jexec alcatraz arp -d 192.0.2.1
199 # We don't allow the jail to receive ARP requests, so if we try to ping
201 ping -c 1 -t 1 192.0.2.2
203 mac=$(arp -an --libxo json \
204 | jq '."arp"."arp-cache"[] |
205 select(."ip-address"=="192.0.2.2")."mac-address"')
209 arp -d 192.0.2.2
210 jexec alcatraz arp -d 192.0.2.1
213 # jail tries to ping
214 jexec alcatraz ping -c 1 -t 1 192.0.2.1
216 mac=$(arp -an --libxo json \
217 | jq '."arp"."arp-cache"[] |
218 select(."ip-address"=="192.0.2.2")."mac-address"')
226 arp -d 192.0.2.2
227 jexec alcatraz arp -d 192.0.2.1
231 jexec alcatraz ping -c 1 -t 1 192.0.2.1
233 mac=$(jexec alcatraz arp -an --libxo json \
234 | jq '."arp"."arp-cache"[] |
235 select(."ip-address"=="192.0.2.1")."mac-address"')
247 atf_set descr 'Test a basic captive portal-like setup'
266 route add -net 198.51.100.0/24 192.0.2.1
273 jexec srv route add -net 192.0.2.0/24 198.51.100.1
276 atf_check -s exit:0 -o ignore ping -c 1 -t 1 198.51.100.2
281 "rdr on ${epair_gw}b proto tcp to port echo tagged captive -> 127.0.0.1 port echo"
282 jexec gw pfctl -e
285 atf_check -s exit:0 -o ignore ping -c 1 -t 1 198.51.100.2
289 jexec gw /usr/sbin/inetd -p ${PWD}/echo_inetd.pid $(atf_get_srcdir)/echo_inetd.conf
293 atf_check -s exit:0 -o match:"^foo$" -x "echo foo | nc -N 198.51.100.2 7"
302 "rdr on ${epair_gw}b proto tcp to port echo tagged captive -> 127.0.0.1 port echo"
305 atf_check -s exit:1 -x "echo foo | nc -N 198.51.100.2 7"
308 jexec srv /usr/sbin/inetd -p ${PWD}/echo_inetd.pid $(atf_get_srcdir)/echo_inetd.conf
312 atf_check -s exit:0 -o match:"^foo$" -x "echo foo | nc -N 198.51.100.2 7"
342 route add -net 198.51.100.0/24 192.0.2.1
349 jexec srv route add -net 192.0.2.0/24 198.51.100.1
354 atf_check -s exit:0 -o ignore ping -c 1 -t 1 198.51.100.2
361 "rdr on ${epair_gw}b proto tcp to port daytime tagged captive -> 127.0.0.1 port echo"
362 jexec gw pfctl -e
365 atf_check -s exit:0 -o ignore ping -c 1 -t 1 198.51.100.2
367 jexec gw /usr/sbin/inetd -p ${PWD}/gw.pid $(atf_get_srcdir)/echo_inetd.conf
368 jexec srv /usr/sbin/inetd -p ${PWD}/srv.pid $(atf_get_srcdir)/daytime_inetd.conf
371 echo foo | nc -N 198.51.100.2 13
374 atf_check -s exit:0 -o match:"^foo$" -x "echo foo | nc -N 198.51.100.2 13"
383 "rdr on ${epair_gw}b proto tcp to port daytime tagged captive -> 127.0.0.1 port echo"
386 atf_check -s exit:0 -o match:"^(Mon|Tue|Wed|Thu|Fri|Sat|Sun)" -x "echo foo | nc -N 198.51.100.2 13"
408 if ! kldstat -q -m dummynet; then
419 atf_check -s exit:0 -o ignore ping -i .1 -c 3 -s 1200 192.0.2.2
422 jexec alcatraz pfctl -e
426 # Ensure things don't break if non-IP(v4/v6) traffic hits dummynet
427 arp -d 192.0.2.2
429 # single ping succeeds just fine
430 atf_check -s exit:0 -o ignore ping -c 1 192.0.2.2
433 ping -i .1 -c 5 -s 1200 192.0.2.2
436 atf_check -s exit:2 -o ignore ping -c 1 -t 1 -s 1200 192.0.2.2
443 atf_check -s exit:2 -o ignore ping -c 1 -t 1 -s 1200 192.0.2.2
471 atf_check -s exit:0 -o ignore ping -c 1 192.0.2.2
473 jexec alcatraz pfctl -e
480 atf_check -s exit:0 -o ignore ping -c 1 192.0.2.2
487 atf_check -s exit:0 -o ignore ping -c 1 192.0.2.2
494 atf_check -s exit:2 -o ignore ping -c 1 -t 2 192.0.2.2
502 atf_check -s exit:0 -o ignore ping -c 1 192.0.2.2
504 atf_check -s exit:0 -o match:'baz' jexec alcatraz pfctl -sA
531 atf_check -s exit:0 -o ignore ping -c 1 192.0.2.2
533 jexec alcatraz pfctl -e
538 atf_check -s exit:2 -o ignore ping -c 1 192.0.2.2
540 # Change IP address and we can ping again
542 atf_check -s exit:0 -o ignore ping -c 1 192.0.2.2
548 atf_check -s exit:2 -o ignore ping -c 1 192.0.2.2
555 atf_check -s exit:2 -o ignore ping -c 1 192.0.2.2
581 atf_check -s exit:0 -o ignore ping -c 1 192.0.2.2
583 jexec alcatraz pfctl -e
588 atf_check -s exit:2 -o ignore ping -c 1 192.0.2.2
595 atf_check -s exit:0 -o ignore ping -c 1 192.0.2.2
622 atf_check -s exit:0 -o ignore ping -c 1 192.0.2.2
624 jexec alcatraz pfctl -e
629 atf_check -s exit:2 -o ignore ping -c 1 192.0.2.2
636 atf_check -s exit:0 -o ignore ping -c 1 192.0.2.2
647 atf_set descr 'Test overly short Ethernet packets'
662 jexec alcatraz pfctl -e
669 atf_check -s exit:0 -o ignore ping -c 1 192.0.2.2
671 jexec alcatraz pfctl -se -v
673 # Try sending ever shorter ping requests
677 --sendif ${epair}a \
678 --to 192.0.2.2 \
679 --len 14-64
690 atf_set descr 'Test bridge-to keyword'
710 atf_check -s exit:0 -o ignore ping -c 1 192.0.2.2
711 atf_check -s exit:1 -o ignore \
713 --sendif ${epair_in}a \
714 --to 192.0.2.2 \
715 --recvif ${epair_out}a
717 jexec alcatraz pfctl -e
719 "ether pass in on ${epair_in}b bridge-to ${epair_out}b"
722 atf_check -s exit:2 -o ignore ping -c 1 192.0.2.2
723 atf_check -s exit:0 -o ignore \
725 --sendif ${epair_in}a \
726 --to 192.0.2.2 \
727 --recvif ${epair_out}a