diff options
author | Philip Hazel <ph10@hermes.cam.ac.uk> | 2007-01-30 15:10:58 +0000 |
---|---|---|
committer | Philip Hazel <ph10@hermes.cam.ac.uk> | 2007-01-30 15:10:58 +0000 |
commit | 41c7c167f4d3552804bfaf7278d72fc448b851ff (patch) | |
tree | f462813d5fc6fa01ff8523deccf655fa5b806516 /test | |
parent | cf8b11a5399e64e50b6cd58f56a98197aca599d8 (diff) |
Magnus' patch for $sending_ip_address and $sending_port.
Diffstat (limited to 'test')
-rw-r--r-- | test/confs/0550 | 44 | ||||
-rw-r--r-- | test/log/0550 | 3 | ||||
-rw-r--r-- | test/scripts/0000-Basic/0550 | 25 | ||||
-rw-r--r-- | test/scripts/2000-GnuTLS/2013 | 2 | ||||
-rw-r--r-- | test/scripts/2100-OpenSSL/2113 | 2 | ||||
-rw-r--r-- | test/stderr/2013 | 66 | ||||
-rw-r--r-- | test/stderr/2113 | 66 | ||||
-rw-r--r-- | test/stdout/0550 | 24 |
8 files changed, 230 insertions, 2 deletions
diff --git a/test/confs/0550 b/test/confs/0550 new file mode 100644 index 000000000..e08750fdd --- /dev/null +++ b/test/confs/0550 @@ -0,0 +1,44 @@ +# Exim test configuration 0550 + +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 ----- + + +# ----- Routers ----- + +begin routers + +r1: + driver = accept + transport = t1 + + +# ----- Transports ----- + +begin transports + +t1: + driver = smtp + hosts = 127.0.0.1 : HOSTIPV4 + port = PORT_S + allow_localhost + helo_data = \ + ${if eq{$sending_ip_address}{127.0.0.1}{Tweedledum}{Tweedledee}} \ + to $host [$host_address] + + +# ------ Retry ------ + +begin retry + +* * F,1d,1d + +# End diff --git a/test/log/0550 b/test/log/0550 new file mode 100644 index 000000000..30da3add6 --- /dev/null +++ b/test/log/0550 @@ -0,0 +1,3 @@ +1999-03-02 09:44:33 10HmaX-0005vi-00 <= CALLER@myhost.test.ex U=CALLER P=local S=sss +1999-03-02 09:44:33 10HmaX-0005vi-00 SMTP error from remote mail server after MAIL FROM:<CALLER@myhost.test.ex>: host 127.0.0.1 [127.0.0.1]: 450 Defer +1999-03-02 09:44:33 10HmaX-0005vi-00 == userx@test.ex R=r1 T=t1 defer (-45): SMTP error from remote mail server after MAIL FROM:<CALLER@myhost.test.ex>: host ipv4.ipv4.ipv4.ipv4 [ipv4.ipv4.ipv4.ipv4]: 450 Defer diff --git a/test/scripts/0000-Basic/0550 b/test/scripts/0000-Basic/0550 new file mode 100644 index 000000000..9ca969971 --- /dev/null +++ b/test/scripts/0000-Basic/0550 @@ -0,0 +1,25 @@ +# $sending_ip_address +need_ipv4 +# +server PORT_S 2 +220 ESMTP +EHLO +250-OK +250 HELP +MAIL FROM +450 Defer +QUIT +221 OK +*EOF +220 ESMTP +EHLO +250-OK +250 HELP +MAIL FROM +450 Defer +QUIT +221 OK +**** +exim -odi userx@test.ex +**** +no_msglog_check diff --git a/test/scripts/2000-GnuTLS/2013 b/test/scripts/2000-GnuTLS/2013 index ef34a6677..f3d5719f0 100644 --- a/test/scripts/2000-GnuTLS/2013 +++ b/test/scripts/2000-GnuTLS/2013 @@ -8,7 +8,7 @@ Test message 1 exim userx@test.ex Test message 2 **** -exim -qqf +exim -qqf -d-all+acl **** killdaemon exim -DSERVER=server -DNOTDAEMON -qf diff --git a/test/scripts/2100-OpenSSL/2113 b/test/scripts/2100-OpenSSL/2113 index 292b4086a..be1f5e4b4 100644 --- a/test/scripts/2100-OpenSSL/2113 +++ b/test/scripts/2100-OpenSSL/2113 @@ -7,7 +7,7 @@ Test message 1 exim userx@test.ex Test message 2 **** -exim -qqf +exim -qqf -d-all+acl **** killdaemon exim -DSERVER=server -DNOTDAEMON -qf diff --git a/test/stderr/2013 b/test/stderr/2013 new file mode 100644 index 000000000..7a2cc7eca --- /dev/null +++ b/test/stderr/2013 @@ -0,0 +1,66 @@ +Exim version x.yz .... +configuration file is TESTSUITE/test-config +admin user +LOG: queue_run MAIN + Start queue run: pid=pppp -qqf +Connecting to 127.0.0.1 [127.0.0.1]:1225 ... connected + SMTP<< 220 myhost.test.ex ESMTP Exim x.yz Tue, 2 Mar 1999 09:44:33 +0000 + SMTP>> EHLO myhost.test.ex + SMTP<< 250-myhost.test.ex Hello localhost [127.0.0.1] + 250-SIZE 52428800 + 250-PIPELINING + 250-STARTTLS + 250 HELP + SMTP>> STARTTLS + SMTP<< 220 TLS go ahead + SMTP>> EHLO myhost.test.ex + SMTP<< 250-myhost.test.ex Hello localhost [127.0.0.1] + 250-SIZE 52428800 + 250-PIPELINING + 250 HELP + SMTP>> MAIL FROM:<CALLER@myhost.test.ex> SIZE=ssss + SMTP>> RCPT TO:<userx@test.ex> + SMTP>> DATA + SMTP<< 250 OK + SMTP<< 250 Accepted + SMTP<< 354 Enter message, ending with "." on a line by itself + SMTP<< 250 OK id=10HmaZ-0005vi-00 + SMTP>> EHLO myhost.test.ex + SMTP<< 250-myhost.test.ex Hello localhost [127.0.0.1] + 250-SIZE 52428800 + 250-PIPELINING + 250-STARTTLS + 250 HELP +LOG: MAIN + => userx@test.ex R=client T=send_to_server H=127.0.0.1 [127.0.0.1] X=TLS-1.0:RSA_AES_256_CBC_SHA1:32 DN="C=UK,L=Cambridge,O=University of Cambridge,OU=Computing Service,CN=Philip Hazel" +LOG: MAIN + Completed +Exim version x.yz .... +configuration file is TESTSUITE/test-config +trusted user +admin user + SMTP>> STARTTLS + SMTP<< 220 TLS go ahead + SMTP>> EHLO myhost.test.ex + SMTP<< 250-myhost.test.ex Hello localhost [127.0.0.1] + 250-SIZE 52428800 + 250-PIPELINING + 250 HELP + SMTP>> MAIL FROM:<CALLER@myhost.test.ex> SIZE=ssss + SMTP>> RCPT TO:<userx@test.ex> + SMTP>> DATA + SMTP<< 250 OK + SMTP<< 250 Accepted + SMTP<< 354 Enter message, ending with "." on a line by itself + SMTP<< 250 OK id=10HmbA-0005vi-00 + SMTP>> QUIT +LOG: MAIN + => userx@test.ex R=client T=send_to_server H=127.0.0.1 [127.0.0.1]* X=TLS-1.0:RSA_AES_256_CBC_SHA1:32 DN="C=UK,L=Cambridge,O=University of Cambridge,OU=Computing Service,CN=Philip Hazel" +LOG: MAIN + Completed +>>>>>>>>>>>>>>>> Exim pid=pppp terminating with rc=0 >>>>>>>>>>>>>>>> +LOG: queue_run MAIN + End queue run: pid=pppp -qqf +>>>>>>>>>>>>>>>> Exim pid=pppp terminating with rc=0 >>>>>>>>>>>>>>>> + +******** SERVER ******** diff --git a/test/stderr/2113 b/test/stderr/2113 new file mode 100644 index 000000000..d2fab9bca --- /dev/null +++ b/test/stderr/2113 @@ -0,0 +1,66 @@ +Exim version x.yz .... +configuration file is TESTSUITE/test-config +admin user +LOG: queue_run MAIN + Start queue run: pid=pppp -qqf +Connecting to 127.0.0.1 [127.0.0.1]:1225 ... connected + SMTP<< 220 myhost.test.ex ESMTP Exim x.yz Tue, 2 Mar 1999 09:44:33 +0000 + SMTP>> EHLO myhost.test.ex + SMTP<< 250-myhost.test.ex Hello localhost [127.0.0.1] + 250-SIZE 52428800 + 250-PIPELINING + 250-STARTTLS + 250 HELP + SMTP>> STARTTLS + SMTP<< 220 TLS go ahead + SMTP>> EHLO myhost.test.ex + SMTP<< 250-myhost.test.ex Hello localhost [127.0.0.1] + 250-SIZE 52428800 + 250-PIPELINING + 250 HELP + SMTP>> MAIL FROM:<CALLER@myhost.test.ex> SIZE=ssss + SMTP>> RCPT TO:<userx@test.ex> + SMTP>> DATA + SMTP<< 250 OK + SMTP<< 250 Accepted + SMTP<< 354 Enter message, ending with "." on a line by itself + SMTP<< 250 OK id=10HmaZ-0005vi-00 + SMTP>> EHLO myhost.test.ex + SMTP<< 250-myhost.test.ex Hello localhost [127.0.0.1] + 250-SIZE 52428800 + 250-PIPELINING + 250-STARTTLS + 250 HELP +LOG: MAIN + => userx@test.ex R=client T=send_to_server H=127.0.0.1 [127.0.0.1] X=TLSv1:AES256-SHA:256 DN="/C=UK/L=Cambridge/O=University of Cambridge/OU=Computing Service/CN=Philip Hazel" +LOG: MAIN + Completed +Exim version x.yz .... +configuration file is TESTSUITE/test-config +trusted user +admin user + SMTP>> STARTTLS + SMTP<< 220 TLS go ahead + SMTP>> EHLO myhost.test.ex + SMTP<< 250-myhost.test.ex Hello localhost [127.0.0.1] + 250-SIZE 52428800 + 250-PIPELINING + 250 HELP + SMTP>> MAIL FROM:<CALLER@myhost.test.ex> SIZE=ssss + SMTP>> RCPT TO:<userx@test.ex> + SMTP>> DATA + SMTP<< 250 OK + SMTP<< 250 Accepted + SMTP<< 354 Enter message, ending with "." on a line by itself + SMTP<< 250 OK id=10HmbA-0005vi-00 + SMTP>> QUIT +LOG: MAIN + => userx@test.ex R=client T=send_to_server H=127.0.0.1 [127.0.0.1]* X=TLSv1:AES256-SHA:256 DN="/C=UK/L=Cambridge/O=University of Cambridge/OU=Computing Service/CN=Philip Hazel" +LOG: MAIN + Completed +>>>>>>>>>>>>>>>> Exim pid=pppp terminating with rc=0 >>>>>>>>>>>>>>>> +LOG: queue_run MAIN + End queue run: pid=pppp -qqf +>>>>>>>>>>>>>>>> Exim pid=pppp terminating with rc=0 >>>>>>>>>>>>>>>> + +******** SERVER ******** diff --git a/test/stdout/0550 b/test/stdout/0550 new file mode 100644 index 000000000..57ef22d25 --- /dev/null +++ b/test/stdout/0550 @@ -0,0 +1,24 @@ + +******** SERVER ******** +Listening on port 1224 ... +Connection request from [127.0.0.1] +220 ESMTP +EHLO Tweedledum to 127.0.0.1 [127.0.0.1] +250-OK +250 HELP +MAIL FROM:<CALLER@myhost.test.ex> +450 Defer +QUIT +221 OK +Unexpected EOF read from client +Listening on port 1224 ... +Connection request from [ip4.ip4.ip4.ip4] +220 ESMTP +EHLO Tweedledee to ip4.ip4.ip4.ip4 [ip4.ip4.ip4.ip4] +250-OK +250 HELP +MAIL FROM:<CALLER@myhost.test.ex> +450 Defer +QUIT +221 OK +End of script |