This option requests Exim to give up trying to deliver the listed messages,
including any that are frozen. However, if any of the messages are active,
their status is not altered. For non-bounce messages, a delivery error message
-is sent to the sender, containing the text &"cancelled by administrator"&.
+is sent to the sender.
Bounce messages are just discarded. This option can be used only by an admin
user.
if (addr->return_file >= 0)
{
- paddr = &(addr->next);
+ paddr = &addr->next;
filecount++;
}
for (address_item * addr = handled_addr; addr; addr = addr->next)
{
host_item * hu;
+#ifdef EXPERIMENTAL_DSN_INFO
+ const uschar * s;
+#endif
print_dsn_addr_action(fp, addr, US"failed", US"5.0.0");
{
fprintf(fp, "Remote-MTA: dns; %s\n", hu->name);
#ifdef EXPERIMENTAL_DSN_INFO
- {
- const uschar * s;
if (hu->address)
{
uschar * p = hu->port == 25
dsn_put_wrapped(fp, US"X-Remote-MTA-smtp-greeting: X-str; ", s);
if ((s = addr->helo_response) && *s)
dsn_put_wrapped(fp, US"X-Remote-MTA-helo-response: X-str; ", s);
- if ((s = addr->message) && *s)
+ if (testflag(addr, af_pass_message) && (s = addr->message) && *s)
dsn_put_wrapped(fp, US"X-Exim-Diagnostic: X-str; ", s);
- }
#endif
print_dsn_diagnostic_code(addr, fp);
}
+#ifdef EXPERIMENTAL_DSN_INFO
+ else if (testflag(addr, af_pass_message) && (s = addr->message) && *s)
+ dsn_put_wrapped(fp, US"X-Exim-Diagnostic: X-str; ", s);
+#endif
fputc('\n', fp);
}
for (i = 0; i < recipients_count; i++)
if (!tree_search(tree_nonrecipients, recipients_list[i].address))
{
- recipient_item *r = recipients_list + i;
- address_item *new = deliver_make_addr(r->address, FALSE);
+ recipient_item * r = recipients_list + i;
+ address_item * new = deliver_make_addr(r->address, FALSE);
+
new->prop.errors_address = r->errors_to;
#ifdef SUPPORT_I18N
if ((new->prop.utf8_msg = message_smtputf8))
case RECIP_FAIL:
new->message = US"delivery cancelled by administrator";
+ /* not setting af_pass_message here means that will not
+ appear in the bounce message */
/* Fall through */
/* Common code for the failure cases above. If this is not a bounce
The incident has already been logged. */
RECIP_QUEUE_FAILED:
- if (sender_address[0])
+ if (*sender_address)
{
new->next = addr_failed;
addr_failed = new;
Action: failed
Final-Recipient: rfc822;userx@mxt1.test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; lowest numbered MX record points to local host
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;userx@test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; subject was "should fail this" (filter fail)
Action: failed
Final-Recipient: rfc822;abcd@test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; subject was "should fail this" (filter fail)
Action: failed
Final-Recipient: rfc822;usery@test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; subject was "should fail this" (filter fail)
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;userx@badbad.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; unrouteable mail domain "badbad.ex" (:fail:)
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;userx@domain2.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; unrouteable mail domain "domain2.ex" (:fail:)
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;":fail: fail message"@special
Status: 5.0.0
+X-Exim-Diagnostic: X-str; fail message
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;forwarder@test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; Address unknown (:fail:)
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;forwarder@test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; Address unknown (:fail:)
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: text/rfc822-headers
Action: failed
Final-Recipient: rfc822;userx@non-local.example
Status: 5.0.0
+X-Exim-Diagnostic: X-str; unrouteable mail domain "non-local.example" (:fail:)
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;userx@test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; subject was "fail this" (filter fail)
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;failure@myhost.test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; this message is a failure (filter fail)
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;failure1@myhost.test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; This message is being failed and there's a long and
+ tortuous
+ explanation about is that is being sent back to the user.
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;failure2@myhost.test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; delivery cancelled
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;list1@lists.test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; list1@lists.test.ex is a closed mailing list
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;nonlist@lists.test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; nonlist@lists.test.ex is a closed mailing list
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;list1@lists.test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; list1@lists.test.ex is a closed mailing list
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;nonlist@lists.test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; nonlist@lists.test.ex is a closed mailing list
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;userx@test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; forced failure
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;userx@test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; forced failure
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;userx@test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; forced failure
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;userx@test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; forced failure
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: text/rfc822-headers
Action: failed
Final-Recipient: rfc822;userx@test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; all hosts for 'test.ex' have been failing for a long
+ time (and retry time not reached)
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;userx@test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; all hosts for 'test.ex' have been failing for a long
+ time (and retry time not reached)
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;user22@test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; 590 5.4.3 Main and extended code
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;remote_user@remote.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; account disabled
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;remote_user@remote.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; account disabled
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;jack@myhost.test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; LMTP error after end of data: 550 Number 2 fails
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;jack@myhost.test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; LMTP error after end of data: 550 Number 2 fails
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;"FAIL cannot route this one (FAIL)"@some.host
Status: 5.0.0
+X-Exim-Diagnostic: X-str; cannot route this one (FAIL)
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822
Action: failed
Final-Recipient: rfc822;x@test.ex
Status: 5.0.0
+X-Exim-Diagnostic: X-str; no deliveries made locally
--NNNNNNNNNN-eximdsn-MMMMMMMMMM
Content-type: message/rfc822