summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/README13
-rw-r--r--test/confs/055639
-rw-r--r--test/log/05565
-rw-r--r--test/rejectlog/05563
-rw-r--r--test/scripts/0000-Basic/055655
-rw-r--r--test/stdout/055659
6 files changed, 169 insertions, 5 deletions
diff --git a/test/README b/test/README
index 5c060974c..c1398329d 100644
--- a/test/README
+++ b/test/README
@@ -1,4 +1,4 @@
-$Cambridge: exim/test/README,v 1.7 2007/01/31 16:52:12 ph10 Exp $
+$Cambridge: exim/test/README,v 1.8 2007/02/20 15:58:02 ph10 Exp $
EXPORTABLE EXIM TEST SUITE
--------------------------
@@ -6,7 +6,7 @@ EXPORTABLE EXIM TEST SUITE
This document last updated for:
Test Suite Version: 4.67
-Date: 31 January 2007
+Date: 20 February 2007
BACKGROUND
@@ -765,9 +765,12 @@ as well as to the named file.
This command runs the auxiliary "client" program that simulates an SMTP client.
It is controlled by a script read from its standard input, details of which are
-given below. The only option is -t, which must be followed by a number, to
-specify the command timeout in seconds. The program connects to the given IP
-address and port, using the specified interface, if one is given.
+given below. There are two options. One is -t, which must be followed directly
+by a number, to specify the command timeout in seconds (e.g. -t5). The default
+timeout is 1 second. The other option is -tls-on-connect, which causes the
+client to try to start up a TLS session as soon as it has connected, without
+using the STARTTLS command. The client program connects to the given IP address
+and port, using the specified interface, if one is given.
client-ssl [<options>] <ip address> <port> [<outgoing interface>] \
diff --git a/test/confs/0556 b/test/confs/0556
new file mode 100644
index 000000000..7ed0105ed
--- /dev/null
+++ b/test/confs/0556
@@ -0,0 +1,39 @@
+# Exim test configuration 0556
+
+ACL_MAIL=accept
+ACL_RCPT=accept
+ACL_PREDATA=accept
+PAH=127.0.0.1
+
+exim_path = EXIM_PATH
+host_lookup_order = bydns
+primary_hostname = myhost.test.ex
+rfc1413_query_timeout = 0s
+spool_directory = DIR/spool
+log_file_path = DIR/spool/log/%slog
+gecos_pattern = ""
+gecos_name = CALLER_NAME
+
+# ----- Main settings -----
+
+acl_smtp_predata = ACL_PREDATA
+acl_smtp_mail = ACL_MAIL
+acl_smtp_rcpt = ACL_RCPT
+pipelining_advertise_hosts = PAH
+
+queue_only
+
+# ----- ACL -----
+
+begin ACL
+
+check_predata:
+ accept delay = 2s
+
+check_mail:
+ accept delay = 2s
+
+check_rcpt:
+ accept delay = 2s
+
+# End
diff --git a/test/log/0556 b/test/log/0556
new file mode 100644
index 000000000..5f1631c5a
--- /dev/null
+++ b/test/log/0556
@@ -0,0 +1,5 @@
+1999-03-02 09:44:33 exim x.yz daemon started: pid=pppp, no queue runs, listening for SMTP on port 1225
+1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was advertised): rejected "data" H=(abcd) [127.0.0.1] next input="Start: sent early ...\r\n"
+1999-03-02 09:44:33 exim x.yz daemon started: pid=pppp, no queue runs, listening for SMTP on port 1225
+1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "mail from:<userx@test.ex>" H=(abcd) [127.0.0.1] next input="rcpt to:<userx@test.ex>\r\n"
+1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "rcpt to:<userx@test.ex>" H=(abcd) [127.0.0.1] next input="data\r\n"
diff --git a/test/rejectlog/0556 b/test/rejectlog/0556
new file mode 100644
index 000000000..2f0d87f1b
--- /dev/null
+++ b/test/rejectlog/0556
@@ -0,0 +1,3 @@
+1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was advertised): rejected "data" H=(abcd) [127.0.0.1] next input="Start: sent early ...\r\n"
+1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "mail from:<userx@test.ex>" H=(abcd) [127.0.0.1] next input="rcpt to:<userx@test.ex>\r\n"
+1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "rcpt to:<userx@test.ex>" H=(abcd) [127.0.0.1] next input="data\r\n"
diff --git a/test/scripts/0000-Basic/0556 b/test/scripts/0000-Basic/0556
new file mode 100644
index 000000000..54c3a86a5
--- /dev/null
+++ b/test/scripts/0000-Basic/0556
@@ -0,0 +1,55 @@
+# SMTP synchronization checks before sending responses
+need_ipv4
+#
+exim -DSERVER=server -DACL_PREDATA=check_predata -bd -oX PORT_D
+****
+# The pause (+++ 1) in the middle of this is so that there is no pending
+# input when DATA is received, but we start sending the data itself too
+# early (the server will be waiting 2 seconds in the predata ACL).
+#
+client 127.0.0.1 PORT_D
+??? 220
+ehlo abcd
+??? 250-
+??? 250-
+??? 250-
+??? 250
+rset\r\nmail from:<userx@test.ex>\r\nrcpt to:<userx@test.ex>\r\ndata
++++ 1
+Start: sent early ...
+??? 250
+??? 250
+??? 250
+??? 554
+****
+sleep 1
+killdaemon
+# This time turn off pipelining to check MAIL and RCPT
+exim -DSERVER=server -DACL_MAIL=check_mail -DACL_RCPT=check_rcpt -DPAH= \
+ -bd -oX PORT_D
+****
+client -t5 127.0.0.1 PORT_D
+??? 220
+ehlo abcd
+??? 250-
+??? 250-
+??? 250
+mail from:<userx@test.ex>
++++ 1
+rcpt to:<userx@test.ex>
+??? 554
+****
+client -t5 127.0.0.1 PORT_D
+??? 220
+ehlo abcd
+??? 250-
+??? 250-
+??? 250
+mail from:<userx@test.ex>
+??? 250
+rcpt to:<userx@test.ex>
++++ 1
+data
+??? 554
+****
+killdaemon
diff --git a/test/stdout/0556 b/test/stdout/0556
new file mode 100644
index 000000000..d8d60ab9a
--- /dev/null
+++ b/test/stdout/0556
@@ -0,0 +1,59 @@
+Connecting to 127.0.0.1 port 1225 ... connected
+??? 220
+<<< 220 myhost.test.ex ESMTP Exim x.yz Tue, 2 Mar 1999 09:44:33 +0000
+>>> ehlo abcd
+??? 250-
+<<< 250-myhost.test.ex Hello abcd [127.0.0.1]
+??? 250-
+<<< 250-SIZE 52428800
+??? 250-
+<<< 250-PIPELINING
+??? 250
+<<< 250 HELP
+>>> rset\r\nmail from:<userx@test.ex>\r\nrcpt to:<userx@test.ex>\r\ndata
++++ 1
+>>> Start: sent early ...
+??? 250
+<<< 250 Reset OK
+??? 250
+<<< 250 OK
+??? 250
+<<< 250 Accepted
+??? 554
+<<< 554 SMTP synchronization error
+End of script
+Connecting to 127.0.0.1 port 1225 ... connected
+??? 220
+<<< 220 myhost.test.ex ESMTP Exim x.yz Tue, 2 Mar 1999 09:44:33 +0000
+>>> ehlo abcd
+??? 250-
+<<< 250-myhost.test.ex Hello abcd [127.0.0.1]
+??? 250-
+<<< 250-SIZE 52428800
+??? 250
+<<< 250 HELP
+>>> mail from:<userx@test.ex>
++++ 1
+>>> rcpt to:<userx@test.ex>
+??? 554
+<<< 554 SMTP synchronization error
+End of script
+Connecting to 127.0.0.1 port 1225 ... connected
+??? 220
+<<< 220 myhost.test.ex ESMTP Exim x.yz Tue, 2 Mar 1999 09:44:33 +0000
+>>> ehlo abcd
+??? 250-
+<<< 250-myhost.test.ex Hello abcd [127.0.0.1]
+??? 250-
+<<< 250-SIZE 52428800
+??? 250
+<<< 250 HELP
+>>> mail from:<userx@test.ex>
+??? 250
+<<< 250 OK
+>>> rcpt to:<userx@test.ex>
++++ 1
+>>> data
+??? 554
+<<< 554 SMTP synchronization error
+End of script