summaryrefslogtreecommitdiffstats
path: root/qa/testsuite
diff options
context:
space:
mode:
author/C=EU/ST=EU/CN=Pablo Neira Ayuso/emailAddress=pablo@netfilter.org </C=EU/ST=EU/CN=Pablo Neira Ayuso/emailAddress=pablo@netfilter.org>2008-04-13 01:52:48 +0000
committer/C=EU/ST=EU/CN=Pablo Neira Ayuso/emailAddress=pablo@netfilter.org </C=EU/ST=EU/CN=Pablo Neira Ayuso/emailAddress=pablo@netfilter.org>2008-04-13 01:52:48 +0000
commitc2f6ad83b0087a246447726a121d1694d95fc627 (patch)
treeed7510155d595afa74a7128c58fac0bd8091b315 /qa/testsuite
parentde56472737c5aa007f775bc475570f49c0e55fb3 (diff)
add initial automated qa testing for the conntrack cli
Diffstat (limited to 'qa/testsuite')
-rw-r--r--qa/testsuite/00create16
-rw-r--r--qa/testsuite/01delete2
2 files changed, 18 insertions, 0 deletions
diff --git a/qa/testsuite/00create b/qa/testsuite/00create
new file mode 100644
index 0000000..7af7d37
--- /dev/null
+++ b/qa/testsuite/00create
@@ -0,0 +1,16 @@
+#missing destination
+-I -s 1.1.1.1 -p tcp --sport 10 --dport 20 --state LISTEN -u SEEN_REPLY -t 50 ; BAD
+#missing source
+-I -d 2.2.2.2 -p tcp --sport 10 --dport 20 --state LISTEN -u SEEN_REPLY -t 50 ; BAD
+#missing protocol
+-I -s 1.1.1.1 -d 2.2.2.2 --sport 10 --dport 20 --state LISTEN -u SEEN_REPLY -t 50 ; BAD
+#missing source port
+-I -s 1.1.1.1 -d 2.2.2.2 -p tcp --dport 20 --state LISTEN -u SEEN_REPLY -t 50 ; BAD
+#missing timeout
+-I -s 1.1.1.1 -d 2.2.2.2 -p tcp --sport 10 --dport 20 --state LISTEN -u SEEN_REPLY ; BAD
+# create a conntrack
+-I -s 1.1.1.1 -d 2.2.2.2 -p tcp --sport 10 --dport 20 --state LISTEN -u SEEN_REPLY -t 50 ; OK
+# create again
+-I -s 1.1.1.1 -d 2.2.2.2 -p tcp --sport 10 --dport 20 --state LISTEN -u SEEN_REPLY -t 50 ; BAD
+# create from reply
+-I -r 2.2.2.2 -q 1.1.1.1 -p tcp --reply-port-src 11 --reply-port-dst 21 --state LISTEN -u SEEN_REPLY -t 50 ; OK
diff --git a/qa/testsuite/01delete b/qa/testsuite/01delete
new file mode 100644
index 0000000..dd3ca8b
--- /dev/null
+++ b/qa/testsuite/01delete
@@ -0,0 +1,2 @@
+# delete
+-D -s 1.1.1.1 -d 2.2.2.2 -p tcp --sport 10 --dport 20 ; OK