summaryrefslogtreecommitdiff
path: root/testing/tests/ikev2/net2net-psk-dscp/pretest.dat
diff options
context:
space:
mode:
Diffstat (limited to 'testing/tests/ikev2/net2net-psk-dscp/pretest.dat')
-rw-r--r--testing/tests/ikev2/net2net-psk-dscp/pretest.dat17
1 files changed, 17 insertions, 0 deletions
diff --git a/testing/tests/ikev2/net2net-psk-dscp/pretest.dat b/testing/tests/ikev2/net2net-psk-dscp/pretest.dat
new file mode 100644
index 000000000..058c24f8f
--- /dev/null
+++ b/testing/tests/ikev2/net2net-psk-dscp/pretest.dat
@@ -0,0 +1,17 @@
+moon::rm /etc/ipsec.d/cacerts/*
+sun::rm /etc/ipsec.d/cacerts/*
+moon::/etc/init.d/iptables start 2> /dev/null
+sun::/etc/init.d/iptables start 2> /dev/null
+alice::iptables -t mangle -A OUTPUT -p icmp -j DSCP --set-dscp-class BE
+venus::iptables -t mangle -A OUTPUT -p icmp -j DSCP --set-dscp-class EF
+moon::iptables -t mangle -A PREROUTING -m dscp --dscp-class BE -j MARK --set-mark 10
+moon::iptables -t mangle -A PREROUTING -m dscp --dscp-class EF -j MARK --set-mark 20
+bob::iptables -t mangle -A OUTPUT -d PH_IP_ALICE -p icmp -j DSCP --set-dscp-class BE
+bob::iptables -t mangle -A OUTPUT -d PH_IP_VENUS -p icmp -j DSCP --set-dscp-class EF
+sun::iptables -t mangle -A PREROUTING -m dscp --dscp-class BE -j MARK --set-mark 10
+sun::iptables -t mangle -A PREROUTING -m dscp --dscp-class EF -j MARK --set-mark 20
+moon::ipsec start
+sun::ipsec start
+moon::sleep 1
+moon::ipsec up dscp-be
+moon::ipsec up dscp-ef