Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F102906810
D31787.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D31787.diff
View Options
diff --git a/tests/sys/netpfil/common/dummynet.sh b/tests/sys/netpfil/common/dummynet.sh
--- a/tests/sys/netpfil/common/dummynet.sh
+++ b/tests/sys/netpfil/common/dummynet.sh
@@ -70,6 +70,50 @@
firewall_cleanup $1
}
+pipe_v6_head()
+{
+ atf_set descr 'Basic IPv6 pipe test'
+ atf_set require.user root
+}
+
+pipe_v6_body()
+{
+ fw=$1
+ firewall_init $fw
+ dummynet_init $fw
+
+ epair=$(vnet_mkepair)
+ vnet_mkjail alcatraz ${epair}b
+
+ ifconfig ${epair}a inet6 2001:db8:42::1/64 up no_dad
+ jexec alcatraz ifconfig ${epair}b inet6 2001:db8:42::2/64 up no_dad
+
+ # Sanity check
+ atf_check -s exit:0 -o ignore ping6 -i .1 -c 3 -s 1200 2001:db8:42::2
+
+ jexec alcatraz dnctl pipe 1 config bw 100Byte/s
+
+ firewall_config alcatraz ${fw} \
+ "ipfw" \
+ "ipfw add 1000 pipe 1 ip6 from any to any"
+
+ # Single ping succeeds
+ atf_check -s exit:0 -o ignore ping6 -c 1 2001:db8:42::2
+
+ # Saturate the link
+ ping6 -i .1 -c 5 -s 1200 2001:db8:42::2
+
+ # We should now be hitting the limit and get this packet dropped.
+ atf_check -s exit:2 -o ignore ping6 -c 1 -s 1200 2001:db8:42::2
+}
+
+pipe_v6_cleanup()
+{
+ firewall_cleanup $1
+}
+
setup_tests \
pipe \
+ ipfw \
+ pipe_v6 \
ipfw
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Nov 19, 2:25 PM (20 h, 48 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
14718076
Default Alt Text
D31787.diff (1 KB)
Attached To
Mode
D31787: dummynet tests: pipe test for IPv6
Attached
Detach File
Event Timeline
Log In to Comment