client_cmd_log = string_catn(client_cmd_log, US"|", 1);
(void) string_from_gstring(client_cmd_log);
}
+ else if (mode == SCMD_MORE)
+ {
+ client_cmd_log = string_catn(client_cmd_log, US"+", 1);
+ (void) string_from_gstring(client_cmd_log);
+ }
store_pool = old_pool;
}
# endif
sx SMTP connection, contains buffer for pipelining, and socket
mode buffer, write-with-more-likely, write
format a format, starting with one of
- of HELO, MAIL FROM, RCPT TO, DATA, ".", or QUIT.
+ of HELO, MAIL FROM, RCPT TO, DATA, BDAT, ".", or QUIT.
If NULL, flush pipeline buffer only.
... data for the format
current continue sequence is greater than the maximum supplied as an argument,
or greater than the global connection_max_messages, which, if set, overrides.
+It is also called if conditions are otherwise right for pipelining a QUIT after
+the message data, since if there is another message waiting we do not want to
+send that QUIT.
+
Arguments:
transport_name name of the transport
hostname name of the host
SMTP(shutdown)>>
SMTP<< 250 OK
SMTP(close)>>
-cmdlog: '220:EHLO:250-:MAIL:250:RCPT:250:DATA:354:.:250:QUIT:250'
+cmdlog: '220:EHLO:250-:MAIL:250:RCPT:250:DATA:354:.:250:QUIT+:250'
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(shutdown)>>
SMTP(closed)<<
SMTP(close)>>
-cmdlog: '220:EHLO:250-:MAIL:250:RCPT:250:RCPT:250:RCPT:250:RCPT:250:DATA:351:.:250:QUIT'
+cmdlog: '220:EHLO:250-:MAIL:250:RCPT:250:RCPT:250:RCPT:250:RCPT:250:DATA:351:.:250:QUIT+'
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<< 250 OK
SMTP<< 250 OK
SMTP(close)>>
-cmdlog: 'MAIL|:RCPT|:DATA:250:250:351:.:QUIT:250:250'
+cmdlog: 'MAIL|:RCPT|:DATA:250:250:351:.:QUIT+:250:250'
LOG: MAIN
=> b@test.ex F=<CALLER@test.ex> R=client T=send_to_server H=127.0.0.1 [127.0.0.1]* L C="250 OK"
LOG: MAIN
SMTP(shutdown)>>
SMTP<< 250 OK
SMTP(close)>>
-cmdlog: '220:EHLO:250-:MAIL|:RCPT|:DATA:550:503:503:QUIT:250'
+cmdlog: '220:EHLO:250-:MAIL|:RCPT|:DATA:550:503:503:QUIT+:250'
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 pipelined MAIL FROM:<CALLER@test.ex>: 550 NO
Exim version x.yz ....
SMTP<< 250 OK
SMTP<< 250 OK
SMTP(close)>>
-cmdlog: 'MAIL|:RCPT|:DATA:250:250:351:.:QUIT:250:250'
+cmdlog: 'MAIL|:RCPT|:DATA:250:250:351:.:QUIT+:250:250'
LOG: MAIN
=> c@test.ex F=<CALLER@test.ex> R=client T=send_to_server H=127.0.0.1 [127.0.0.1]* L C="250 OK"
LOG: MAIN
SMTP(shutdown)>>
SMTP<< 200 OK
SMTP(close)>>
-cmdlog: '220:EHLO:250-:MAIL|:RCPT|:DATA:250:250:500:QUIT:200'
+cmdlog: '220:EHLO:250-:MAIL|:RCPT|:DATA:250:250:500:QUIT+:200'
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(shutdown)>>
SMTP<< 200 OK
SMTP(close)>>
-cmdlog: '220:EHLO:250-:MAIL:250:RCPT:250:DATA:500:QUIT:200'
+cmdlog: '220:EHLO:250-:MAIL:250:RCPT:250:DATA:500:QUIT+:200'
LOG: MAIN
** usery@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
delay@test.again.dns
locking TESTSUITE/spool/db/retry.lockfile
locking TESTSUITE/spool/db/wait-t1.lockfile
-cmdlog: 'MAIL|:RCPT|:DATA:250:250:354:.:250:QUIT:250'
+cmdlog: 'MAIL|:RCPT|:DATA:250:250:354:.:250:QUIT+:250'
LOG: MAIN
=> ok@no.delay R=r1 T=t1 H=127.0.0.1 [127.0.0.1]* C="250 OK"
>>>>>>>>>>>>>>>> Exim pid=p1236 (continued-transport) terminating with rc=0 >>>>>>>>>>>>>>>>
delay@test.again.dns
locking TESTSUITE/spool/db/retry.lockfile
locking TESTSUITE/spool/db/wait-t1.lockfile
-cmdlog: 'MAIL|:RCPT|:DATA:250:250:354:.:250:QUIT:250'
+cmdlog: 'MAIL|:RCPT|:DATA:250:250:354:.:250:QUIT+:250'
LOG: MAIN
=> ok@no.delay R=r1 T=t1 H=127.0.0.1 [127.0.0.1]* C="250 OK"
>>>>>>>>>>>>>>>> Exim pid=p1235 (continued-transport) terminating with rc=0 >>>>>>>>>>>>>>>>
locking TESTSUITE/spool/db/retry.lockfile
no retry data available
added retry item for R:userx@test.ex:<CALLER@test.ex>: errno=-44 more_errno=dd,A flags=0
-cmdlog: '220:EHLO:250:MAIL:250:RCPT:451:QUIT:250'
+cmdlog: '220:EHLO:250:MAIL:250:RCPT:451:QUIT+:250'
reading retry information for R:userx@test.ex:<CALLER@test.ex> from subprocess
added retry item
LOG: MAIN
no host retry record
no message retry record
added retry item for R:userx@test.ex:<CALLER@test.ex>: errno=-44 more_errno=dd,A flags=0
-cmdlog: '220:EHLO:250:MAIL:250:RCPT:451:QUIT:250'
+cmdlog: '220:EHLO:250:MAIL:250:RCPT:451:QUIT+:250'
reading retry information for R:userx@test.ex:<CALLER@test.ex> from subprocess
existing delete item dropped
added retry item
no host retry record
no message retry record
added retry item for R:userx@test.ex:<CALLER@test.ex>: errno=-44 more_errno=dd,A flags=0
-cmdlog: '220:EHLO:250:MAIL:250:RCPT:451:QUIT:250'
+cmdlog: '220:EHLO:250:MAIL:250:RCPT:451:QUIT+:250'
reading retry information for R:userx@test.ex:<CALLER@test.ex> from subprocess
existing delete item dropped
added retry item
no retry data available
added retry item for R:userx@test.ex:<CALLER@test.ex>: errno=-44 more_errno=dd,A flags=0
added retry item for R:usery@test.ex:<CALLER@test.ex>: errno=-44 more_errno=dd,A flags=0
-cmdlog: '220:EHLO:250:MAIL:250:RCPT:451:RCPT:451:QUIT:250'
+cmdlog: '220:EHLO:250:MAIL:250:RCPT:451:RCPT:451:QUIT+:250'
reading retry information for R:userx@test.ex:<CALLER@test.ex> from subprocess
added retry item
reading retry information for R:usery@test.ex:<CALLER@test.ex> from subprocess
no message retry record
added retry item for R:userx@test.ex:<CALLER@test.ex>: errno=-44 more_errno=dd,A flags=0
added retry item for R:usery@test.ex:<CALLER@test.ex>: errno=-44 more_errno=dd,A flags=0
-cmdlog: '220:EHLO:250:MAIL:250:RCPT:451:RCPT:451:QUIT:250'
+cmdlog: '220:EHLO:250:MAIL:250:RCPT:451:RCPT:451:QUIT+:250'
reading retry information for R:userx@test.ex:<CALLER@test.ex> from subprocess
existing delete item dropped
added retry item
SMTP(shutdown)>>
SMTP<< 250 OK
SMTP(close)>>
-cmdlog: '220:EHLO:250:MAIL:250:RCPT:451:QUIT:250'
+cmdlog: '220:EHLO:250:MAIL:250:RCPT:451:QUIT+:250'
set_process_info: pppp delivering 10HmaX-000000005vi-0000: just tried 127.0.0.1 [127.0.0.1]:PORT_S for x@y: result OK
*@127.0.0.1 in "*"?
list element: *
Deferred addresses:
locking TESTSUITE/spool/db/retry.lockfile
locking TESTSUITE/spool/db/wait-t1.lockfile
-cmdlog: '220:EHLO:250:MAIL:250:RCPT:550:QUIT:250'
+cmdlog: '220:EHLO:250:MAIL:250:RCPT:550:QUIT+:250'
LOG: MAIN
** x@uppercase.test.ex R=r1 T=t1 H=uppercase.test.ex [127.0.0.1]: SMTP error from remote mail server after RCPT TO:<x@UpperCase.test.ex>: 550 Unknown
Exim version x.yz ....
SMTP(shutdown)>>
SMTP<< 250 OK
SMTP(close)>>
-cmdlog: '220:EHLO:250-:MAIL:250:RCPT:250:DATA:354:.:250:QUIT:250'
+cmdlog: '220:EHLO:250-:MAIL:250:RCPT:250:DATA:354:.:250:QUIT+:250'
LOG: MAIN
=> x@srv27.test.ex R=r1 T=t1 H=localhost.test.ex [127.0.0.1]:PORT_S C="250 OK"
LOG: MAIN
Deferred addresses:
locking TESTSUITE/spool/db/retry.lockfile
locking TESTSUITE/spool/db/wait-smtp.lockfile
-cmdlog: '220:EHLO:250-:MAIL:250:RCPT:250:DATA:354:.:250:QUIT:250'
+cmdlog: '220:EHLO:250-:MAIL:250:RCPT:250:DATA:354:.:250:QUIT+:250'
LOG: MAIN
=> userx@domain1 R=smarthost T=smtp H=thisloop.test.ex [127.0.0.1] C="250 OK"
LOG: MAIN
locking TESTSUITE/spool/db/retry.lockfile
no retry data available
added retry item for R:x@y:<CALLER@myhost.test.ex>: errno=-44 more_errno=dd,A flags=0
-cmdlog: '220:EHLO:250:MAIL:250:RCPT:451:QUIT:250'
+cmdlog: '220:EHLO:250:MAIL:250:RCPT:451:QUIT+:250'
reading retry information for R:x@y:<CALLER@myhost.test.ex> from subprocess
added retry item
LOG: MAIN
added retry item for R:x@y:<CALLER@myhost.test.ex>: errno=dd more_errno=dd,A flags=1
added retry item for R:x@y: errno=dd more_errno=dd,A flags=1
locking TESTSUITE/spool/db/wait-smtp.lockfile
-cmdlog: '220:EHLO:250:MAIL:250:RCPT:250:DATA:354:.:250:QUIT:250'
+cmdlog: '220:EHLO:250:MAIL:250:RCPT:250:DATA:354:.:250:QUIT+:250'
reading retry information for R:x@y from subprocess
existing delete item dropped
added delete item
ok=0 send_quit=0 send_rset=1 continue_more=0 yield=0 first_address is NULL
SMTP<< 221 Closing connection
SMTP(close)>>
-cmdlog: '220:EHLO:250-:MAIL|:RCPT|:DATA:250:250:300:.:QUIT:451:221'
+cmdlog: '220:EHLO:250-:MAIL|:RCPT|:DATA:250:250:300:.:QUIT+:451:221'
added retry item for T:127.0.0.1:127.0.0.1:PORT_D:10HmaZ-000000005vi-0000: errno=-46 more_errno=dd,A flags=6
all IP addresses skipped or deferred at least one address
Leaving send_to_server transport
ok=0 send_quit=0 send_rset=1 continue_more=0 yield=0 first_address is NULL
SMTP<< 221 Closing connection
SMTP(close)>>
-cmdlog: '220:EHLO:250-:MAIL|:RCPT|:DATA:250:250:300:.:QUIT:550:221'
+cmdlog: '220:EHLO:250-:MAIL|:RCPT|:DATA:250:250:300:.:QUIT+:550:221'
Leaving send_to_server transport
LOG: MAIN
** permreject@test.ex R=client T=send_to_server H=127.0.0.1 [127.0.0.1]: SMTP error from remote mail server after end of data: 550 content rejected
ok=0 send_quit=0 send_rset=1 continue_more=0 yield=0 first_address is NULL
SMTP(closed)<<
SMTP(close)>>
-cmdlog: '220:EHLO:250-:MAIL|:RCPT|:DATA:250:250:300:.:QUIT'
+cmdlog: '220:EHLO:250-:MAIL|:RCPT|:DATA:250:250:300:.:QUIT+'
added retry item for T:127.0.0.1:127.0.0.1:PORT_D:10HmbB-000000005vi-0000: errno=-18 more_errno=dd,A flags=6
all IP addresses skipped or deferred at least one address
Leaving send_to_server transport
ok=1 send_quit=0 send_rset=0 continue_more=0 yield=0 first_address is NULL
SMTP<< 221 Closing connection
SMTP(close)>>
-cmdlog: '220:EHLO:250-:MAIL|:RCPT|:BDAT:QUIT:250:250:250:221'
+cmdlog: '220:EHLO:250-:MAIL|:RCPT|:BDAT+:QUIT+:250:250:250:221'
Leaving send_to_server transport
LOG: MAIN
=> good@test.ex R=client T=send_to_server H=127.0.0.1 [127.0.0.1] L K C="250 OK chunked message data"
SMTP(shutdown)>>
SMTP<< 221 Closing connection
SMTP(close)>>
-cmdlog: '220:EHLO:250-:MAIL:250:RCPT:250:BDAT:250:QUIT:221'
+cmdlog: '220:EHLO:250-:MAIL:250:RCPT:250:BDAT+:250:QUIT+:221'
Leaving send_to_server transport
LOG: MAIN
=> nopipe@test.ex R=client T=send_to_server H=127.0.0.1 [127.0.0.1] K C="250 OK chunked message data"
ok=0 send_quit=0 send_rset=1 continue_more=0 yield=0 first_address is NULL
SMTP<< 221 Closing connection
SMTP(close)>>
-cmdlog: '220:EHLO:250-:MAIL|:RCPT|:BDAT:QUIT:250:250:451:221'
+cmdlog: '220:EHLO:250-:MAIL|:RCPT|:BDAT+:QUIT+:250:250:451:221'
added retry item for T:127.0.0.1:127.0.0.1:PORT_D:10HmaZ-000000005vi-0000: errno=-46 more_errno=dd,A flags=6
all IP addresses skipped or deferred at least one address
Leaving send_to_server transport
ok=0 send_quit=0 send_rset=1 continue_more=0 yield=0 first_address is NULL
SMTP<< 221 Closing connection
SMTP(close)>>
-cmdlog: '220:EHLO:250-:MAIL|:RCPT|:BDAT:QUIT:250:250:550:221'
+cmdlog: '220:EHLO:250-:MAIL|:RCPT|:BDAT+:QUIT+:250:250:550:221'
Leaving send_to_server transport
LOG: MAIN
** permreject@test.ex R=client T=send_to_server H=127.0.0.1 [127.0.0.1]: SMTP error from remote mail server after pipelined end of data: 550 content rejected
ok=0 send_quit=0 send_rset=1 continue_more=0 yield=0 first_address is NULL
SMTP(closed)<<
SMTP(close)>>
-cmdlog: '220:EHLO:250-:MAIL|:RCPT|:BDAT:QUIT:250:250'
+cmdlog: '220:EHLO:250-:MAIL|:RCPT|:BDAT+:QUIT+:250:250'
added retry item for T:127.0.0.1:127.0.0.1:PORT_D:10HmbB-000000005vi-0000: errno=-18 more_errno=dd,A flags=6
all IP addresses skipped or deferred at least one address
Leaving send_to_server transport
SMTP<< 250 OK id=10HmbC-000000005vi-0000
SMTP<< 221 myhost.test.ex closing connection
SMTP(close)>>
-cmdlog: 'MAIL|:RCPT|:DATA:250:250:354:.:QUIT:250:221'
+cmdlog: 'MAIL|:RCPT|:DATA:250:250:354:.:QUIT+:250:221'
LOG: MAIN
=> usery@test.ex R=client T=send_to_server H=127.0.0.1 [127.0.0.1]* X=TLS1.x:ke-RSA-AES256-SHAnnn:xxx CV=no C="250 OK id=10HmbC-000000005vi-0000"
LOG: MAIN
SMTP<< 250 OK id=10HmbI-000000005vi-0000
SMTP<< 221 myhost.test.ex closing connection
SMTP(close)>>
-cmdlog: 'MAIL|:RCPT|:DATA:250:250:354:.:QUIT:250:221'
+cmdlog: 'MAIL|:RCPT|:DATA:250:250:354:.:QUIT+:250:221'
LOG: MAIN
=> userb@test.ex R=cl_override T=send_to_server H=127.0.0.1 [127.0.0.1]* X=TLS1.x:ke-RSA-AES256-SHAnnn:xxx CV=no C="250 OK id=10HmbI-000000005vi-0000"
LOG: MAIN
SMTP(TLS shutdown)>>
SMTP<< 221 myhost.test.ex closing connection
SMTP(close)>>
-cmdlog: 'DATA:354:.:250:QUIT:221'
+cmdlog: 'DATA:354:.:250:QUIT+:221'
Leaving t1 transport
LOG: MAIN
=> userb@test.ex R=client T=t1 H=127.0.0.1 [127.0.0.1]:PORT_D X=TLS1.x:ke-RSA-AES256-SHAnnn:xxx CV=no C="250 OK id=10HmaY-000000005vi-0000"
SMTP(TLS shutdown)>>
SMTP<< 221 myhost.test.ex closing connection
SMTP(close)>>
-cmdlog: 'DATA:354:.:250:QUIT:221'
+cmdlog: 'DATA:354:.:250:QUIT+:221'
Leaving t1 transport
LOG: MAIN
=> userb@test.ex R=client T=t1 H=127.0.0.1 [127.0.0.1]:PORT_D X=TLS1.x:ke-RSA-AES256-SHAnnn:xxx CV=no C="250 OK id=10HmaY-000000005vi-0000"
SMTP(shutdown)>>
SMTP<< 250 OK
SMTP(close)>>
-cmdlog: '220:EHLO:250-:AUTH:235:MAIL:250:RCPT:250:DATA:354:.:250:QUIT:250'
+cmdlog: '220:EHLO:250-:AUTH:235:MAIL:250:RCPT:250:DATA:354:.:250:QUIT+:250'
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(shutdown)>>
SMTP<< 250 OK
SMTP(close)>>
-cmdlog: '220:EHLO:250-:AUTH:235:MAIL:250:RCPT:250:DATA:354:.:250:QUIT:250'
+cmdlog: '220:EHLO:250-:AUTH:235:MAIL:250:RCPT:250:DATA:354:.:250:QUIT+:250'
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(shutdown)>>
SMTP<< 250 OK
SMTP(close)>>
-cmdlog: '220:EHLO:250-:AUTH:300:********:300:********:235:MAIL:250:RCPT:250:DATA:354:.:250:QUIT:250'
+cmdlog: '220:EHLO:250-:AUTH:300:********:300:********:235:MAIL:250:RCPT:250:DATA:354:.:250:QUIT+:250'
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
ok=1 send_quit=0 send_rset=0 continue_more=0 yield=0 first_address is NULL
SMTP<< 220 bye
SMTP(close)>>
-cmdlog: 'EHLO|:MAIL|:RCPT|:DATA:220:250-:250:250:354:.:QUIT:250:220'
+cmdlog: 'EHLO|:MAIL|:RCPT|:DATA:220:250-:250:250:354:.:QUIT+:250:220'
Leaving smtp transport
LOG: MAIN
=> extchange@test.ex R=client T=smtp H=127.0.0.1 [127.0.0.1] L* C="250 message accepted"
SMTP<< 250 OK id=10HmbL-000000005vi-0000
SMTP<< 221 myhost.test.ex closing connection
SMTP(close)>>
-cmdlog: '220:EHLO:250-:MAIL|:RCPT|:DATA:250:250:354:.:QUIT:250:221'
+cmdlog: '220:EHLO:250-:MAIL|:RCPT|:DATA:250:250:354:.:QUIT+:250:221'
LOG: MAIN
=> d@test.ex R=client T=send_to_server H=ip4.ip4.ip4.ip4 [ip4.ip4.ip4.ip4] C="250 OK id=10HmbL-000000005vi-0000"
LOG: MAIN