Hi all.
I usually receive DSN messages from my postfix in the format as below.
They are sent to a script for regex analysis.
My question: is there a way to customize these "undelivered mail" messages
when thay come from emails not delivered because max lifetime in the queue
is expired?
It seems like a lifetime-expired-bounce message has the same
format/text/codes as a normal bounce for "user or domain not found". Or is
there any way to identify former messages (= lifetime-expired ones) looking
for some error codes, strings, etc. ?
Thank you very much for your help.
-Francesco

-------------------- Bounce message example obtained when queue lifetime was
expired on my postfix -------------------------------------------------
>From MAILER-DAEMON  Tue Oct  4 17:57:08 2016
Return-Path: <>
X-Original-To: [email protected]
Delivered-To: [email protected]
Received: by mx4.gggg.it (Postfix)
        id 03D28CE450; Tue,  4 Oct 2016 17:57:01 +0200 (CEST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gggg.it; s=default;
        t=1475596621; bh=qSsNQZkXj2y3zLnJB4Jq1e1C6Xz/rIerI6S66JHdb2A=;
        h=Date:From:Subject:To:MIME-Version:Content-Type:Message-Id;
        b=QE7N+oIVDQawNpiBAgiYG8X1MNEzzcsCF3uVoq3ZULwA08meYbAUlNGudawvXb0yH
         PP6WGMm6g81yM5FNphCr0XTSmUl5IHCc6oWRhsSejXg3N9PxzxHDbvXYow/F+MQxeO
         xMLDS0aSKpr7ZUAE5r6ZHjymUFLhwuAQG2nmkQdA=
Date: Tue,  4 Oct 2016 17:57:01 +0200 (CEST)
From: [email protected] (Mail Delivery System)
Subject: Undelivered Mail Returned to Sender
To: [email protected]
Auto-Submitted: auto-replied
MIME-Version: 1.0
Content-Type: multipart/report; report-type=delivery-status;
        boundary="D2778CF145.1475596621/mx4.gggg.it"
Message-Id: <[email protected]>

This is a MIME-encapsulated message.

--D2778CF145.1475596621/mx4.gggg.it
Content-Description: Notification
Content-Type: text/plain; charset=us-ascii

This is the mail system at host mx4.gggg.it.

I'm sorry to have to inform you that your message could not
be delivered to one or more recipients. It's attached below.

For further assistance, please send mail to postmaster.

If you do so, please include this problem report. You can
delete your own text from the attached returned message.

                   The mail system

<[email protected]>: delivery temporarily suspended: lost connection with
    mx4.hotmail.com[65.55.92.152] while sending RCPT TO

--D2778CF145.1475596621/mx4.gggg.it
Content-Description: Delivery report
Content-Type: message/delivery-status

Reporting-MTA: dns; mx4.gggg.it
X-Postfix-Queue-ID: D2778CF145
X-Postfix-Sender: rfc822; [email protected]
Arrival-Date: Thu, 29 Sep 2016 17:22:35 +0200 (CEST)

Final-Recipient: rfc822; [email protected]
Original-Recipient: rfc822; [email protected]
Action: failed
Status: 4.4.2
Diagnostic-Code: X-Postfix; delivery temporarily suspended: lost connection
    with mx4.hotmail.com[65.55.92.152] while sending RCPT TO

--D2778CF145.1475596621/mx4.gggg.it
Content-Description: Undelivered Message
Content-Type: message/rfc822
[.....]


---
Questa e-mail è stata controllata per individuare virus con Avast antivirus.
https://www.avast.com/antivirus

Reply via email to