specified in the transports, and therefore not visible at top level, in which
case continue_more won't get set. */
+HDEBUG(D_transport|D_acl|D_v) debug_printf(" SMTP(close)>>\n");
(void)close(inblock.sock);
#ifndef DISABLE_EVENT
# command, triggered by $server_pid being non-zero. The server sends its output
# to a different file. The variable $server_opts, if not empty, contains
# options to disable IPv4 or IPv6 if necessary.
+# This works because "server" swallows its stdin before waiting for a connection.
if (/^server\s+(.*)$/)
{
250 Recipient OK
DATA
>
-QUIT
-250 OK
+*eof
****
exim -odi x@test.ex
****
RCPT TO:
>
DATA
-550 Failed DATA
-QUIT
-250 OK
+*eof
****
exim -odi x@test.ex
****
RCPT TO:
550 Can't send RCPT
DATA
-550 Can't send DATA
-QUIT
-250 OK
+*eof
****
exim -odi x@test.ex
****
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
****
250 Recipient OK
DATA
>
-QUIT
-250 OK
+*eof
****
exim -odi x@test.ex
****
250 Sender OK
RCPT TO:
>
-DATA
-550 Failed DATA
-QUIT
-250 OK
+*eof
****
exim -odi x@test.ex
****
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
****
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
****
cr.pid, cr.uid, cr.gid);
--------------*****************/
}
+ fflush(stdout);
if (dup_accept_socket < 0)
{
sequence=1 local_max=500 global_max=-1
no messages waiting for 127.0.0.1
SMTP>> QUIT
+ SMTP(close)>>
Leaving my_smtp transport
LOG: MAIN
=> userx@domain.com R=my_main_router T=my_smtp H=127.0.0.1 [127.0.0.1] C="250 OK"
SMTP<< 550 NO
SMTP<< 403 Sorry temp data error
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
== yes@test.ex R=client T=send_to_server defer (-46) H=127.0.0.1 [127.0.0.1]: SMTP error from remote mail server after pipelined DATA: 403 Sorry temp data error
LOG: MAIN
SMTP>> writing message and terminating "."
SMTP<< 250 OK
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
=> w@test.ex R=client T=send_to_server H=127.0.0.1 [127.0.0.1] C="250 OK"
LOG: MAIN
SMTP<< 351 Send more
SMTP>> writing message and terminating "."
SMTP<< 250 OK
+ SMTP(close)>>
LOG: MAIN
=> a@test.ex F=<CALLER@test.ex> R=client T=send_to_server H=127.0.0.1 [127.0.0.1] C="250 OK"
LOG: MAIN
SMTP>> writing message and terminating "."
SMTP<< 250 OK
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
=> b@test.ex F=<CALLER@test.ex> R=client T=send_to_server H=127.0.0.1 [127.0.0.1]* C="250 OK"
LOG: MAIN
SMTP<< 503 Unexpected RCPT
SMTP<< 503 Unexpected DATA
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
** a@test.ex F=<CALLER@test.ex> R=client T=send_to_server H=127.0.0.1 [127.0.0.1]: SMTP error from remote mail server after MAIL FROM:<CALLER@test.ex>: 550 NO
Exim version x.yz ....
SMTP<< 503 Unexpected DATA
SMTP>> RSET
SMTP<< 250 OK
+ SMTP(close)>>
LOG: MAIN
** b@test.ex F=<CALLER@test.ex> R=client T=send_to_server H=127.0.0.1 [127.0.0.1]: SMTP error from remote mail server after RCPT TO:<b@test.ex>: 550 Unknown
Exim version x.yz ....
SMTP>> writing message and terminating "."
SMTP<< 250 OK
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
=> c@test.ex F=<CALLER@test.ex> R=client T=send_to_server H=127.0.0.1 [127.0.0.1]* C="250 OK"
LOG: MAIN
SMTP<< 250 OK
SMTP<< 500 NO
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
** userx@test.ex R=r1 T=t1 H=127.0.0.1 [127.0.0.1]: SMTP error from remote mail server after pipelined DATA: 500 NO
LOG: MAIN
SMTP>> DATA
SMTP<< 500 NO
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
** userx@test.ex R=r1 T=t1 H=127.0.0.1 [127.0.0.1]: SMTP error from remote mail server after DATA: 500 NO
LOG: MAIN
H=127.0.0.1 [127.0.0.1]: SMTP error from remote mail server after RCPT TO:<x@y>: 451 Temporary error
added retry item for R:x@y: errno=-44 more_errno=dd,A flags=0
SMTP>> QUIT
+ SMTP(close)>>
set_process_info: pppp delivering 10HmaX-0005vi-00: just tried 127.0.0.1 [127.0.0.1] for x@y: result OK
address match test: subject=*@127.0.0.1 pattern=*
127.0.0.1 in "*"? yes (matched "*")
SMTP>> writing message and terminating "."
SMTP<< 250 OK
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
=> x@srv27.test.ex R=r1 T=t1 H=localhost.test.ex [127.0.0.1]:1224 C="250 OK"
LOG: MAIN
sequence=1 local_max=500 global_max=-1
SMTP>> RSET
H=127.0.0.1 [127.0.0.1] Remote host closed connection in response to RSET
+ SMTP(close)>>
set_process_info: pppp delivering 10HmaX-0005vi-00: just tried 127.0.0.1 [127.0.0.1] for userx@test.ex: result OK
Leaving t1 transport
set_process_info: pppp delivering 10HmaX-0005vi-00 (just run t1 for userx@test.ex in subprocess)
SMTP>> DATA
SMTP<< 354 SEND
SMTP>> writing message and terminating "."
+ SMTP(close)>>
LOG: MAIN
H=127.0.0.1 [127.0.0.1]: SMTP timeout after sending data block (ddd bytes written): Connection timed out
LOG: MAIN
SMTP>> writing message and terminating "."
SMTP<< 250 OK id=10HmaZ-0005vi-00
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
=> CALLER@test.ex R=client T=send_to_server1 H=127.0.0.1 [127.0.0.1] X=TLS1.x:xxxxRSA_AES_256_CBC_SHAnnn:256 CV=no DN="C=UK,O=The Exim Maintainers,OU=Test Suite,CN=Phil Pennock" C="250 OK id=10HmaZ-0005vi-00"
LOG: MAIN
SMTP>> writing message and terminating "."
SMTP<< 250 OK id=10HmbA-0005vi-00
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
=> CALLER@test.ex R=client T=send_to_server1 H=127.0.0.1 [127.0.0.1] X=TLS1.x:xxxxRSA_AES_256_CBC_SHAnnn:256 CV=no DN="C=UK,O=The Exim Maintainers,OU=Test Suite,CN=Phil Pennock" C="250 OK id=10HmbA-0005vi-00"
LOG: MAIN
SMTP>> writing message and terminating "."
SMTP<< 250 OK id=10HmbB-0005vi-00
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
=> abcd@test.ex R=client T=send_to_server2 H=ip4.ip4.ip4.ip4 [ip4.ip4.ip4.ip4] X=TLS1.x:xxxxRSA_AES_256_CBC_SHAnnn:256 CV=no DN="C=UK,O=The Exim Maintainers,OU=Test Suite,CN=Phil Pennock" C="250 OK id=10HmbB-0005vi-00"
LOG: MAIN
250-PIPELINING
250-STARTTLS
250 HELP
+ SMTP(close)>>
LOG: MAIN
=> userx@test.ex R=client T=send_to_server H=127.0.0.1 [127.0.0.1] X=TLS1.x:xxxxRSA_AES_256_CBC_SHAnnn:256 CV=no DN="C=UK,O=The Exim Maintainers,OU=Test Suite,CN=Phil Pennock" C="250 OK id=10HmaZ-0005vi-00"
LOG: MAIN
SMTP<< 354 Enter message, ending with "." on a line by itself
SMTP<< 250 OK id=10HmbA-0005vi-00
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
=> userx@test.ex R=client T=send_to_server H=127.0.0.1 [127.0.0.1]* X=TLS1.x:xxxxRSA_AES_256_CBC_SHAnnn:256 CV=no DN="C=UK,O=The Exim Maintainers,OU=Test Suite,CN=Phil Pennock" C="250 OK id=10HmbA-0005vi-00"
LOG: MAIN
SMTP>> writing message and terminating "."
SMTP<< 250 OK id=10HmaZ-0005vi-00
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
=> CALLER@test.ex R=client T=send_to_server1 H=127.0.0.1 [127.0.0.1] X=TLSv1:AES256-SHA:256 CV=no DN="/C=UK/O=The Exim Maintainers/OU=Test Suite/CN=Phil Pennock" C="250 OK id=10HmaZ-0005vi-00"
LOG: MAIN
SMTP>> writing message and terminating "."
SMTP<< 250 OK id=10HmbA-0005vi-00
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
=> CALLER@test.ex R=client T=send_to_server1 H=127.0.0.1 [127.0.0.1] X=TLSv1:AES256-SHA:256 CV=no DN="/C=UK/O=The Exim Maintainers/OU=Test Suite/CN=Phil Pennock" C="250 OK id=10HmbA-0005vi-00"
LOG: MAIN
SMTP>> writing message and terminating "."
SMTP<< 250 OK id=10HmbB-0005vi-00
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
=> abcd@test.ex R=client T=send_to_server2 H=ip4.ip4.ip4.ip4 [ip4.ip4.ip4.ip4] X=TLSv1:AES256-SHA:256 CV=no DN="/C=UK/O=The Exim Maintainers/OU=Test Suite/CN=Phil Pennock" C="250 OK id=10HmbB-0005vi-00"
LOG: MAIN
250-PIPELINING
250-STARTTLS
250 HELP
+ SMTP(close)>>
LOG: MAIN
=> userx@test.ex R=client T=send_to_server H=127.0.0.1 [127.0.0.1] X=TLSv1:AES256-SHA:256 CV=no DN="/C=UK/O=The Exim Maintainers/OU=Test Suite/CN=Phil Pennock" C="250 OK id=10HmaZ-0005vi-00"
LOG: MAIN
SMTP<< 354 Enter message, ending with "." on a line by itself
SMTP<< 250 OK id=10HmbA-0005vi-00
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
=> userx@test.ex R=client T=send_to_server H=127.0.0.1 [127.0.0.1]* X=TLSv1:AES256-SHA:256 CV=no DN="/C=UK/O=The Exim Maintainers/OU=Test Suite/CN=Phil Pennock" C="250 OK id=10HmbA-0005vi-00"
LOG: MAIN
SMTP>> writing message and terminating "."
SMTP<< 250 OK
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
=> userx@domain.com R=all T=smtp H=127.0.0.1 [127.0.0.1] A=plain C="250 OK"
LOG: MAIN
SMTP>> writing message and terminating "."
SMTP<< 250 OK
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
=> userx@domain.com R=all T=smtp H=127.0.0.1 [127.0.0.1] A=plain C="250 OK"
LOG: MAIN
SMTP>> writing message and terminating "."
SMTP<< 250 OK
SMTP>> QUIT
+ SMTP(close)>>
LOG: MAIN
=> userx@domain.com R=all T=smtp H=127.0.0.1 [127.0.0.1] A=login C="250 OK"
LOG: MAIN
250 Recipient OK
DATA
>
-Unexpected EOF read from client
+Expected EOF read from client
+End of script
Listening on port 1224 ...
Connection request from [127.0.0.1]
220 ESMTP
RCPT TO:<x@test.ex>
>
DATA
-550 Failed DATA
-Unexpected EOF read from client
+Expected EOF read from client
+End of script
Listening on port 1224 ...
Connection request from [127.0.0.1]
220 ESMTP
RCPT TO:<x@test.ex>
550 Can't send RCPT
DATA
-550 Can't send DATA
-Unexpected EOF read from client
+Expected EOF read from client
+End of script
Listening on port 1224 ...
Connection request from [127.0.0.1]
220 ESMTP
RCPT TO:<z@test.ex>
250 Third RCPT OK
DATA
-550 Failed DATA
-Unexpected EOF read from client
+Expected EOF read from client
+End of script
Listening on port 1224 ...
Connection request from [127.0.0.1]
220 ESMTP
250 Recipient OK
DATA
>
-Unexpected EOF read from client
+Expected EOF read from client
+End of script
Listening on port 1224 ...
Connection request from [127.0.0.1]
220 ESMTP
250 Sender OK
RCPT TO:<x@test.ex>
>
-Unexpected EOF read from client
+Expected EOF read from client
+End of script
Listening on port 1224 ...
Connection request from [127.0.0.1]
220 ESMTP
250 HELP
MAIL FROM:<CALLER@myhost.test.ex>
>
-Unexpected EOF read from client
+Expected EOF read from client
+End of script
Listening on port 1224 ...
Connection request from [127.0.0.1]
220 ESMTP
RCPT TO:<y@test.ex>
>
250 Second RCPT malformed
-Unexpected EOF read from client
+Expected EOF read from client
+End of script