summaryrefslogtreecommitdiff
path: root/test/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'test/scripts')
-rw-r--r--test/scripts/0000-Basic/00013
-rw-r--r--test/scripts/0000-Basic/00029
-rw-r--r--test/scripts/0000-Basic/00212
-rw-r--r--test/scripts/0000-Basic/00412
-rw-r--r--test/scripts/0000-Basic/00998
-rw-r--r--test/scripts/0000-Basic/01374
-rw-r--r--test/scripts/0000-Basic/02066
-rw-r--r--test/scripts/0000-Basic/021116
-rw-r--r--test/scripts/0000-Basic/021716
-rw-r--r--test/scripts/0000-Basic/022721
-rw-r--r--test/scripts/0000-Basic/02304
-rw-r--r--test/scripts/0000-Basic/02906
-rw-r--r--test/scripts/0000-Basic/03001
-rw-r--r--test/scripts/0000-Basic/03011
-rw-r--r--test/scripts/0000-Basic/031416
-rw-r--r--test/scripts/0000-Basic/032237
-rw-r--r--test/scripts/0000-Basic/042019
-rw-r--r--test/scripts/0000-Basic/04601
-rw-r--r--test/scripts/0000-Basic/04654
-rw-r--r--test/scripts/0000-Basic/050218
-rw-r--r--test/scripts/0000-Basic/05512
-rw-r--r--test/scripts/0000-Basic/05552
-rw-r--r--test/scripts/0000-Basic/055710
-rw-r--r--test/scripts/0000-Basic/05644
-rw-r--r--test/scripts/0000-Basic/05701
-rw-r--r--test/scripts/0000-Basic/05725
-rw-r--r--test/scripts/0000-Basic/057437
-rw-r--r--test/scripts/0000-Basic/057510
-rw-r--r--test/scripts/0000-Basic/057665
-rw-r--r--test/scripts/0000-Basic/0900219
-rw-r--r--test/scripts/0000-Basic/0901387
-rw-r--r--test/scripts/0000-Basic/09021100
-rw-r--r--test/scripts/2000-GnuTLS/200013
-rw-r--r--test/scripts/2000-GnuTLS/20132
-rw-r--r--test/scripts/2000-GnuTLS/201514
-rw-r--r--test/scripts/2000-GnuTLS/20202
-rw-r--r--test/scripts/2000-GnuTLS/203434
l---------test/scripts/2000-GnuTLS/20511
-rw-r--r--test/scripts/2000-GnuTLS/205222
-rw-r--r--test/scripts/2000-GnuTLS/209078
-rw-r--r--test/scripts/2000-GnuTLS/20919
-rw-r--r--test/scripts/2100-OpenSSL/21006
-rw-r--r--test/scripts/2100-OpenSSL/21202
-rw-r--r--test/scripts/2100-OpenSSL/21302
-rw-r--r--test/scripts/2100-OpenSSL/215134
-rw-r--r--test/scripts/2100-OpenSSL/215221
-rw-r--r--test/scripts/2100-OpenSSL/219077
-rw-r--r--test/scripts/2100-OpenSSL/21918
-rw-r--r--test/scripts/2800-lmdb/280011
-rw-r--r--test/scripts/2800-lmdb/REQUIRES1
-rw-r--r--test/scripts/3000-Perl/300114
-rw-r--r--test/scripts/3000-Perl/30113
l---------test/scripts/3000-Perl/30121
-rw-r--r--test/scripts/3400-plaintext/34144
-rw-r--r--test/scripts/4000-scanning/400836
-rw-r--r--test/scripts/4000-scanning/400964
-rw-r--r--test/scripts/4015-scan-ipv6/401517
-rw-r--r--test/scripts/4500-Domain-Keys-Identified-Mail/45037
-rw-r--r--test/scripts/4500-Domain-Keys-Identified-Mail/4509111
-rw-r--r--test/scripts/4800-dnssec-dnslookup/480411
-rw-r--r--test/scripts/5400-cutthrough/540011
-rw-r--r--test/scripts/5400-cutthrough/540185
-rw-r--r--test/scripts/5400-cutthrough/540237
-rw-r--r--test/scripts/5400-cutthrough/540342
-rw-r--r--test/scripts/5400-cutthrough/540430
-rw-r--r--test/scripts/5400-cutthrough/5405228
-rw-r--r--test/scripts/5500-PRDR/559040
-rw-r--r--test/scripts/5500-PRDR/559139
-rw-r--r--test/scripts/5500-PRDR/REQUIRES1
-rw-r--r--test/scripts/5600-OCSP-OpenSSL/560020
-rw-r--r--test/scripts/5600-OCSP-OpenSSL/560114
-rw-r--r--test/scripts/5600-OCSP-OpenSSL/5610115
-rw-r--r--test/scripts/5600-OCSP-OpenSSL/561177
-rw-r--r--test/scripts/5650-OCSP-GnuTLS/56508
-rw-r--r--test/scripts/5650-OCSP-GnuTLS/565112
-rw-r--r--test/scripts/5700-events/57001
-rw-r--r--test/scripts/5730-OCSP-GnuTLS-events/573014
-rw-r--r--test/scripts/5740-OCSP-OpenSSL-events/574012
-rw-r--r--test/scripts/5840-DANE-OpenSSL/584020
-rw-r--r--test/scripts/5900-queuefile-transport/59004
-rw-r--r--test/scripts/5900-queuefile-transport/59014
-rw-r--r--test/scripts/5900-queuefile-transport/590223
-rw-r--r--test/scripts/5900-queuefile-transport/REQUIRES1
83 files changed, 3281 insertions, 198 deletions
diff --git a/test/scripts/0000-Basic/0001 b/test/scripts/0000-Basic/0001
index 4b5f282ca..78682571d 100644
--- a/test/scripts/0000-Basic/0001
+++ b/test/scripts/0000-Basic/0001
@@ -26,5 +26,6 @@ exim -bP accept_8bitmime \
tcp_nodelay \
trusted_users \
unknown_login \
- warn_message_file
+ warn_message_file \
+ syslog_pid
****
diff --git a/test/scripts/0000-Basic/0002 b/test/scripts/0000-Basic/0002
index 35e6f6bf9..c2dcc40d9 100644
--- a/test/scripts/0000-Basic/0002
+++ b/test/scripts/0000-Basic/0002
@@ -23,6 +23,7 @@ primary_hostname: ${primary_hostname}
qualify_domain: $qualify_domain
bounce_return_size_limit: ${bounce_return_size_limit}
spool_directory: $spool_directory
+queue_name: $queue_name
unknown: ${unknown}
h_subject: $h_subject:(should be empty)
h_subject:$h_subject (should be empty)
@@ -131,7 +132,9 @@ addresses: ${addresses:Exim Person <local-part@dom.ain> (that's me), \
xyz@abc, nullgroupname:;, group: p@q, r@s; }
addresses: ${addresses:local-part@dom.ain <local-part@dom.ain>}
-escape: ${escape:B7·F2ò}
+escape: ${escape:B7·F2ò}
+excape8bit: ${escape8bit:undisturbed text\ttab\nnewline\ttab\\backslash \176tilde\177DEL\200\x81.}
+
eval: ${eval:1+1}
eval: ${eval:1+2*3}
eval: ${eval:(1+2)*3}
@@ -629,6 +632,10 @@ ${extract{}{X=3}}
${extract{ }{X=3}}
${extract{ 2 }{ }{a b c}}
+${map{a,1:b,2:c,3}{${extract{1}{,}{$item}{$value}{}}}}
+${map{a,1:b,2:c,3}{${extract{1}{,}{$item}{$value}{failcase}{bogus_argument}}}}
+${map{a,1:b,2:c,3}{${extract{1}{,}{$item}{$value}fail}}}
+
# Translation
abcdea aaa xyz ${tr{abcdea}{aaa}{xyz}}
diff --git a/test/scripts/0000-Basic/0021 b/test/scripts/0000-Basic/0021
index 8fbf94837..16c5c3b80 100644
--- a/test/scripts/0000-Basic/0021
+++ b/test/scripts/0000-Basic/0021
@@ -24,6 +24,8 @@ Test message 5.
****
exim -bs -oMa 10.9.8.7
****
+exim -DLOG_SELECTOR=-connection_reject -bs -oMa 10.9.8.7
+****
exim -d-all+acl+lists -bs -oMa 10.9.8.8
mail from:<bad@test1>
mail from:<ok@test1>
diff --git a/test/scripts/0000-Basic/0041 b/test/scripts/0000-Basic/0041
index 3495375cb..0f8cdb3b5 100644
--- a/test/scripts/0000-Basic/0041
+++ b/test/scripts/0000-Basic/0041
@@ -2,6 +2,8 @@
exim -bh 1.1.1.1
vrfy userx@test.ex
vrfy hardfail@test.ex
+vrfy unqual
+vrfy
expn postmaster
quit
****
diff --git a/test/scripts/0000-Basic/0099 b/test/scripts/0000-Basic/0099
index c386e1e85..d6655dcf9 100644
--- a/test/scripts/0000-Basic/0099
+++ b/test/scripts/0000-Basic/0099
@@ -38,14 +38,18 @@ Test message
****
dump retry
#
-# one for a lookup-failure (in manualroute)
+# a lookup-failure (in manualroute)
exim -odi userx@nonexist
Test message
****
-# one for a lookup-failure (in dnslookup)
+# a lookup-failure (good MX, missing A) in dnslookup, deferred
exim -odi userx@mxt2.test.ex
Test message
****
+# a lookup-failure (missing MX) in dnslookup, deferred
+exim -odi userx@mxnonexist.test.ex
+Test message
+****
dump retry
#
#
diff --git a/test/scripts/0000-Basic/0137 b/test/scripts/0000-Basic/0137
index 0335afe57..56941941f 100644
--- a/test/scripts/0000-Basic/0137
+++ b/test/scripts/0000-Basic/0137
@@ -1,10 +1,12 @@
# mailbox locking
exim -odi userx
+Subject: First
Transport: local_delivery
First message.
****
exim_lock -v test-mail/userx
exim -odi userx
+Subject: Second
Transport: local_delivery
Second message
****
@@ -12,6 +14,7 @@ exim -qf
****
exim_lock -v -fcntl test-mail/userx
exim -odi userx
+Subject: Third
Transport: local_delivery_fcntl
Third message
****
@@ -19,6 +22,7 @@ exim -qf
****
exim_lock -v -fcntl test-mail/userx
exim -odi userx
+Subject: Fourth
Transport: local_delivery_fcntl_blocking
Fourth message
****
diff --git a/test/scripts/0000-Basic/0206 b/test/scripts/0000-Basic/0206
index 6f9968f96..64afd8014 100644
--- a/test/scripts/0000-Basic/0206
+++ b/test/scripts/0000-Basic/0206
@@ -1,12 +1,16 @@
# timeout_frozen_after with ignore_bounce_errors_after
sudo exim -odi -f unknown@test.ex nonexist@test.ex freeze@test.ex
****
-sleep 1
+# that gave us a frozen bounce, and a deferred message (with one undelivered addr)
sudo exim -Mf $msg1
****
+# now 2 frozen, one of which is a bounce
+# check that ignore_bounce_errors_after finishes off the frozen bounce (only)
+millisleep 2500
exim -qf
****
sleep 3
+# check that timeout_frozen_after finishes off the (remaining) frozen
exim -q
****
no_msglog_check
diff --git a/test/scripts/0000-Basic/0211 b/test/scripts/0000-Basic/0211
index f8750d2e8..dbe41c723 100644
--- a/test/scripts/0000-Basic/0211
+++ b/test/scripts/0000-Basic/0211
@@ -59,3 +59,19 @@ QUIT
exim -odi userx@domain1 usery@domain2
Test message 2
****
+#
+exim -z "Test: reject ehlo, then close (late, giving time for HELO)"
+****
+sudo rm DIR/spool/db/retry
+server PORT_S
+220 Connected OK
+EHLO
+550 You are banned
+HELO
+****
+exim -odi userx@domain1
+Test message 4
+****
+#
+#
+no_msglog_check
diff --git a/test/scripts/0000-Basic/0217 b/test/scripts/0000-Basic/0217
index c47ae5c9e..a74be606f 100644
--- a/test/scripts/0000-Basic/0217
+++ b/test/scripts/0000-Basic/0217
@@ -36,7 +36,7 @@ RCPT TO
250 OK
*sleep 2
****
-exim -odi a b c
+exim -odi e f g
.
****
# Temp error on MAIL
@@ -56,7 +56,7 @@ DATA
QUIT
250 OK
****
-exim -odi a b
+exim -odi h i
.
****
# Perm error on MAIL
@@ -76,7 +76,7 @@ DATA
QUIT
250 OK
****
-exim -odi a b
+exim -odi j k
.
****
# All get temp errors
@@ -96,7 +96,7 @@ DATA
QUIT
250 OK
****
-exim -odi a b
+exim -odi l m
.
****
# All get perm errors
@@ -116,7 +116,7 @@ DATA
QUIT
250 OK
****
-exim -odi a b
+exim -odi n o
.
****
# Mixed temp and perm
@@ -136,7 +136,7 @@ DATA
QUIT
250 OK
****
-exim -odi a b
+exim -odi p q
.
****
# Perm error on DATA after good recipients
@@ -156,7 +156,7 @@ DATA
QUIT
250 OK
****
-exim -odi a b
+exim -odi r s
.
****
# Temp error on DATA after good recipients
@@ -176,7 +176,7 @@ DATA
QUIT
250 OK
****
-exim -odi a b
+exim -odi t u
.
****
# Temp error on DATA after good recipients, but in first block of a
diff --git a/test/scripts/0000-Basic/0227 b/test/scripts/0000-Basic/0227
index 59adba788..a67dab2eb 100644
--- a/test/scripts/0000-Basic/0227
+++ b/test/scripts/0000-Basic/0227
@@ -203,6 +203,27 @@ MAIL FROM:<ok@localhost1>
RCPT TO:<z@remote.domain>
QUIT
****
+#
+server PORT_S
+220 Server ready
+EHLO
+250- wotcher
+250-SIZE
+250 OK
+MAIL FROM
+250 OK
+RCPT TO
+250 OK
+QUIT
+250 OK
+****
+sudo exim -v -bs -oMa V4NET.0.0.6
+EHLO me
+MAIL FROM:<ok@localhost1> SIZE=420000
+RCPT TO:<z@test.ex>
+QUIT
+****
+#
server PORT_S
220 Server ready
LHLO
diff --git a/test/scripts/0000-Basic/0230 b/test/scripts/0000-Basic/0230
index b62e31355..92ef10c51 100644
--- a/test/scripts/0000-Basic/0230
+++ b/test/scripts/0000-Basic/0230
@@ -67,7 +67,7 @@ quit
#
exim -DSERVER=server -bd -oX PORT_D
****
-sudo exim -DRT -bs -oMa V4NET.9.8.7.1225
+sudo exim -DOPT -bs -oMa V4NET.9.8.7.1225
mail from:<x@y.x>
rcpt to:<x@test.ex>
data
@@ -75,7 +75,7 @@ this is a message
.
quit
****
-exim -DRT -odi -qf
+exim -DOPT -odi -qf
****
#
#
diff --git a/test/scripts/0000-Basic/0290 b/test/scripts/0000-Basic/0290
index f2d69e1d0..f4b63aa8e 100644
--- a/test/scripts/0000-Basic/0290
+++ b/test/scripts/0000-Basic/0290
@@ -1,11 +1,11 @@
# .include and macro tests
exim -bP local_interfaces message_size_limit recipients_max remote_sort_domains receive_timeout
****
-exim -DRT= -bP receive_timeout
+exim -DOPT= -bP receive_timeout
****
-exim -DRT -bP receive_timeout
+exim -DOPT -bP receive_timeout
****
-exim '-D RT = receive_timeout = 4s ' -bP receive_timeout
+exim '-D OPT = receive_timeout = 4s ' -bP receive_timeout
****
1
exim -DINC='.include non/absolute' -bP receive_timeout
diff --git a/test/scripts/0000-Basic/0300 b/test/scripts/0000-Basic/0300
index 047dba410..920f12b5d 100644
--- a/test/scripts/0000-Basic/0300
+++ b/test/scripts/0000-Basic/0300
@@ -1,5 +1,6 @@
# SMTP synchronization checks, with and without PIPELINING
need_ipv4
+munge sync_check_data
#
exim -DSERVER=server -bd -oX PORT_D
****
diff --git a/test/scripts/0000-Basic/0301 b/test/scripts/0000-Basic/0301
index 08996c7ef..45a824285 100644
--- a/test/scripts/0000-Basic/0301
+++ b/test/scripts/0000-Basic/0301
@@ -1,5 +1,6 @@
# SMTP synchronization checks disabled, with and without PIPELINING
need_ipv4
+munge sync_check_data
#
exim -DSERVER=server -bd -oX PORT_D
****
diff --git a/test/scripts/0000-Basic/0314 b/test/scripts/0000-Basic/0314
index 6fec248d8..dd3d39906 100644
--- a/test/scripts/0000-Basic/0314
+++ b/test/scripts/0000-Basic/0314
@@ -1,5 +1,17 @@
# host_reject_connection
-exim -bh V4NET.0.0.1
+need_ipv4
+exim -DSERVER=server -bd -oX PORT_D
****
-exim -bh V4NET.0.0.2
+client 127.0.0.1 PORT_D
+??? 554
****
+client HOSTIPV4 PORT_D
+??? 220
+****
+killdaemon
+exim -DSERVER=server -DLOG_SELECTOR=-connection_reject -bd -oX PORT_D
+****
+client 127.0.0.1 PORT_D
+??? 554
+****
+killdaemon
diff --git a/test/scripts/0000-Basic/0322 b/test/scripts/0000-Basic/0322
index e317eb784..91fabeeb7 100644
--- a/test/scripts/0000-Basic/0322
+++ b/test/scripts/0000-Basic/0322
@@ -13,8 +13,7 @@ RCPT TO:
250 Recipient OK
DATA
>
-QUIT
-250 OK
+*eof
****
exim -odi x@test.ex
****
@@ -29,9 +28,7 @@ MAIL FROM:
RCPT TO:
>
DATA
-550 Failed DATA
-QUIT
-250 OK
+*eof
****
exim -odi x@test.ex
****
@@ -46,9 +43,7 @@ MAIL FROM:
RCPT TO:
550 Can't send RCPT
DATA
-550 Can't send DATA
-QUIT
-250 OK
+*eof
****
exim -odi x@test.ex
****
@@ -68,9 +63,7 @@ RCPT TO:
RCPT TO:
250 Third RCPT OK
DATA
-550 Failed DATA
-QUIT
-250 OK
+*eof
****
exim -odi x@test.ex y@test.ex z@test.ex
****
@@ -109,8 +102,7 @@ RCPT TO:
250 Recipient OK
DATA
>
-QUIT
-250 OK
+*eof
****
exim -odi x@test.ex
****
@@ -123,10 +115,7 @@ MAIL FROM:
250 Sender OK
RCPT TO:
>
-DATA
-550 Failed DATA
-QUIT
-250 OK
+*eof
****
exim -odi x@test.ex
****
@@ -137,12 +126,7 @@ EHLO
250 HELP
MAIL FROM:
>
-RCPT TO:
-550 Can't send RCPT
-DATA
-550 Can't send DATA
-QUIT
-250 OK
+*eof
****
exim -odi x@test.ex
****
@@ -158,12 +142,7 @@ RCPT TO:
RCPT TO:
>
250 Second RCPT malformed
-RCPT TO:
-250 Third RCPT OK
-DATA
-550 Failed DATA
-QUIT
-250 OK
+*eof
****
exim -odi x@test.ex y@test.ex z@test.ex
****
diff --git a/test/scripts/0000-Basic/0420 b/test/scripts/0000-Basic/0420
index c61a23d1e..2f7fe4998 100644
--- a/test/scripts/0000-Basic/0420
+++ b/test/scripts/0000-Basic/0420
@@ -1,14 +1,31 @@
# received_header_text
-exim -d -bh V4NET.0.0.0
+exim -bd -DSERVER=server -oX PORT_D
+****
+#
+client 127.0.0.1 PORT_D
+??? 220
+helo client.test.ex
+??? 250
mail from:<x@y>
+??? 250
rcpt to:<x@y>
+??? 250
data
+??? 354
Message.
.
+??? 250
mail from:<a@b>
+??? 250
rcpt to:<x@y>
+??? 250
data
+??? 354
Message.
.
+??? 250
quit
+??? 221
****
+#
+killdaemon
diff --git a/test/scripts/0000-Basic/0460 b/test/scripts/0000-Basic/0460
index b91be2084..beb4e00db 100644
--- a/test/scripts/0000-Basic/0460
+++ b/test/scripts/0000-Basic/0460
@@ -45,3 +45,4 @@ QUIT
killdaemon
# Wait for delivery process
sleep 1
+sortlog
diff --git a/test/scripts/0000-Basic/0465 b/test/scripts/0000-Basic/0465
index 03abe164f..de8b6cbdf 100644
--- a/test/scripts/0000-Basic/0465
+++ b/test/scripts/0000-Basic/0465
@@ -7,7 +7,7 @@ quit
1
exim -f abc@somewhere. xxx
****
-exim -DSTD=strip_trailing_dot -d -bs
+exim -DOPT=strip_trailing_dot -d -bs
mail from:<>
rcpt to:<abc@domain.>
data
@@ -15,7 +15,7 @@ To: abc@domain.
.
quit
****
-exim -DSTD=strip_trailing_dot -f abc@somewhere. xxx@yyy.
+exim -DOPT=strip_trailing_dot -f abc@somewhere. xxx@yyy.
****
exim -d -bs
mail from:<>
diff --git a/test/scripts/0000-Basic/0502 b/test/scripts/0000-Basic/0502
index d4b8f0fdb..c22205ca7 100644
--- a/test/scripts/0000-Basic/0502
+++ b/test/scripts/0000-Basic/0502
@@ -23,3 +23,21 @@ exim -bs -DLAST=''
mail from:<a@b>
quit
****
+#
+# Check the server closes conn after a quit-response
+exim -DSERVER=server -DLAST=accept -bd -oX PORT_D
+****
+client 127.0.0.1 PORT_D
+??? 220
+EHLO test.ex
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250 HELP
+QUIT
+??? 221
+???*eof
+****
+#
+killdaemon
diff --git a/test/scripts/0000-Basic/0551 b/test/scripts/0000-Basic/0551
index afd5c9b05..d11064c00 100644
--- a/test/scripts/0000-Basic/0551
+++ b/test/scripts/0000-Basic/0551
@@ -6,7 +6,7 @@ Message 1
exim -odi userx@test.ex userz@test.ex
Message 2
****
-exim -DLS= -odi userx@test.ex
+exim -DLOG_SELECTOR= -odi userx@test.ex
Message 3
****
exigrep userx
diff --git a/test/scripts/0000-Basic/0555 b/test/scripts/0000-Basic/0555
index 947f1692d..c35113603 100644
--- a/test/scripts/0000-Basic/0555
+++ b/test/scripts/0000-Basic/0555
@@ -1,4 +1,4 @@
-# Long lines for fakedefer/fakereject
+# Long response lines for fakedefer/fakereject
exim -bs
mail from:<>
rcpt to:<userx@test.ex>
diff --git a/test/scripts/0000-Basic/0557 b/test/scripts/0000-Basic/0557
index 8e05b4719..02ab466d2 100644
--- a/test/scripts/0000-Basic/0557
+++ b/test/scripts/0000-Basic/0557
@@ -1,16 +1,16 @@
# host_find_failed=ignore
1
-exim -DX=# -DY=# -bt userx@test.ex
+exim -DFAKE=# -DOPT=# -bt userx@test.ex
****
1
-exim -DY=# -DHOSTS=a.non.exist -bt userx@test.ex
+exim -DOPT=# -DHOSTS=a.non.exist -bt userx@test.ex
****
1
-exim -DY=# -DHOSTS=a.non.exist:b.non.exist -bt userx@test.ex
+exim -DOPT=# -DHOSTS=a.non.exist:b.non.exist -bt userx@test.ex
****
-exim -DY=# -DHOSTS=a.non.exist:127.0.0.1 -bt userx@test.ex
+exim -DOPT=# -DHOSTS=a.non.exist:127.0.0.1 -bt userx@test.ex
****
-exim -DY=# -DHOSTS=127.0.0.1:b.non.exist:127.0.0.2 -bt userx@test.ex
+exim -DOPT=# -DHOSTS=127.0.0.1:b.non.exist:127.0.0.2 -bt userx@test.ex
****
1
exim -DHOSTS=a.non.exist -DHAI=defer -bt userx@test.ex
diff --git a/test/scripts/0000-Basic/0564 b/test/scripts/0000-Basic/0564
index 68fb607ec..26acd66d2 100644
--- a/test/scripts/0000-Basic/0564
+++ b/test/scripts/0000-Basic/0564
@@ -1,9 +1,9 @@
# testing -bw inetd wait mode
need_ipv4
#
-exim -DSERVER=wait:PORT_D -bw
+exim -DSERVER=wait:PORT_DYNAMIC -bw
****
-client 127.0.0.1 PORT_D
+client 127.0.0.1 PORT_DYNAMIC
??? 220
ehlo abcd
??? 250-
diff --git a/test/scripts/0000-Basic/0570 b/test/scripts/0000-Basic/0570
index ed54afc1d..75ac0cec6 100644
--- a/test/scripts/0000-Basic/0570
+++ b/test/scripts/0000-Basic/0570
@@ -61,6 +61,7 @@ exim -DOPTION='multi_domain=${if eqi {$address_data}{domA.ex} {no}{yes}}' -q
#
killdaemon
no_msglog_check
+sortlog
#
#
##
diff --git a/test/scripts/0000-Basic/0572 b/test/scripts/0000-Basic/0572
index 05ba658f7..2866a23f1 100644
--- a/test/scripts/0000-Basic/0572
+++ b/test/scripts/0000-Basic/0572
@@ -3,7 +3,7 @@
# Ought to test a non-priv user, checking "hide", but
# the testsuite cannot do that...
#
-munge optional_nossl
+munge optional_config
exim -bP spool_directory
****
perl -e 'print "\n";'
@@ -26,3 +26,6 @@ perl -e 'print "\n";'
#
exim -bP config
****
+#
+exim -n -bP config
+****
diff --git a/test/scripts/0000-Basic/0574 b/test/scripts/0000-Basic/0574
new file mode 100644
index 000000000..6784bde56
--- /dev/null
+++ b/test/scripts/0000-Basic/0574
@@ -0,0 +1,37 @@
+# debug logging ACL modifier
+munge debuglog_stdout
+#
+exim -DSERVER=server -bd -oX PORT_D
+****
+#
+client 127.0.0.1 PORT_D
+??? 220
+EHLO test.ex
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250
+MAIL FROM:<tester@test.ex>
+??? 250
+RCPT TO:<dest@test.ex>
+??? 250
+DATA
+??? 354
+Subject: test
+
+body
+.
+??? 250
+QUIT
+??? 221
+****
+#
+killdaemon
+#
+1
+cat DIR/spool/log/serverdebuglog_1
+#
+cat DIR/spool/log/serverdebuglog_2
+#
+no_msglog_check
diff --git a/test/scripts/0000-Basic/0575 b/test/scripts/0000-Basic/0575
new file mode 100644
index 000000000..e4534af9b
--- /dev/null
+++ b/test/scripts/0000-Basic/0575
@@ -0,0 +1,10 @@
+# -bh and msglog
+# no logfiles, says the docs
+exim -d -bh V4NET.0.0.0
+mail from:<x@y>
+rcpt to:<x@y>
+data
+Message.
+.
+quit
+****
diff --git a/test/scripts/0000-Basic/0576 b/test/scripts/0000-Basic/0576
new file mode 100644
index 000000000..6f01d9aae
--- /dev/null
+++ b/test/scripts/0000-Basic/0576
@@ -0,0 +1,65 @@
+# named queues
+# Exim test configuration 0576
+#
+no_msglog_check
+#
+exim -bs
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO: <normal@test.ex>
+DATA
+Subject: test
+
+foo
+.
+RSET
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO: <alternate@test.ex>
+DATA
+Subject: test
+
+foo
+.
+QUIT
+****
+#
+exim -qq
+****
+#
+exim -qGnosuchqueue
+****
+#
+exim -qGalternate
+****
+#
+#
+#
+exim -DSERVER=server -qGlowpri/3s
+****
+sleep 1
+exim -bs
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO: <lowpri@test.ex>
+DATA
+Subject: test
+
+foo
+.
+QUIT
+****
+sleep 3
+killdaemon
+#
+# third-party queue transfer
+exim -bs
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO: <alternate@test.ex>
+DATA
+Subject: test
+
+foo
+.
+QUIT
+****
+#
+sudo mv DIR/spool/alternate/input/* DIR/spool/input/
+exim -q
diff --git a/test/scripts/0000-Basic/0900 b/test/scripts/0000-Basic/0900
new file mode 100644
index 000000000..9e014c43e
--- /dev/null
+++ b/test/scripts/0000-Basic/0900
@@ -0,0 +1,219 @@
+# CHUNKING reception
+exim -DSERVER=server -bd -oX PORT_D
+****
+#
+# plain, small message (no body)
+client 127.0.0.1 PORT_D
+??? 220
+ehlo tester
+??? 250-
+??? 250-SIZE
+??? 250-8BITMIME
+??? 250-PIPELINING
+??? 250-CHUNKING
+??? 250 HELP
+mail from:someone@some.domain
+??? 250
+rcpt to:CALLER@test.ex
+??? 250
+bdat 88 last
+To: Susan@random.com
+From: Sam@random.com
+Subject: This is a bodyless test message
+
+??? 250-
+??? 250
+quit
+??? 221
+****
+#
+# plain, small message (with body)
+# nonlast 1st bdat, noop, last-bdat(0)
+# immediate followon 2nd message
+client 127.0.0.1 PORT_D
+??? 220
+ehlo tester
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250
+mail from:someone@some.domain
+??? 250
+rcpt to:CALLER@test.ex
+??? 250
+bdat 100
+To: Susan@random.com
+From: Sam@random.com
+Subject: This is a bodyfull test message
+
+1234567890
+??? 250
+noop
+??? 250
+bdat 0 last
+??? 250-
+??? 250
+mail from:someone@some.domain
+??? 250
+rcpt to:CALLER@test.ex
+??? 250
+bdat 10
+To: Susan@bdat 78 last
+??? 250
+random.com
+From: Sam@random.com
+Subject: This is a bodyless test message
+
+??? 250-
+??? 250
+quit
+??? 221
+****
+#
+# not enough data in chunk
+#
+client 127.0.0.1 PORT_D
+??? 220
+ehlo tester
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250
+mail from:someone@some.domain
+??? 250
+rcpt to:CALLER@test.ex
+??? 250
+bdat 89 last
+To: Susan@random.com
+From: Sam@random.com
+Subject: This is a bodyless test message
+
+??? 421
+****
+#
+# protocol failure cases
+#
+client 127.0.0.1 PORT_D
+??? 220
+ehlo tester
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250
+mail from:someone@some.domain
+??? 250
+rcpt to:CALLER@test.ex
+??? 250
+bdat 88
+To: Susan@random.com
+From: Sam@random.com
+Subject: This is a bodyless test message
+
+??? 250
+bdat 0
+??? 504
+quit
+??? 221
+****
+#
+# followon EHLO and another message
+client 127.0.0.1 PORT_D
+??? 220
+ehlo tester
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250
+mail from:someone@some.domain
+??? 250
+rcpt to:CALLER@test.ex
+??? 250
+bdat 88
+To: Susan@random.com
+From: Sam@random.com
+Subject: This is a bodyless test message
+
+??? 250
+data
+??? 503
+RSET
+??? 250
+EHLO tester
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250
+mail from:someone@some.domain
+??? 250
+rcpt to:CALLER@test.ex
+??? 250
+bdat 88
+To: Susan@random.com
+From: Sam@random.com
+Subject: This is a bodyless test message
+
+??? 250
+data
+??? 503
+data
+??? 503
+quit
+??? 221
+****
+#
+# plain, small message (no body)
+# pipelined
+client 127.0.0.1 PORT_D
+??? 220
+EHLO tester
+??? 250-
+??? 250-SIZE
+??? 250-8BITMIME
+??? 250-PIPELINING
+??? 250-CHUNKING
+??? 250 HELP
+MAIL FROM:<someone@some.domain>\r\nRCPT TO:<CALLER@test.ex>\r\nBDAT 88 LAST\r\nTo: Susan@random.com\r\nFrom: Sam@random.com\r\nSubject: This is a bodyless test message\r\n
+??? 250
+??? 250
+??? 250-
+??? 250
+quit
+??? 221
+****
+#
+# plain, longer message (xple chunks), RCPT rejected
+# pipelined
+client 127.0.0.1 PORT_D
+??? 220
+EHLO tester
+??? 250-
+??? 250-SIZE
+??? 250-8BITMIME
+??? 250-PIPELINING
+??? 250-CHUNKING
+??? 250 HELP
+MAIL FROM:<someone@some.domain>\r\nRCPT TO:<dummy@reject.ex>\r\nBDAT 86\r\nTo: Susan@random.com\r\nFrom: Sal@random.com\r\nSubject: This is a bodyless test message\r\nBDAT 6 LAST\r\nZZ\r\n
+??? 250
+??? 550
+??? 503-
+??? 503-
+??? 503
+??? 503-
+??? 503-
+??? 503
+quit
+??? 221
+****
+#
+killdaemon
+no_msglog_check
diff --git a/test/scripts/0000-Basic/0901 b/test/scripts/0000-Basic/0901
new file mode 100644
index 000000000..2157e61a8
--- /dev/null
+++ b/test/scripts/0000-Basic/0901
@@ -0,0 +1,387 @@
+# CHUNKING transmission, short messages
+#
+# Start with non-pipelined cases
+#
+# Basic short message
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250 CHUNKING
+MAIL FROM
+250 OK
+RCPT TO
+250 OK
+BDAT 329 LAST
+*data 329
+250 OK
+QUIT
+225 OK
+*eof
+****
+sudo exim -odf -bS
+EHLO test
+MAIL FROM:<sender@source.dom>
+RCPT TO:<a@test.ex>
+DATA
+Subject: foo
+
+data
+.
+QUIT
+****
+#
+# Error case: server wrongly expected more data, client gets timeout for data-ack
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250 CHUNKING
+MAIL FROM
+250 good mail cmd
+RCPT TO
+250 acceptable rcpt cmd
+BDAT 329 LAST
+*data 330
+250 OK got that data
+QUIT
+225 OK quitting
+****
+sudo exim -odf -bS
+EHLO test
+MAIL FROM:<sender@source.dom>
+RCPT TO:<b@test.ex>
+DATA
+Subject: foo
+
+data
+.
+QUIT
+****
+#
+# Error case: server wrongly expected less data
+# client get the data-ack, sends quit - but server
+# sees a munged quit due to the outstanding data tail
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250 CHUNKING
+MAIL FROM
+250 OK
+RCPT TO
+250 OK
+BDAT 329 LAST
+*data 328
+250 OK
+QUIT
+225 OK
+****
+sudo exim -odf -bS
+EHLO test
+MAIL FROM:<sender@source.dom>
+RCPT TO:<c@test.ex>
+DATA
+Subject: foo
+
+data
+.
+QUIT
+****
+#
+# server rejects BDAT cmd
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250 CHUNKING
+MAIL FROM
+250 OK
+RCPT TO
+250 OK
+BDAT 329 LAST
+*data 329
+500 oops
+QUIT
+225 OK
+****
+sudo exim -odf -bS
+EHLO test
+MAIL FROM:<sender@source.dom>
+RCPT TO:<d@test.ex>
+DATA
+Subject: foo
+
+data
+.
+QUIT
+****
+#
+# server tmp-rejects BDAT cmd
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250 CHUNKING
+MAIL FROM
+250 OK
+RCPT TO
+250 OK
+BDAT 329 LAST
+*data 329
+400 not right now
+QUIT
+225 OK
+****
+sudo exim -odf -bS
+EHLO test
+MAIL FROM:<sender@source.dom>
+RCPT TO:<e@test.ex>
+DATA
+Subject: foo
+
+data
+.
+QUIT
+****
+#
+#
+###################################################
+#
+# Pipelined cases
+#
+# Basic short message
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250-PIPELINING
+250 CHUNKING
+MAIL FROM
+RCPT TO
+BDAT 329 LAST
+*data 329
+250 OK mail
+250 OK rcpt
+250 OK bdat
+QUIT
+225 OK
+*eof
+****
+sudo exim -odf -bS
+EHLO test
+MAIL FROM:<sender@source.dom>
+RCPT TO:<p@test.ex>
+DATA
+Subject: foo
+
+data
+.
+QUIT
+****
+#
+# Error case: server wrongly expected more data, client gets timeout for data-ack
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250-PIPELINING
+250 CHUNKING
+MAIL FROM
+RCPT TO
+BDAT 329 LAST
+*data 330
+250 good mail cmd
+****
+sudo exim -odf -bS
+EHLO test
+MAIL FROM:<sender@source.dom>
+RCPT TO:<q@test.ex>
+DATA
+Subject: foo
+
+data
+.
+QUIT
+****
+#
+# Error case: server wrongly expected less data
+# client get the data-ack, sends quit - but server
+# sees a munged quit due to the outstanding data tail
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250-PIPELINING
+250 CHUNKING
+MAIL FROM
+RCPT TO
+BDAT 329 LAST
+*data 328
+250 OK mail
+250 OK rcpt
+250 OK bdat
+QUIT
+225 OK
+****
+sudo exim -odf -bS
+EHLO test
+MAIL FROM:<sender@source.dom>
+RCPT TO:<r@test.ex>
+DATA
+Subject: foo
+
+data
+.
+QUIT
+****
+#
+# server rejects MAIL cmd
+# transport coding does not handle the possible RSET-and-another transaction,
+# but always QUITs
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250-PIPELINING
+250 CHUNKING
+MAIL FROM
+RCPT TO
+BDAT 329 LAST
+*data 329
+550 unacceptable mail-from
+550 rcpt ungood lacking mail-from
+500 bdat ungood lacking mail-from
+QUIT
+225 OK
+****
+sudo exim -odf -bS
+EHLO test
+MAIL FROM:<sender@source.dom>
+RCPT TO:<s@test.ex>
+DATA
+Subject: foo
+
+data
+.
+QUIT
+****
+#
+# server tmp-rejects MAIL cmd
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250-PIPELINING
+250 CHUNKING
+MAIL FROM
+RCPT TO
+BDAT 330 LAST
+*data 330
+450 greylisted mail-from
+550 rcpt ungood lacking mail-from
+500 bdat ungood lacking mail-from
+QUIT
+225 OK
+****
+sudo exim -odf -bS
+EHLO test
+MAIL FROM:<sender@source.dom>
+RCPT TO:<s1@test.ex>
+DATA
+Subject: foo
+
+data
+.
+QUIT
+****
+#
+# server rejects RCPT cmd
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250-PIPELINING
+250 CHUNKING
+MAIL FROM
+RCPT TO
+BDAT 329 LAST
+*data 329
+250 OK mail
+550 no such recipient
+500 oops bdat
+QUIT
+225 OK
+****
+sudo exim -odf -bS
+EHLO test
+MAIL FROM:<sender@source.dom>
+RCPT TO:<t@test.ex>
+DATA
+Subject: foo
+
+data
+.
+QUIT
+****
+#
+# server rejects BDAT cmd
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250-PIPELINING
+250 CHUNKING
+MAIL FROM
+RCPT TO
+BDAT 329 LAST
+*data 329
+250 OK mail
+250 OK rcpt
+500 oops bdat
+QUIT
+225 OK
+****
+sudo exim -odf -bS
+EHLO test
+MAIL FROM:<sender@source.dom>
+RCPT TO:<u@test.ex>
+DATA
+Subject: foo
+
+data
+.
+QUIT
+****
+#
+# server tmp-rejects BDAT cmd
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250-PIPELINING
+250 CHUNKING
+MAIL FROM
+RCPT TO
+BDAT 329 LAST
+*data 329
+250 OK mail
+250 OK rcpt
+400 not right now bdat
+QUIT
+225 OK
+****
+sudo exim -odf -bS
+EHLO test
+MAIL FROM:<sender@source.dom>
+RCPT TO:<v@test.ex>
+DATA
+Subject: foo
+
+data
+.
+QUIT
+****
+#
+#
+no_msglog_check
diff --git a/test/scripts/0000-Basic/0902 b/test/scripts/0000-Basic/0902
new file mode 100644
index 000000000..5be294087
--- /dev/null
+++ b/test/scripts/0000-Basic/0902
@@ -0,0 +1,1100 @@
+# CHUNKING transmission, long messages
+#
+# Start with non-pipelined cases
+#
+# Basic long message
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250 CHUNKING
+MAIL FROM
+250 OK
+RCPT TO
+250 OK
+BDAT 295
+*data 295
+250 OK nonlast bdat
+BDAT 8380 LAST
+*data 8380
+250 OK bdat
+QUIT
+225 OK
+*eof
+****
+sudo exim -odf -bS
+EHLO
+MAIL FROM:<sender@dom>
+RCPT TO:<a@test.ex>
+DATA
+Subject: foo
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+.
+QUIT
+****
+#
+#
+# server rejects BDAT cmd
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250 CHUNKING
+MAIL FROM
+250 OK
+RCPT TO
+250 OK
+BDAT 295
+*data 295
+500 oops bdat-nonlast
+QUIT
+225 OK
+****
+sudo exim -odf -bS
+EHLO
+MAIL FROM:<sender@dom>
+RCPT TO:<d@test.ex>
+DATA
+Subject: foo
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+.
+QUIT
+****
+#
+#
+###################################################
+#
+# Pipelined cases
+#
+# Basic long message
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250-PIPELINING
+250 CHUNKING
+MAIL FROM
+RCPT TO
+BDAT 295
+250 OK mail
+250 OK rcpt
+*data 295
+250 OK nonlast bdat
+BDAT 8380 LAST
+*data 8380
+250 OK bdat
+QUIT
+225 OK
+*eof
+****
+sudo exim -odf -bS
+EHLO
+MAIL FROM:<sender@dom>
+RCPT TO:<p@test.ex>
+DATA
+Subject: foo
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+.
+QUIT
+****
+#
+# server rejects MAIL cmd
+# transport coding does not handle the possible RSET-and-another transaction,
+# but always QUITs
+#
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250-PIPELINING
+250 CHUNKING
+MAIL FROM
+RCPT TO
+BDAT 295
+*data 295
+550 unacceptable mail-from
+550 rcpt ungood lacking mail-from
+500 bdat (nonlast) ungood lacking mail-from
+QUIT
+225 OK
+****
+sudo exim -odf -bS
+EHLO
+MAIL FROM:<sender@dom>
+RCPT TO:<s@test.ex>
+DATA
+Subject: foo
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+.
+QUIT
+****
+#
+# server rejects RCPT cmd
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250-PIPELINING
+250 CHUNKING
+MAIL FROM
+RCPT TO
+BDAT 295
+*data 295
+250 OK mail
+550 no such recipient
+500 oops nonlast bdat - no rcpt
+QUIT
+225 OK
+****
+sudo exim -odf -bS
+EHLO
+MAIL FROM:<sender@dom>
+RCPT TO:<t@test.ex>
+DATA
+Subject: foo
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+.
+QUIT
+****
+#
+# server rejects 1st RCPT cmd of two
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250-PIPELINING
+250 CHUNKING
+MAIL FROM
+RCPT TO
+RCPT TO
+BDAT 279
+*data 279
+250 OK mail
+550 no such recipient
+250 good recipient
+200 OK nonlast bdat
+BDAT 8380 LAST
+*data 8380
+250 OK bdat
+QUIT
+225 OK
+****
+sudo exim -odf -bS
+EHLO
+MAIL FROM:<sender@dom>
+RCPT TO:<t1@test.ex>
+RCPT TO:<t2@test.ex>
+DATA
+Subject: foo
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+.
+QUIT
+****
+#
+# server rejects initial BDAT cmd
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250-PIPELINING
+250 CHUNKING
+MAIL FROM
+RCPT TO
+BDAT 295
+*data 295
+250 OK mail
+250 OK rcpt
+500 oops nonlast bdat
+QUIT
+225 OK
+****
+sudo exim -odf -bS
+EHLO
+MAIL FROM:<sender@dom>
+RCPT TO:<u@test.ex>
+DATA
+Subject: foo
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+.
+QUIT
+****
+#
+# server rejects final BDAT cmd
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250-PIPELINING
+250 CHUNKING
+MAIL FROM
+RCPT TO
+BDAT 295
+*data 295
+250 OK mail
+250 OK rcpt
+250 OK nonlast bdat
+BDAT 8380 LAST
+*data 8380
+500 oops bdat
+QUIT
+225 OK
+****
+sudo exim -odf -bS
+EHLO
+MAIL FROM:<sender@dom>
+RCPT TO:<v@test.ex>
+DATA
+Subject: foo
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+.
+QUIT
+****
+#
+# message with long headers
+server PORT_S
+220 Greetings
+EHLO
+250-Hello there
+250-PIPELINING
+250 CHUNKING
+MAIL FROM
+RCPT TO
+BDAT 8191
+250 OK mail
+250 OK rcpt
+*data 8191
+250 OK nonlast bdat
+BDAT 807 LAST
+*data 807
+250 OK bdat
+QUIT
+225 OK
+*eof
+****
+sudo exim -odf -bS
+EHLO
+MAIL FROM:<sender@dom>
+RCPT TO:<p@test.ex>
+DATA
+Subject: foo
+X-long_hdr: 0
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 2
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 3
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 4
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 5
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 6
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 7
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 8
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+ 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+
+body
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
+.
+QUIT
+****
+#
+#
+no_msglog_check
diff --git a/test/scripts/2000-GnuTLS/2000 b/test/scripts/2000-GnuTLS/2000
index a1299e574..8717892f2 100644
--- a/test/scripts/2000-GnuTLS/2000
+++ b/test/scripts/2000-GnuTLS/2000
@@ -13,3 +13,16 @@ exim -qf
****
killdaemon
no_msglog_check
+#
+#
+exim -be
+sha256: ${sha256:}
+sha256: ${sha256:abc}
+
+sha3: ${sha3:}
+sha3: ${sha3:abc}
+sha3_256: ${sha3_256:}
+sha3_256: ${sha3_256:abc}
+sha3_512: ${sha3_512:}
+sha3_512: ${sha3_512:abc}
+****
diff --git a/test/scripts/2000-GnuTLS/2013 b/test/scripts/2000-GnuTLS/2013
index f3d5719f0..24c2c58fc 100644
--- a/test/scripts/2000-GnuTLS/2013
+++ b/test/scripts/2000-GnuTLS/2013
@@ -5,7 +5,7 @@ exim -DSERVER=server -bd -oX PORT_D
exim userx@test.ex
Test message 1
****
-exim userx@test.ex
+exim usery@test.ex
Test message 2
****
exim -qqf -d-all+acl
diff --git a/test/scripts/2000-GnuTLS/2015 b/test/scripts/2000-GnuTLS/2015
index 140af797f..b963e4e06 100644
--- a/test/scripts/2000-GnuTLS/2015
+++ b/test/scripts/2000-GnuTLS/2015
@@ -1,4 +1,4 @@
-# TLS server: timeout after accepting STARTTLS
+# TLS server: timeout or close after accepting STARTTLS
gnutls
exim -DSERVER=server -bd -oX PORT_D
****
@@ -16,4 +16,16 @@ starttls_wait
+++ 2
??? 421
****
+client-gnutls 127.0.0.1 PORT_D
+??? 220
+ehlo rhu.barb
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250
+starttls_wait
+??? 220
+****
killdaemon
diff --git a/test/scripts/2000-GnuTLS/2020 b/test/scripts/2000-GnuTLS/2020
index bd00740bf..3203ab4ea 100644
--- a/test/scripts/2000-GnuTLS/2020
+++ b/test/scripts/2000-GnuTLS/2020
@@ -1,4 +1,4 @@
-# TLS server: no certificate defined, client sends in clear
+# TLS server: no certificate defined, autogen selfsign used
gnutls
exim -DSERVER=server -bd -oX PORT_D
****
diff --git a/test/scripts/2000-GnuTLS/2034 b/test/scripts/2000-GnuTLS/2034
new file mode 100644
index 000000000..b03c60d93
--- /dev/null
+++ b/test/scripts/2000-GnuTLS/2034
@@ -0,0 +1,34 @@
+# TLS server: error in TLS session startup
+gnutls
+exim -DSERVER=server -bd -oX PORT_D
+****
+# timeout case
+client 127.0.0.1 PORT_D
+??? 220
+ehlo rhu.barb
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250
+starttls
+??? 220
++++ 3
+****
+#
+# bad TLS negotiation case
+client 127.0.0.1 PORT_D
+??? 220
+ehlo rhu.barb
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250
+starttls
+??? 220
+bogus
+****
+killdaemon
diff --git a/test/scripts/2000-GnuTLS/2051 b/test/scripts/2000-GnuTLS/2051
new file mode 120000
index 000000000..ac5066b61
--- /dev/null
+++ b/test/scripts/2000-GnuTLS/2051
@@ -0,0 +1 @@
+../2100-OpenSSL/2151 \ No newline at end of file
diff --git a/test/scripts/2000-GnuTLS/2052 b/test/scripts/2000-GnuTLS/2052
new file mode 100644
index 000000000..fa76b4849
--- /dev/null
+++ b/test/scripts/2000-GnuTLS/2052
@@ -0,0 +1,22 @@
+# TLS client: TLS setup fails - retry in clear (with fastopen)
+#
+# If all works you'll not see any difference. To enable in the
+# kernel, 'sudo sh -c "echo 3 > /proc/sys/net/ipv4/tcp_fastopen"'.
+# A packet capture on the loopback interface will show the TFU
+# option on the SYN, but the fast-output SMTP banner will not
+# be seen unless you also deliberately emulate a long path:
+# 'sudo tc qdisc add dev lo root netem delay 100ms'
+#
+# If the client-side is disabled in the kernel, Exim logs
+# will become noisy.
+#
+gnutls
+exim -DSERVER=server -bd -oX PORT_D
+****
+exim CALLER@test.ex
+Testing
+****
+exim -qf
+****
+killdaemon
+no_msglog_check
diff --git a/test/scripts/2000-GnuTLS/2090 b/test/scripts/2000-GnuTLS/2090
new file mode 100644
index 000000000..278f03429
--- /dev/null
+++ b/test/scripts/2000-GnuTLS/2090
@@ -0,0 +1,78 @@
+# TLS server, CHUNKING reception
+gnutls
+exim -DSERVER=server -DSRV=tls -bd -oX PORT_D
+****
+#
+# non-piplined
+client-gnutls 127.0.0.1 PORT_D
+??? 220
+EHLO rhu.barb
+??? 250-
+??? 250-SIZE
+??? 250-8BITMIME
+??? 250-PIPELINING
+??? 250-CHUNKING
+??? 250-STARTTLS
+??? 250 HELP
+STARTTLS
+??? 220
+EHLO rhu.barb
+??? 250-
+??? 250-SIZE
+??? 250-8BITMIME
+??? 250-PIPELINING
+??? 250-CHUNKING
+??? 250 HELP
+MAIL FROM:<someone@some.domain>
+??? 250
+RCPT TO:<CALLER@test.ex>
+??? 250
+BDAT 88 LAST
+To: Susan@random.com
+From: Sam@random.com
+Subject: This is a bodyless test message
+
+??? 250-
+??? 250
+QUIT
+??? 221
+****
+#
+# pipelined
+client-gnutls 127.0.0.1 PORT_D
+??? 220
+EHLO rhu.barb
+??? 250-
+??? 250-SIZE
+??? 250-8BITMIME
+??? 250-PIPELINING
+??? 250-CHUNKING
+??? 250-STARTTLS
+??? 250 HELP
+STARTTLS
+??? 220
+EHLO rhu.barb
+??? 250-
+??? 250-SIZE
+??? 250-8BITMIME
+??? 250-PIPELINING
+??? 250-CHUNKING
+??? 250 HELP
+MAIL FROM:<someone@some.domain>
+RCPT TO:<CALLER@test.ex>
+BDAT 88 LAST
+To: Susan@random.com
+From: Sam@random.com
+Subject: This is a bodyless test message
+
+??? 250
+??? 250
+??? 250-
+??? 250
+QUIT
+??? 221
+****
+#
+#
+killdaemon
+no_msglog_check
diff --git a/test/scripts/2000-GnuTLS/2091 b/test/scripts/2000-GnuTLS/2091
new file mode 100644
index 000000000..58e5163c5
--- /dev/null
+++ b/test/scripts/2000-GnuTLS/2091
@@ -0,0 +1,9 @@
+# TLS client, CHUNKING transmission
+gnutls
+exim -DSERVER=server -DSRV=tls -bd -oX PORT_S
+****
+exim -oMt this-user -f this-user -odf other-user@test.ex
+Test message. Contains FF: ÿ
+****
+killdaemon
+no_msglog_check
diff --git a/test/scripts/2100-OpenSSL/2100 b/test/scripts/2100-OpenSSL/2100
index c2b0f8981..27c6c84d6 100644
--- a/test/scripts/2100-OpenSSL/2100
+++ b/test/scripts/2100-OpenSSL/2100
@@ -8,3 +8,9 @@ exim -qf
****
killdaemon
no_msglog_check
+#
+#
+exim -be
+sha256: ${sha256:}
+sha256: ${sha256:abc}
+****
diff --git a/test/scripts/2100-OpenSSL/2120 b/test/scripts/2100-OpenSSL/2120
index 7e0aa1e0e..53cd81333 100644
--- a/test/scripts/2100-OpenSSL/2120
+++ b/test/scripts/2100-OpenSSL/2120
@@ -1,4 +1,4 @@
-# TLS server: no certificate defined, client sends in clear
+# TLS server: no certificate defined, autogen selfsign used
exim -DSERVER=server -bd -oX PORT_D
****
exim userx
diff --git a/test/scripts/2100-OpenSSL/2130 b/test/scripts/2100-OpenSSL/2130
index 1de3e4f40..afaa949e0 100644
--- a/test/scripts/2100-OpenSSL/2130
+++ b/test/scripts/2100-OpenSSL/2130
@@ -1,4 +1,4 @@
-# TLS: SNI
+# TLS: client SNI
#
exim -DSERVER=server -bd -oX PORT_D
****
diff --git a/test/scripts/2100-OpenSSL/2151 b/test/scripts/2100-OpenSSL/2151
new file mode 100644
index 000000000..19dfc6479
--- /dev/null
+++ b/test/scripts/2100-OpenSSL/2151
@@ -0,0 +1,34 @@
+# TLS client: recipient callout - TLS fail, retry in clear
+need_ipv4
+#
+server PORT_S 2
+220 Server ready
+EHLO
+250-wotcher mate
+250-STARTTLS
+250 OK
+STARTTLS
+250
+.
+220 Server ready
+EHLO
+250-wotcher mate
+250-STARTTLS
+250 OK
+MAIL FROM
+250 OK
+RCPT TO
+250 OK
+QUIT
+250 OK
+****
+exim -odq -bs
+ehlo xxxx
+mail from: s1@test.ex
+rcpt to: r1@test.ex
+data
+.
+quit
+****
+no_stdout_check
+no_msglog_check
diff --git a/test/scripts/2100-OpenSSL/2152 b/test/scripts/2100-OpenSSL/2152
new file mode 100644
index 000000000..329e42051
--- /dev/null
+++ b/test/scripts/2100-OpenSSL/2152
@@ -0,0 +1,21 @@
+# TLS client: TLS setup fails - retry in clear (with fastopen)
+#
+# If all works you'll not see any difference. To enable in the
+# kernel, 'sudo sh -c "echo 3 > /proc/sys/net/ipv4/tcp_fastopen"'.
+# A packet capture on the loopback interface will show the TFU
+# option on the SYN, but the fast-output SMTP banner will not
+# be seen unless you also deliberately emulate a long path:
+# 'sudo tc qdisc add dev lo root netem delay 100ms'
+#
+# If the client-side is disabled in the kernel, Exim logs
+# will become noisy.
+#
+exim -DSERVER=server -bd -oX PORT_D
+****
+exim CALLER@test.ex
+Testing
+****
+exim -qf
+****
+killdaemon
+no_msglog_check
diff --git a/test/scripts/2100-OpenSSL/2190 b/test/scripts/2100-OpenSSL/2190
new file mode 100644
index 000000000..54095d49a
--- /dev/null
+++ b/test/scripts/2100-OpenSSL/2190
@@ -0,0 +1,77 @@
+# TLS server, CHUNKING reception
+exim -DSERVER=server -DSRV=tls -bd -oX PORT_D
+****
+#
+# non-piplined
+client-ssl 127.0.0.1 PORT_D
+??? 220
+EHLO rhu.barb
+??? 250-
+??? 250-SIZE
+??? 250-8BITMIME
+??? 250-PIPELINING
+??? 250-CHUNKING
+??? 250-STARTTLS
+??? 250 HELP
+STARTTLS
+??? 220
+EHLO rhu.barb
+??? 250-
+??? 250-SIZE
+??? 250-8BITMIME
+??? 250-PIPELINING
+??? 250-CHUNKING
+??? 250 HELP
+MAIL FROM:<someone@some.domain>
+??? 250
+RCPT TO:<CALLER@test.ex>
+??? 250
+BDAT 88 LAST
+To: Susan@random.com
+From: Sam@random.com
+Subject: This is a bodyless test message
+
+??? 250-
+??? 250
+QUIT
+??? 221
+****
+#
+# pipelined
+client-ssl 127.0.0.1 PORT_D
+??? 220
+EHLO rhu.barb
+??? 250-
+??? 250-SIZE
+??? 250-8BITMIME
+??? 250-PIPELINING
+??? 250-CHUNKING
+??? 250-STARTTLS
+??? 250 HELP
+STARTTLS
+??? 220
+EHLO rhu.barb
+??? 250-
+??? 250-SIZE
+??? 250-8BITMIME
+??? 250-PIPELINING
+??? 250-CHUNKING
+??? 250 HELP
+MAIL FROM:<someone@some.domain>
+RCPT TO:<CALLER@test.ex>
+BDAT 88 LAST
+To: Susan@random.com
+From: Sam@random.com
+Subject: This is a bodyless test message
+
+??? 250
+??? 250
+??? 250-
+??? 250
+QUIT
+??? 221
+****
+#
+#
+killdaemon
+no_msglog_check
diff --git a/test/scripts/2100-OpenSSL/2191 b/test/scripts/2100-OpenSSL/2191
new file mode 100644
index 000000000..86963f747
--- /dev/null
+++ b/test/scripts/2100-OpenSSL/2191
@@ -0,0 +1,8 @@
+# TLS client, CHUNKING transmission
+exim -DSERVER=server -DSRV=tls -bd -oX PORT_S
+****
+exim -oMt this-user -f this-user -odf other-user@test.ex
+Test message. Contains FF: ÿ
+****
+killdaemon
+no_msglog_check
diff --git a/test/scripts/2800-lmdb/2800 b/test/scripts/2800-lmdb/2800
new file mode 100644
index 000000000..a074ae628
--- /dev/null
+++ b/test/scripts/2800-lmdb/2800
@@ -0,0 +1,11 @@
+# lmdb lookup
+exim -be
+${lookup{first}lmdb{DIR/aux-fixed/TESTNUM.mdb}}
+${lookup{first}lmdb{DIR/aux-fixed/TESTNUM.mdb}{$value}fail}
+${lookup{fail}lmdb{DIR/aux-fixed/TESTNUM.mdb}{$value}{failure value}}
+${lookup{fail}lmdb{DIR/aux-fixed/TESTNUM.mdb}{$value}fail}
+${lookup{second}lmdb{DIR/aux-fixed/TESTNUM.mdb}{$value}fail}
+${extract{A}{${lookup{second}lmdb{DIR/aux-fixed/TESTNUM.mdb}{$value}fail}}}
+${extract{B}{${lookup{second}lmdb{DIR/aux-fixed/TESTNUM.mdb}{$value}fail}}}
+${extract{C}{${lookup{second}lmdb{DIR/aux-fixed/TESTNUM.mdb}{$value}fail}}{$value}fail}
+****
diff --git a/test/scripts/2800-lmdb/REQUIRES b/test/scripts/2800-lmdb/REQUIRES
new file mode 100644
index 000000000..c160c4640
--- /dev/null
+++ b/test/scripts/2800-lmdb/REQUIRES
@@ -0,0 +1 @@
+lookup lmdb
diff --git a/test/scripts/3000-Perl/3001 b/test/scripts/3000-Perl/3001
index 87b32e7cf..c49a5f352 100644
--- a/test/scripts/3000-Perl/3001
+++ b/test/scripts/3000-Perl/3001
@@ -1,3 +1,13 @@
-# Perl w/o taintmode
-exim -be '${perl{taint_flag}}'
+# Environment
+# settings
+FOO=foo FOO1=foo1 FOO2=foo2 BAR=bar BAR1=bar1 BAR2=bar2 exim -bP keep_environment add_environment
****
+# result via -bP environment
+FOO=foo FOO1=foo1 FOO2=foo2 BAR=bar BAR1=bar1 BAR2=bar2 exim -bP environment
+****
+# result via -n -bP environment
+FOO=foo FOO1=foo1 FOO2=foo2 BAR=bar BAR1=bar1 BAR2=bar2 exim -n -bP environment
+****
+# result via perl_at_start
+FOO=foo FOO1=foo1 FOO2=foo2 BAR=bar BAR1=bar1 BAR2=bar2 exim -ps -be ''
+***
diff --git a/test/scripts/3000-Perl/3011 b/test/scripts/3000-Perl/3011
new file mode 100644
index 000000000..87b32e7cf
--- /dev/null
+++ b/test/scripts/3000-Perl/3011
@@ -0,0 +1,3 @@
+# Perl w/o taintmode
+exim -be '${perl{taint_flag}}'
+****
diff --git a/test/scripts/3000-Perl/3012 b/test/scripts/3000-Perl/3012
new file mode 120000
index 000000000..3ae81fbb2
--- /dev/null
+++ b/test/scripts/3000-Perl/3012
@@ -0,0 +1 @@
+3011 \ No newline at end of file
diff --git a/test/scripts/3400-plaintext/3414 b/test/scripts/3400-plaintext/3414
index 37528f2ea..edd3a011f 100644
--- a/test/scripts/3400-plaintext/3414
+++ b/test/scripts/3400-plaintext/3414
@@ -1,5 +1,5 @@
# control of AUTH= on MAIL by ACL
-exim -DS=# -bs
+exim -DOPT=# -bs
ehlo xxxx
mail from:<a@b> auth=c@d
quit
@@ -15,7 +15,7 @@ mail from:<a@b> auth=c@d
quit
****
# No acl_smtp_mailauth, but authenticated
-exim -DS=# -bs
+exim -DOPT=# -bs
ehlo xxxx
auth plain abcd
mail from:<a@b> auth=c@d
diff --git a/test/scripts/4000-scanning/4008 b/test/scripts/4000-scanning/4008
index 703a7c2aa..e5a7c9492 100644
--- a/test/scripts/4000-scanning/4008
+++ b/test/scripts/4000-scanning/4008
@@ -5,23 +5,23 @@
munge scanfile_size
#
server 11333
-<CHECK RSPAMC/1.3
-<Content-length:
-<Queue-Id:
-<From:
-<Recipient-Number: 1
-<Rcpt:
+<CHECK RSPAMC/1.3
+<Content-length:
+<Queue-Id:
+<From:
+<Recipient-Number: 1
+<Rcpt:
<Helo:
<User:
-<
-<From
+<
+<From
<X-Envelope-From
<X-Envelope-To
-<Received:
-< by
+<Received:
+< by
< (envelope
-< id
-< for
+< id
+< for
<From:
<Content-type: text/plain
<Message-Id:
@@ -29,12 +29,12 @@ server 11333
<Date:
<
<test
->RSPAMD/1.3 0 EX_OK
->Metric: default; True; 15.00 / 15.00 / 0.0
->Action: reject
->Symbol: FAKE_SYMBOL_A(15.00)
->Symbol: FAKE_SYMBOL_B(0.00)
->Message-ID: undef
+>RSPAMD/1.3 0 EX_OK
+>Metric: default; True; 15.00 / 15.00 / 0.0
+>Action: reject
+>Symbol: FAKE_SYMBOL_A(15.00)
+>Symbol: FAKE_SYMBOL_B(0.00)
+>Message-ID: undef
*eof
****
exim -odi -bs
diff --git a/test/scripts/4000-scanning/4009 b/test/scripts/4000-scanning/4009
index 0fb96ac16..d9849c341 100644
--- a/test/scripts/4000-scanning/4009
+++ b/test/scripts/4000-scanning/4009
@@ -12,14 +12,14 @@ server 7833
<User:
<Content-length:
<
-<From
+<From
<X-Envelope-From
<X-Envelope-To
-<Received:
-< by
+<Received:
+< by
< (envelope
-< id
-< for
+< id
+< for
<Content-type: text/plain
<Message-Id:
<From:
@@ -35,7 +35,7 @@ server 7833
>similar future email. If you have any questions, see
>@@CONTACT_ADDRESS@@ for details.
>
->Content preview: test [...]
+>Content preview: test [...]
>
>Content analysis details: (4.5 points, 5.0 required)
>
@@ -50,9 +50,9 @@ server 7833
>
*eof
****
-exim -odi -bs
+exim -odi -oMt fromuser -bs
ehlo test.ex
-mail from:<>
+mail from:<fromuser@myhost.test.ex>
rcpt to:<userx@test.ex>
data
Content-type: text/plain
@@ -72,14 +72,14 @@ server 7833
<User:
<Content-length:
<
-<From
+<From
<X-Envelope-From
<X-Envelope-To
-<Received:
-< by
+<Received:
+< by
< (envelope
-< id
-< for
+< id
+< for
<Content-type: text/plain
<Message-Id:
<From:
@@ -95,7 +95,7 @@ server 7833
>similar future email. If you have any questions, see
>@@CONTACT_ADDRESS@@ for details.
>
->Content preview: test [...]
+>Content preview: test [...]
>
>Content analysis details: (4.5 points, 5.0 required)
>
@@ -110,9 +110,9 @@ server 7833
>
*eof
****
-exim -odi -bs -DOPT='127.0.0.1 7833 retry=10s'
+exim -odi -oMt fromuser -bs -DOPT='127.0.0.1 7833 retry=10s'
ehlo test.ex
-mail from:<>
+mail from:<fromuser@myhost.test.ex>
rcpt to:<userx@test.ex>
data
Content-type: text/plain
@@ -130,14 +130,14 @@ server -i 2 7833
<User:
<Content-length:
<
-<From
+<From
<X-Envelope-From
<X-Envelope-To
-<Received:
-< by
+<Received:
+< by
< (envelope
-< id
-< for
+< id
+< for
<Content-type: text/plain
<Message-Id:
<From:
@@ -153,7 +153,7 @@ server -i 2 7833
>similar future email. If you have any questions, see
>@@CONTACT_ADDRESS@@ for details.
>
->Content preview: test [...]
+>Content preview: test [...]
>
>Content analysis details: (4.5 points, 5.0 required)
>
@@ -168,9 +168,9 @@ server -i 2 7833
>
*eof
****
-exim -odi -bs -DOPT='127.0.0.1 7833 retry=4s'
+exim -odi -oMt fromuser -bs -DOPT='127.0.0.1 7833 retry=4s'
ehlo test.ex
-mail from:<>
+mail from:<fromuser@myhost.test.ex>
rcpt to:<userx@test.ex>
data
Content-type: text/plain
@@ -189,14 +189,14 @@ server 7833
<User:
<Content-length:
<
-<From
+<From
<X-Envelope-From
<X-Envelope-To
-<Received:
-< by
+<Received:
+< by
< (envelope
-< id
-< for
+< id
+< for
<Content-type: text/plain
<Message-Id:
<From:
@@ -212,7 +212,7 @@ server 7833
>similar future email. If you have any questions, see
>@@CONTACT_ADDRESS@@ for details.
>
->Content preview: test [...]
+>Content preview: test [...]
>
>Content analysis details: (4.5 points, 5.0 required)
>
@@ -227,9 +227,9 @@ server 7833
>
*eof
****
-exim -odi -bs -DOPT='<; 127.0.0.1 7833 ; 127.0.0.2 7834 pri=2 tmo=2s'
+exim -odi -oMt fromuser -bs -DOPT='<; 127.0.0.1 7833 ; HOSTIPV4 7834 pri=2 tmo=2s'
ehlo test.ex
-mail from:<>
+mail from:<fromuser@myhost.test.ex>
rcpt to:<userx@test.ex>
data
Content-type: text/plain
diff --git a/test/scripts/4015-scan-ipv6/4015 b/test/scripts/4015-scan-ipv6/4015
index 66db933e6..9e4a857be 100644
--- a/test/scripts/4015-scan-ipv6/4015
+++ b/test/scripts/4015-scan-ipv6/4015
@@ -7,14 +7,14 @@ server 7833
<User:
<Content-length:
<
-<From
+<From
<X-Envelope-From
<X-Envelope-To
-<Received:
-< by
+<Received:
+< by
< (envelope
-< id
-< for
+< id
+< for
<Content-type: text/plain
<Message-Id:
<From:
@@ -30,7 +30,7 @@ server 7833
>similar future email. If you have any questions, see
>@@CONTACT_ADDRESS@@ for details.
>
->Content preview: test [...]
+>Content preview: test [...]
>
>Content analysis details: (4.5 points, 5.0 required)
>
@@ -45,9 +45,10 @@ server 7833
>
*eof
****
-exim -odi -bs -DOPT='<; 127.0.0.1 7833 ; ::1 7834 pri=2 tmo=2s'
+# need to trust CALLER to -oMt
+exim -odi -oMt fromuser -bs -DOPT='<; 127.0.0.1 7833 ; ::1 7834 pri=2 tmo=2s'
ehlo test.ex
-mail from:<>
+mail from:<fromuser@myhost.test.ex>
rcpt to:<userx@test.ex>
data
Content-type: text/plain
diff --git a/test/scripts/4500-Domain-Keys-Identified-Mail/4503 b/test/scripts/4500-Domain-Keys-Identified-Mail/4503
index 45be7c2c6..140e6d6bf 100644
--- a/test/scripts/4500-Domain-Keys-Identified-Mail/4503
+++ b/test/scripts/4500-Domain-Keys-Identified-Mail/4503
@@ -4,21 +4,22 @@ exim -bd -DSERVER=server -oX PORT_D
****
#
# single header signed
-exim -DOPT=From a@test.ex
+exim -DOPT=From -odf a@test.ex
From: nobody@example.com
+From: second@example.com
content
****
#
# single header, oversigned
-exim -DOPT=From:From b@test.ex
+exim -DOPT=From:From -odf b@test.ex
From: nobody@example.com
content
****
#
# default header set
-exim -DHEADERS_MAXSIZE=y c@test.ex
+exim -DHEADERS_MAXSIZE=y -odf c@test.ex
From: nobody@example.com
content
diff --git a/test/scripts/4500-Domain-Keys-Identified-Mail/4509 b/test/scripts/4500-Domain-Keys-Identified-Mail/4509
new file mode 100644
index 000000000..3447fa10b
--- /dev/null
+++ b/test/scripts/4500-Domain-Keys-Identified-Mail/4509
@@ -0,0 +1,111 @@
+# DKIM signing, with CHUNKING
+#
+exim -bd -DSERVER=server -oX PORT_S
+****
+#
+# single header signed, short message
+exim -DOPT=dkim -DLIST=From -odf -oMt sender -f sender a@test.ex
+From: nobody@example.com
+From: second@example.com
+
+content
+****
+#
+# single header signed, long message
+exim -DOPT=dkim -DLIST=From -odf -oMt sender -f sender b@test.ex
+From: nobody@example.com
+From: second@example.com
+
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
+
+The very last line
+****
+millisleep 500
+killdaemon
+no_msglog_check
diff --git a/test/scripts/4800-dnssec-dnslookup/4804 b/test/scripts/4800-dnssec-dnslookup/4804
new file mode 100644
index 000000000..ea4f2dec0
--- /dev/null
+++ b/test/scripts/4800-dnssec-dnslookup/4804
@@ -0,0 +1,11 @@
+# dnssec log_selector (client)
+exim -DSERVER=server -bd -oX PORT_D
+****
+exim -DOPT= -odf nologging@l-sec.test.ex
+****
+exim -DOPT=+dnssec -odf withlogging@l-sec.test.ex
+****
+exim -DOPT=+dnssec -odf withlogging@thishost.test.ex
+****
+killdaemon
+no_msglog_check
diff --git a/test/scripts/5400-cutthrough/5400 b/test/scripts/5400-cutthrough/5400
index 109b43928..10406c255 100644
--- a/test/scripts/5400-cutthrough/5400
+++ b/test/scripts/5400-cutthrough/5400
@@ -120,8 +120,7 @@ QUIT
#
# cutthrough for 2 recipients in one domain
# first one denied
-# so we get a 2nd conn with the traditional delivery
-# (for both because it's not a real verify=recipient)
+# so we get a 2nd conn with the traditional delivery for the second
server PORT_S 2
220 ESMTP
EHLO
@@ -140,8 +139,6 @@ MAIL FROM:
250 Sender OK
RCPT TO:
250 ok rcpt-1
-RCPT TO:
-250 ok rcpt-2
DATA
354 Send data
.
@@ -168,8 +165,7 @@ QUIT
#
# cutthrough for 2 recipients in one domain
# second one denied
-# so we get a 2nd conn with the traditional delivery
-# (for both because it's not a real verify=recipient)
+# so we get a 2nd conn with the traditional delivery of the 1st
server PORT_S 2
220 ESMTP
EHLO
@@ -190,8 +186,6 @@ MAIL FROM:
250 Sender OK
RCPT TO:
250 ok rcpt-1
-RCPT TO:
-250 ok rcpt-2
DATA
354 Send data
.
@@ -449,4 +443,5 @@ QUIT
****
#
#
+sortlog
# End
diff --git a/test/scripts/5400-cutthrough/5401 b/test/scripts/5400-cutthrough/5401
index d92110ce5..b7837b342 100644
--- a/test/scripts/5400-cutthrough/5401
+++ b/test/scripts/5400-cutthrough/5401
@@ -16,7 +16,7 @@ DATA
QUIT
250 OK
****
-exim -d-all+acl+transport -bs
+exim -bs -odf
EHLO myhost.test.ex
MAIL FROM:<CALLER@myhost.test.ex>
RCPT TO:<userx@domain.com>
@@ -25,3 +25,86 @@ DATA
.
QUIT
****
+#
+#
+#
+# cutthrough for denied recipient
+# deny should be reflected to originator
+# as this was a real rcpt-verify
+server PORT_S
+220 ESMTP
+EHLO
+250 OK
+MAIL FROM:
+250 Sender OK
+RCPT TO:
+550 No mate
+QUIT
+250 OK
+*eof
+****
+exim -bs -odf
+EHLO myhost.test.ex
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO:<no@domain.com>
+QUIT
+****
+#
+#
+#
+# cutthrough for 2 recipients in one domain
+# first one denied
+# so we get a 3rd conn with the traditional delivery
+# (for just the second because it was a real verify=recipient)
+server PORT_S 3
+220 ESMTP
+EHLO
+250 OK
+MAIL FROM:
+250 Sender OK
+RCPT TO:
+550 Not that one
+QUIT
+250 OK
+*eof
+220 ESMTP
+EHLO
+250 OK
+MAIL FROM:
+250 Sender OK
+RCPT TO:
+250 ok rcpt-1
+QUIT
+250 OK
+*eof
+220 ESMTP
+EHLO
+250 OK
+MAIL FROM:
+250 Sender OK
+RCPT TO:
+250 ok rcpt-1
+DATA
+354 Send data
+.
+250 OK
+QUIT
+250 OK
+*eof
+****
+#
+# Foregound delivery needed else the following subtest reception logging happens before this ones
+# delivery process logs and terminates; the interlock is only on the parent exim terminating.
+exim -bs -odf
+EHLO myhost.test.ex
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO:<no@domain.com>
+RCPT TO:<userx@domain.com>
+DATA
+
+.
+QUIT
+****
+#
+#
+#
diff --git a/test/scripts/5400-cutthrough/5402 b/test/scripts/5400-cutthrough/5402
index dbe7ef3c5..1113c6d32 100644
--- a/test/scripts/5400-cutthrough/5402
+++ b/test/scripts/5400-cutthrough/5402
@@ -1,13 +1,33 @@
-# cutthrough_delivery with MAIL SIZE=
+# cutthrough_delivery vs. recipient-verify cache entry
need_ipv4
-munge loopback
+#
+# Set up callout cache
#
server PORT_S
220 ESMTP
EHLO
-250-OK
-250 SIZE 65536
-MAIL FROM:<fred@myhost.test.ex> SIZE=1123
+250 OK
+MAIL FROM:
+250 Sender OK
+RCPT TO:
+250 Recipient OK
+QUIT
+250 OK
+****
+exim -bs -odf
+EHLO myhost.test.ex
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO:<dest@domain.com>
+QUIT
+****
+#
+# Send message with cutthrough
+#
+server PORT_S
+220 ESMTP
+EHLO
+250 OK
+MAIL FROM:
250 Sender OK
RCPT TO:
250 Recipient OK
@@ -18,13 +38,12 @@ DATA
QUIT
250 OK
****
-exim -bs
+exim -DOPT=CUTTHROUGH -bs -odf
EHLO myhost.test.ex
-MAIL FROM:<fred@myhost.test.ex> SIZE=99
-RCPT TO:<userx@domain.com>
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO:<dest@domain.com>
DATA
.
QUIT
****
-# End
diff --git a/test/scripts/5400-cutthrough/5403 b/test/scripts/5400-cutthrough/5403
new file mode 100644
index 000000000..ad1b44646
--- /dev/null
+++ b/test/scripts/5400-cutthrough/5403
@@ -0,0 +1,42 @@
+# cutthrough_delivery and -bhc
+need_ipv4
+munge loopback
+no_msglog_check
+#
+# Despite config for cutthrough should not make onward conn
+server -t -2 PORT_S
+****
+exim -bhc 1.2.3.4
+EHLO myhost.test.ex
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO:<plain@domain.com>
+DATA
+
+.
+QUIT
+****
+#
+# Onward conn made for r-verify but cleared before DATA
+server PORT_S
+220 server ready
+EHLO
+250 OK
+MAIL
+250 OK
+RCPT
+250 OK
+QUIT
+220 OK
+*eof
+****
+exim -bhc 1.2.3.4
+EHLO myhost.test.ex
+MAIL FROM:<sender@myhost.test.ex>
+RCPT TO:<verify@domain.com>
+DATA
+
+.
+QUIT
+****
+#
+# End
diff --git a/test/scripts/5400-cutthrough/5404 b/test/scripts/5400-cutthrough/5404
new file mode 100644
index 000000000..dbe7ef3c5
--- /dev/null
+++ b/test/scripts/5400-cutthrough/5404
@@ -0,0 +1,30 @@
+# cutthrough_delivery with MAIL SIZE=
+need_ipv4
+munge loopback
+#
+server PORT_S
+220 ESMTP
+EHLO
+250-OK
+250 SIZE 65536
+MAIL FROM:<fred@myhost.test.ex> SIZE=1123
+250 Sender OK
+RCPT TO:
+250 Recipient OK
+DATA
+354 Send data
+.
+250 OK
+QUIT
+250 OK
+****
+exim -bs
+EHLO myhost.test.ex
+MAIL FROM:<fred@myhost.test.ex> SIZE=99
+RCPT TO:<userx@domain.com>
+DATA
+
+.
+QUIT
+****
+# End
diff --git a/test/scripts/5400-cutthrough/5405 b/test/scripts/5400-cutthrough/5405
new file mode 100644
index 000000000..2e7a33388
--- /dev/null
+++ b/test/scripts/5400-cutthrough/5405
@@ -0,0 +1,228 @@
+# cutthrough_delivery tmp-rejects
+need_ipv4
+munge loopback
+#
+# basic operation. Should deliver in cutthrough mode.
+server PORT_S
+220 ESMTP
+EHLO
+250 OK
+MAIL FROM:
+250 Sender OK
+RCPT TO:
+250 Recipient OK
+DATA
+354 Send data
+.
+250 OK
+QUIT
+250 OK
+****
+exim -bs
+EHLO myhost.test.ex
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO:<usera@domain.com>
+DATA
+
+.
+QUIT
+****
+######################################################
+# RCPT-time
+#
+# temp-reject (at RCPT), default. Should spool msg.
+server PORT_S
+220 ESMTP
+EHLO
+250 OK
+MAIL FROM:
+250 Sender OK
+RCPT TO:
+450 not right now
+QUIT
+250 OK
+****
+exim -bs
+EHLO myhost.test.ex
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO:<userb@domain.com>
+DATA
+
+.
+QUIT
+****
+#
+# temp-reject (at RCPT), option "spool". Should spool msg (again).
+server PORT_S
+220 ESMTP
+EHLO
+250 OK
+MAIL FROM:
+250 Sender OK
+RCPT TO:
+450 not right now
+QUIT
+250 OK
+****
+exim -DCONTROL=/defer=spool -bs
+EHLO myhost.test.ex
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO:<userc@domain.com>
+DATA
+
+.
+QUIT
+****
+#
+# temp-reject (at RCPT), option "pass". Should tmp-rej source, at RCPT.
+server PORT_S
+220 ESMTP
+EHLO
+250 OK
+MAIL FROM:
+250 Sender OK
+RCPT TO:
+450 not right now
+QUIT
+250 OK
+****
+exim -DCONTROL=/defer=pass -bs
+EHLO myhost.test.ex
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO:<userd@domain.com>
+QUIT
+****
+#########################################################
+# DATA-time
+#
+#
+# temp-reject (at DATA-dot), default. Should spool msg.
+server PORT_S
+220 ESMTP
+EHLO
+250 OK
+MAIL FROM:
+250 Sender OK
+RCPT TO:
+250 good rcpt
+DATA
+354 Send data
+.
+459 content reject
+QUIT
+250 OK
+****
+exim -bs
+EHLO myhost.test.ex
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO:<usere@domain.com>
+DATA
+
+.
+QUIT
+****
+#
+# temp-reject (at DATA-dot), option "spool". Should spool msg (again).
+server PORT_S
+220 ESMTP
+EHLO
+250 OK
+MAIL FROM:
+250 Sender OK
+RCPT TO:
+250 good rcpt
+DATA
+354 Send data
+.
+459 content reject
+QUIT
+250 OK
+****
+exim -DCONTROL=/defer=spool -bs
+EHLO myhost.test.ex
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO:<userf@domain.com>
+DATA
+
+.
+QUIT
+****
+#
+# temp-reject (at DATA-dot), option "pass". Should tmp-rej source, at DATA.
+server PORT_S
+220 ESMTP
+EHLO
+250 OK
+MAIL FROM:
+250 Sender OK
+RCPT TO:
+250 good rcpt
+DATA
+354 Send data
+.
+459 content reject
+QUIT
+250 OK
+****
+exim -DCONTROL=/defer=pass -bs
+EHLO myhost.test.ex
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO:<userg@domain.com>
+DATA
+
+.
+QUIT
+****
+#
+#########################################################
+#, Now using a conn opened by a recipient verify
+#
+# basic operation. Should deliver in cutthrough mode.
+server PORT_S
+220 ESMTP
+EHLO
+250 OK
+MAIL FROM:
+250 Sender OK
+RCPT TO:
+250 Recipient OK
+DATA
+354 Send data
+.
+250 OK
+QUIT
+250 OK
+****
+exim -DOPT=verify=recipient/callout=use_sender -bs
+EHLO myhost.test.ex
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO:<userh@domain.com>
+DATA
+
+.
+QUIT
+****
+#
+# temp-reject (at RCPT), default. Should tmp-rej, due to the r-verify
+server PORT_S
+220 ESMTP
+EHLO
+250 OK
+MAIL FROM:
+250 Sender OK
+RCPT TO:
+450 not right now
+QUIT
+250 OK
+****
+exim -DOPT=verify=recipient/callout=use_sender -bs
+EHLO myhost.test.ex
+MAIL FROM:<CALLER@myhost.test.ex>
+RCPT TO:<useri@domain.com>
+DATA
+
+.
+QUIT
+****
+#
+no_msglog_check
diff --git a/test/scripts/5500-PRDR/5590 b/test/scripts/5500-PRDR/5590
new file mode 100644
index 000000000..a9722ff81
--- /dev/null
+++ b/test/scripts/5500-PRDR/5590
@@ -0,0 +1,40 @@
+# PRDR and CHUNKING reception
+exim -DALLOW=prdr_enable -DSERVER=server -bd -oX PORT_D
+****
+#
+client 127.0.0.1 PORT_D
+??? 220
+EHLO tester
+??? 250-
+??? 250-SIZE
+??? 250-8BITMIME
+??? 250-PIPELINING
+??? 250-CHUNKING
+??? 250-PRDR
+??? 250
+MAIL FROM:<someone@some.domain> PRDR
+??? 250
+RCPT TO:<bad1@test.ex>
+??? 250
+RCPT TO:<good@test.ex>
+??? 250
+RCPT TO:<bad2@test.ex>
+??? 250
+BDAT 100 last
+To: Susan@random.com
+From: Sam@random.com
+Subject: This is a bodyfull test message
+
+1234567890
+??? 353
+??? 550
+??? 250
+??? 550
+??? 250
+QUIT
+??? 221
+****
+#
+#
+killdaemon
+no_msglog_check
diff --git a/test/scripts/5500-PRDR/5591 b/test/scripts/5500-PRDR/5591
new file mode 100644
index 000000000..cf2af61b7
--- /dev/null
+++ b/test/scripts/5500-PRDR/5591
@@ -0,0 +1,39 @@
+# PRDR and CHUNKING transmission
+need_ipv4
+no_msglog_check
+#
+# Two recipients, accepted by full PRDR response sequence
+server PORT_S
+220 Server ready
+EHLO
+250-hiya matey
+250-PRDR
+250-CHUNKING
+250 OK
+MAIL FROM:<> PRDR
+250 OK
+RCPT TO
+250 OK
+RCPT TO
+250 OK
+BDAT 285 LAST
+*data 285
+353 prdr responses coming up
+250 first rcpt was good
+250 second rcpt was good
+250 OK, overall
+QUIT
+250 OK
+****
+sudo exim -odi -bS
+EHLO
+MAIL FROM:<sender@dom>
+RCPT TO:<usery>
+RCPT TO:<userz>
+DATA
+Some message text.
+.
+QUIT
+****
+#
+#
diff --git a/test/scripts/5500-PRDR/REQUIRES b/test/scripts/5500-PRDR/REQUIRES
index e69de29bb..bca921eaf 100644
--- a/test/scripts/5500-PRDR/REQUIRES
+++ b/test/scripts/5500-PRDR/REQUIRES
@@ -0,0 +1 @@
+support PRDR
diff --git a/test/scripts/5600-OCSP-OpenSSL/5600 b/test/scripts/5600-OCSP-OpenSSL/5600
index 2e63d0e0a..72fa478e3 100644
--- a/test/scripts/5600-OCSP-OpenSSL/5600
+++ b/test/scripts/5600-OCSP-OpenSSL/5600
@@ -2,11 +2,10 @@
#
#
#
-exim -z '1: Server sends good staple on request'
-****
+# '1: Server sends good staple on request'
#
exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
****
client-ssl \
-ocsp aux-fixed/exim-ca/example.com/server1.example.com/ca_chain.pem \
@@ -32,11 +31,10 @@ killdaemon
#
#
#
-exim -z '2: Server does not staple an outdated response'
-****
+# '2: Server does not staple an outdated response'
#
exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.dated.resp
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.dated.resp
****
# XXX test sequence might not be quite right; this is for a server refusal
# and we're expecting a client refusal.
@@ -58,11 +56,10 @@ killdaemon
#
#
#
-exim -z '3: Server does not staple a response for a revoked cert'
-****
+# '3: Server does not staple a response for a revoked cert'
#
exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.revoked.resp
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.revoked.resp
****
client-ssl \
-ocsp aux-fixed/exim-ca/example.com/server1.example.com/ca_chain.pem \
@@ -84,11 +81,10 @@ killdaemon
#
#
#
-exim -z '4: Connection functions when server is prepared to staple but client does not request it'
-****
+# '4: Connection functions when server is prepared to staple but client does not request it'
#
exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
****
#
client-ssl \
diff --git a/test/scripts/5600-OCSP-OpenSSL/5601 b/test/scripts/5600-OCSP-OpenSSL/5601
index f06bba7e2..ddcdeed9b 100644
--- a/test/scripts/5600-OCSP-OpenSSL/5601
+++ b/test/scripts/5600-OCSP-OpenSSL/5601
@@ -2,7 +2,7 @@
#
#
# Client works when we request but don't require OCSP stapling and none comes
-exim -bd -oX PORT_D -DSERVER=server -DOCSP=/dev/null
+exim -bd -oX PORT_D -DSERVER=server -DRETURN=/dev/null
****
exim norequire@test.ex
test message.
@@ -15,7 +15,7 @@ killdaemon
#
# Client works when we don't request OCSP stapling
exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
****
exim nostaple@test.ex
test message.
@@ -35,20 +35,20 @@ killdaemon
#
#
# Client fails on lack of required stapled info
-exim -bd -oX PORT_D -DSERVER=server -DOCSP=/dev/null
+exim -bd -oX PORT_D -DSERVER=server -DRETURN=/dev/null
****
exim CALLER@test.ex
test message.
****
sleep 1
killdaemon
-no_msglog_check
+sudo rm spool/db/retry
#
#
#
# Client fails on revoked stapled info
EXIM_TESTHARNESS_DISABLE_OCSPVALIDITYCHECK=y exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.revoked.resp
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.revoked.resp
****
exim CALLER@test.ex
test message.
@@ -56,13 +56,14 @@ test message.
sleep 1
killdaemon
millisleep 200
+sudo rm spool/db/retry
#
#
#
#
# Client fails on expired stapled info
EXIM_TESTHARNESS_DISABLE_OCSPVALIDITYCHECK=y exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.dated.resp
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.dated.resp
****
exim CALLER@test.ex
test message.
@@ -73,3 +74,4 @@ killdaemon
#
#
#
+no_msglog_check
diff --git a/test/scripts/5600-OCSP-OpenSSL/5610 b/test/scripts/5600-OCSP-OpenSSL/5610
new file mode 100644
index 000000000..fccd94486
--- /dev/null
+++ b/test/scripts/5600-OCSP-OpenSSL/5610
@@ -0,0 +1,115 @@
+# OCSP stapling, server, LE variation
+#
+#
+#
+# '1: Server sends good staple on request'
+#
+exim -bd -oX PORT_D -DSERVER=server \
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.signernocert.good.resp
+****
+client-ssl \
+ -ocsp aux-fixed/exim-ca/example.com/server1.example.com/ca_chain.pem \
+ HOSTIPV4 PORT_D aux-fixed/cert2 aux-fixed/cert2
+??? 220
+ehlo rhu.barb
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250
+starttls
+??? 220
+mail from:<userx@test.ex>
+??? 250
+rcpt to:<userx@test.ex>
+??? 250
+quit
+??? 221
+****
+killdaemon
+#
+#
+#
+# '2: Server does not staple an outdated response'
+#
+exim -bd -oX PORT_D -DSERVER=server \
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.signernocert.dated.resp
+****
+# XXX test sequence might not be quite right; this is for a server refusal
+# and we're expecting a client refusal.
+client-ssl -ocsp aux-fixed/exim-ca/expired1.example.com/CA.pem HOSTIPV4 PORT_D aux-fixed/cert2 aux-fixed/cert2
+??? 220
+ehlo rhu.barb
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250
+starttls
+??? 220
+****
+killdaemon
+#
+#
+#
+#
+#
+# '3: Server does not staple a response for a revoked cert'
+#
+exim -bd -oX PORT_D -DSERVER=server \
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.signernocert.revoked.resp
+****
+client-ssl \
+ -ocsp aux-fixed/exim-ca/example.com/server1.example.com/ca_chain.pem \
+ HOSTIPV4 PORT_D aux-fixed/cert2 aux-fixed/cert2
+??? 220
+ehlo rhu.barb
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250
+starttls
+??? 220
+****
+killdaemon
+#
+#
+#
+#
+#
+# '4: Connection functions when server is prepared to staple but client does not request it'
+#
+exim -bd -oX PORT_D -DSERVER=server \
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.signernocert.good.resp
+****
+#
+client-ssl \
+ HOSTIPV4 PORT_D aux-fixed/cert2 aux-fixed/cert2
+??? 220
+ehlo rhu.barb
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250
+starttls
+??? 220
+ehlo rhu.barb.tls
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250
+quit
+****
+killdaemon
+#
+#
+#
+#
+#
diff --git a/test/scripts/5600-OCSP-OpenSSL/5611 b/test/scripts/5600-OCSP-OpenSSL/5611
new file mode 100644
index 000000000..cb8f44fe1
--- /dev/null
+++ b/test/scripts/5600-OCSP-OpenSSL/5611
@@ -0,0 +1,77 @@
+# OCSP stapling, client, LE variation
+#
+#
+# Client works when we request but don't require OCSP stapling and none comes
+exim -bd -oX PORT_D -DSERVER=server -DRETURN=/dev/null
+****
+exim norequire@test.ex
+test message.
+****
+sleep 1
+killdaemon
+#
+#
+#
+#
+# Client works when we don't request OCSP stapling
+exim -bd -oX PORT_D -DSERVER=server \
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.signernocert.good.resp
+****
+exim nostaple@test.ex
+test message.
+****
+millisleep 500
+#
+#
+#
+#
+# Client accepts good stapled info
+exim CALLER@test.ex
+test message.
+****
+sleep 1
+killdaemon
+#
+#
+#
+# Client fails on lack of required stapled info
+exim -bd -oX PORT_D -DSERVER=server -DRETURN=/dev/null
+****
+exim CALLER@test.ex
+test message.
+****
+sleep 1
+killdaemon
+sudo rm spool/db/retry
+#
+#
+#
+# Client fails on revoked stapled info
+EXIM_TESTHARNESS_DISABLE_OCSPVALIDITYCHECK=y exim -bd -oX PORT_D -DSERVER=server \
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.signernocert.revoked.resp
+****
+exim CALLER@test.ex
+test message.
+****
+sleep 1
+killdaemon
+millisleep 200
+sudo rm spool/db/retry
+#
+#
+#
+#
+# Client fails on expired stapled info
+EXIM_TESTHARNESS_DISABLE_OCSPVALIDITYCHECK=y exim -bd -oX PORT_D -DSERVER=server \
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.signernocert.dated.resp
+****
+exim CALLER@test.ex
+test message.
+****
+sleep 1
+killdaemon
+#
+#
+#
+#
+no_msglog_check
diff --git a/test/scripts/5650-OCSP-GnuTLS/5650 b/test/scripts/5650-OCSP-GnuTLS/5650
index 749d87048..f67111424 100644
--- a/test/scripts/5650-OCSP-GnuTLS/5650
+++ b/test/scripts/5650-OCSP-GnuTLS/5650
@@ -6,7 +6,7 @@ exim -z '1: Server sends good staple on request'
****
#
exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
+ -DOPT=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
****
client-gnutls \
-ocsp aux-fixed/exim-ca/example.com/server1.example.com/ca_chain.pem \
@@ -36,7 +36,7 @@ exim -z '2: Server does not staple an outdated response'
****
#
exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.dated.resp
+ -DOPT=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.dated.resp
****
# XXX test sequence might not be quite right; this is for a server refusal
# and we're expecting a client refusal.
@@ -62,7 +62,7 @@ exim -z '3: Server does not staple a response for a revoked cert'
****
#
exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.revoked.resp
+ -DOPT=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.revoked.resp
****
client-gnutls \
-ocsp aux-fixed/exim-ca/example.com/server1.example.com/ca_chain.pem \
@@ -88,7 +88,7 @@ exim -z '4: Connection functions when server is prepared to staple but client do
****
#
exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
+ -DOPT=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
****
#
client-gnutls \
diff --git a/test/scripts/5650-OCSP-GnuTLS/5651 b/test/scripts/5650-OCSP-GnuTLS/5651
index 2015d43b9..dbf802298 100644
--- a/test/scripts/5650-OCSP-GnuTLS/5651
+++ b/test/scripts/5650-OCSP-GnuTLS/5651
@@ -2,7 +2,7 @@
#
#
# Client works when we request but don't require OCSP stapling and none comes
-exim -bd -oX PORT_D -DSERVER=server -DOCSP=""
+exim -bd -oX PORT_D -DSERVER=server -DOPT=""
****
exim norequire@test.ex
test message.
@@ -15,7 +15,7 @@ killdaemon
#
# Client works when we don't request OCSP stapling
exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
+ -DOPT=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
****
exim nostaple@test.ex
test message.
@@ -35,7 +35,7 @@ killdaemon
#
#
# Client fails on lack of required stapled info
-exim -bd -oX PORT_D -DSERVER=server -DOCSP=""
+exim -bd -oX PORT_D -DSERVER=server -DOPT=""
****
exim CALLER@test.ex
test message.
@@ -47,8 +47,9 @@ no_msglog_check
#
#
# Client fails on revoked stapled info
+sudo rm DIR/spool/db/retry
EXIM_TESTHARNESS_DISABLE_OCSPVALIDITYCHECK=y exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.revoked.resp
+ -DOPT=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.revoked.resp
****
exim CALLER@test.ex
test message.
@@ -60,8 +61,9 @@ killdaemon
#
#
# Client fails on expired stapled info
+sudo rm DIR/spool/db/retry
EXIM_TESTHARNESS_DISABLE_OCSPVALIDITYCHECK=y exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.dated.resp
+ -DOPT=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.dated.resp
****
exim CALLER@test.ex
test message.
diff --git a/test/scripts/5700-events/5700 b/test/scripts/5700-events/5700
index 8fb2010f2..1fe31cbfc 100644
--- a/test/scripts/5700-events/5700
+++ b/test/scripts/5700-events/5700
@@ -2,6 +2,7 @@
# (EXPERIMENTAL_EVENT)
#
need_ipv4
+munge timeout_errno
#
exim -odq userx@domain1
A deliverable message
diff --git a/test/scripts/5730-OCSP-GnuTLS-events/5730 b/test/scripts/5730-OCSP-GnuTLS-events/5730
index 6085a361e..d22a1aa1f 100644
--- a/test/scripts/5730-OCSP-GnuTLS-events/5730
+++ b/test/scripts/5730-OCSP-GnuTLS-events/5730
@@ -3,7 +3,7 @@
#
#
# Client works when we request but don't require OCSP stapling and none comes
-exim -bd -oX PORT_D -DSERVER=server -DOCSP=""
+exim -bd -oX PORT_D -DSERVER=server -DOPT=""
****
exim norequire@test.ex
test message.
@@ -16,7 +16,7 @@ killdaemon
#
# Client works when we request but don't require OCSP stapling and some arrives
exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
+ -DOPT=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
****
exim norequire@test.ex
test message.
@@ -45,33 +45,34 @@ killdaemon
#
#
# Client fails on lack of required stapled info
-exim -bd -oX PORT_D -DSERVER=server -DOCSP=""
+exim -bd -oX PORT_D -DSERVER=server -DOPT=""
****
exim failrequire@test.ex
test message.
****
sleep 1
killdaemon
-no_msglog_check
+sudo rm DIR/spool/db/retry
#
#
#
# Client fails on revoked stapled info
EXIM_TESTHARNESS_DISABLE_OCSPVALIDITYCHECK=y exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.revoked.resp
+ -DOPT=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.revoked.resp
****
exim failrevoked@test.ex
test message.
****
sleep 1
killdaemon
+sudo rm DIR/spool/db/retry
#
#
#
#
# Client fails on expired stapled info
EXIM_TESTHARNESS_DISABLE_OCSPVALIDITYCHECK=y exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.dated.resp
+ -DOPT=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.dated.resp
****
exim failexpired@test.ex
test message.
@@ -82,3 +83,4 @@ killdaemon
#
#
#
+no_msglog_check
diff --git a/test/scripts/5740-OCSP-OpenSSL-events/5740 b/test/scripts/5740-OCSP-OpenSSL-events/5740
index 5e385afa3..43c545afa 100644
--- a/test/scripts/5740-OCSP-OpenSSL-events/5740
+++ b/test/scripts/5740-OCSP-OpenSSL-events/5740
@@ -3,7 +3,7 @@
#
#
# Client works when we request but don't require OCSP stapling and none comes
-exim -bd -oX PORT_D -DSERVER=server -DOCSP=/dev/null
+exim -bd -oX PORT_D -DSERVER=server -DRETURN=/dev/null
****
exim norequire@test.ex
test message.
@@ -16,7 +16,7 @@ killdaemon
#
# Client works when we request but don't require OCSP stapling and some arrives
exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.good.resp
****
exim norequire@test.ex
test message.
@@ -45,7 +45,7 @@ killdaemon
#
#
# Client fails on lack of required stapled info
-exim -bd -oX PORT_D -DSERVER=server -DOCSP=/dev/null
+exim -bd -oX PORT_D -DSERVER=server -DRETURN=/dev/null
****
exim failrequire@test.ex
test message.
@@ -53,25 +53,27 @@ test message.
sleep 1
killdaemon
no_msglog_check
+sudo rm -f DIR/spool/db/retry
#
#
#
# Client fails on revoked stapled info
EXIM_TESTHARNESS_DISABLE_OCSPVALIDITYCHECK=y exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.revoked.resp
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.revoked.resp
****
exim failrevoked@test.ex
test message.
****
sleep 1
killdaemon
+sudo rm -f DIR/spool/db/retry
#
#
#
#
# Client fails on expired stapled info
EXIM_TESTHARNESS_DISABLE_OCSPVALIDITYCHECK=y exim -bd -oX PORT_D -DSERVER=server \
- -DOCSP=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.dated.resp
+ -DRETURN=DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.ocsp.dated.resp
****
exim failexpired@test.ex
test message.
diff --git a/test/scripts/5840-DANE-OpenSSL/5840 b/test/scripts/5840-DANE-OpenSSL/5840
index 143bf615b..d1da54913 100644
--- a/test/scripts/5840-DANE-OpenSSL/5840
+++ b/test/scripts/5840-DANE-OpenSSL/5840
@@ -2,11 +2,11 @@
#
exim -DSERVER=server -DDETAILS=ee -bd -oX PORT_D
****
-# TLSA (3 1 1)
+### TLSA (3 1 1)
exim -odq CALLER@dane256ee.test.ex
Testing
****
-# TLSA (3 1 2)
+### TLSA (3 1 2)
exim -odq CALLER@mxdane512ee.test.ex
Testing
****
@@ -14,17 +14,17 @@ exim -qf
****
#
#
-# Recipient callout
+### Recipient callout
exim -DOPT=callout -bhc 127.0.0.1
MAIL FROM: <CALLER@myhost.test.ex>
-RCPT TO: <CALLER@dane256ee.test.ex>
+RCPT TO: <rcptuser@dane256ee.test.ex>
****
killdaemon
#
#
exim -DSERVER=server -DDETAILS=ta -bd -oX PORT_D
****
-# TLSA (2 0 1)
+### TLSA (2 0 1)
exim -odq CALLER@mxdane256ta.test.ex
Testing
****
@@ -32,7 +32,7 @@ exim -qf
****
killdaemon
#
-# A server with a nonverifying cert and no TLSA
+### A server with a nonverifying cert and no TLSA
# Check we get a non-CV but TLS connection, with try_dane but no require_dane
exim -DSERVER=server -DDETAILS=no -bd -oX PORT_D
****
@@ -43,7 +43,7 @@ exim -qf
****
killdaemon
#
-# A server with a verifying cert and no TLSA
+### A server with a verifying cert and no TLSA
# Check we get a CV and TLS connection, with try_dane but no require_dane
exim -DSERVER=server -DDETAILS=ca -bd -oX PORT_D
****
@@ -57,15 +57,15 @@ killdaemon
#
exim -DSERVER=server -DDETAILS=ee -bd -oX PORT_D
****
-# A server with two MXs for which both TLSA lookups return defer
+### A server with two MXs for which both TLSA lookups return defer
exim -odq CALLER@mxdanelazy.test.ex
Testing
****
-# A server lacking a TLSA, required
+### A server lacking a TLSA, required
exim -odq CALLER@dane.no.1.test.ex
Testing
****
-# A server lacking a TLSA, requested only
+### A server lacking a TLSA, requested only
exim -odq CALLER@dane.no.2.test.ex
Testing
****
diff --git a/test/scripts/5900-queuefile-transport/5900 b/test/scripts/5900-queuefile-transport/5900
new file mode 100644
index 000000000..3d905542d
--- /dev/null
+++ b/test/scripts/5900-queuefile-transport/5900
@@ -0,0 +1,4 @@
+# queuefile transport test non existant directory
+exim -odi userx
+****
+no_msglog_check
diff --git a/test/scripts/5900-queuefile-transport/5901 b/test/scripts/5900-queuefile-transport/5901
new file mode 100644
index 000000000..b0f74f0ab
--- /dev/null
+++ b/test/scripts/5900-queuefile-transport/5901
@@ -0,0 +1,4 @@
+# queuefile transport test relative directory
+exim -odi userx
+****
+no_msglog_check
diff --git a/test/scripts/5900-queuefile-transport/5902 b/test/scripts/5900-queuefile-transport/5902
new file mode 100644
index 000000000..77c1db215
--- /dev/null
+++ b/test/scripts/5900-queuefile-transport/5902
@@ -0,0 +1,23 @@
+# queuefile transport test delivery
+#
+# make a scanner dir for the transport to write into
+mkdir -p DIR/scanner
+sudo chown EXIMUSER:EXIMGROUP DIR/scanner
+#
+# this message should be placed by the queuefile transport in the scanner directory
+exim -DOPT=scan user1
+****
+sleep 1
+#
+# check it is there
+ls DIR/scanner
+#
+# then re-inject "after scanning" to the default queue and see it gets found
+# it should get an appendfile delivery becase it is from the default queue
+sudo mv DIR/scanner/* DIR/spool/input/
+exim -q
+****
+#
+# tidy up
+sudo rm -fr DIR/scanner
+no_msglog_check
diff --git a/test/scripts/5900-queuefile-transport/REQUIRES b/test/scripts/5900-queuefile-transport/REQUIRES
new file mode 100644
index 000000000..f24c3ba19
--- /dev/null
+++ b/test/scripts/5900-queuefile-transport/REQUIRES
@@ -0,0 +1 @@
+support Experimental_QUEUEFILE