procmail
[Top] [All Lists]

howto forwarding a part of a multipart message

2005-05-03 13:02:11
I'm new using procmail.

I have a mail which has 3 parts and the third part has attachments.
This is because a notification of a failure sending the original mail.

What i need is filter by the subject of the third part and then foward
the complete third part (original message) to an e-mail address.

I need help writting the filter criteria in the .rc file. I was trying
some but i didn't find the solution.

I have a lot of this kind of mail mixed with anothers, that's why I
want to find a automatic soluction.

Here, I attach how a message looks using pine:

Date: Sat, 12 Feb 2005 00:38:11 -0600 (CST)
From: Mail Delivery System 
<MAILER-DAE(_dot_)(_dot_)(_dot_)(_at_)machine(_dot_)domain>
To: u(_dot_)(_dot_)(_dot_)(_at_)machine(_dot_)domain
Subject: Undelivered Mail Returned to Sender
Parts/Attachments:
   1   Shown     14 lines  Text, "Notification"
   2   Shown    288 bytes  Message, "Delivery error report"
   3   Shown     50 KB     Message, "Undelivered Message"
   3.1 Shown      2 lines  Text
   3.2          211 bytes  Application
   3.3           23 KB     Application
   3.4          396 bytes  Application
   3.5          1.4 KB     Application
   3.6           39 bytes  Application
   3.7          196 bytes  Application
   3.8          1.5 KB     Application
   3.9          8.6 KB     Application
----------------------------------------

This is the Postfix program at host machine.domain.

I'm sorry to have to inform you that the message returned
below could not be delivered to one or more destinations.

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 message returned below.

                        The Postfix program

<recipi(_dot_)(_dot_)(_dot_)(_at_)recipientmachine(_dot_)domain>: 
[recipientmachine.domain]: Name
    or service not known

    [ Part 2: "Delivery error report" ]

Reporting-MTA: dns; machine.domain
Arrival-Date: Sat, 12 Feb 2005 00:38:04 -0600 (CST)

Final-Recipient: rfc822; 
recipi(_dot_)(_dot_)(_dot_)(_at_)recipientmachine(_dot_)domain
Action: failed
Status: 5.0.0
Diagnostic-Code: X-Postfix; [recipientmachine.domain: Name or service
not
    known

    [ Part 3: "Undelivered Message" ]

Date: Sat, 12 Feb 2005 00:38:04 -0600 (CST)
From: r(_dot_)(_dot_)(_dot_)(_at_)machine(_dot_)domain
To: recipi(_dot_)(_dot_)(_dot_)(_at_)recipientmachine(_dot_)domain
Subject: Bitácoras - 2005/02/12 00:38:01 CST

Date: 2005-02-12T00:38:01-0600
Host: machine.domain

    [ Part 3.2, Application/OCTET-STREAM (Name: "arch1.log.gz")
282bytes. ]
    [ Cannot display this part. Press "V" then "S" to save in a file. ]

    [ Part 3.3, Application/OCTET-STREAM (Name: "arch2.log.gz")  30KB.
]
    [ Cannot display this part. Press "V" then "S" to save in a file. ]

    [ Part 3.4, Application/OCTET-STREAM (Name: "arch3.log.gz")
528bytes. ]
    [ Cannot display this part. Press "V" then "S" to save in a file. ]

    [ Part 3.5, Application/OCTET-STREAM (Name: "arch4.log.gz")  1.9KB.
]
    [ Cannot display this part. Press "V" then "S" to save in a file. ]

    [ Part 3.6, Application/OCTET-STREAM (Name: "arch5.log.gz")
52bytes. ]
    [ Cannot display this part. Press "V" then "S" to save in a file. ]

    [ Part 3.7, Application/OCTET-STREAM (Name: "arch6.log.gz")
262bytes. ]
    [ Cannot display this part. Press "V" then "S" to save in a file. ]

    [ Part 3.8, Application/OCTET-STREAM (Name: "arch7.log.gz")  2.1KB.
]
    [ Cannot display this part. Press "V" then "S" to save in a file. ]

    [ Part 3.9, Application/OCTET-STREAM (Name: "arch8.log.gz")  11KB.
]
    [ Cannot display this part. Press "V" then "S" to save in a file. ]

Thanks in advance.


____________________________________________________________
procmail mailing list   Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail


<Prev in Thread] Current Thread [Next in Thread>