[exim] Filtering MIME Parts

Top Page
Delete this message
Reply to this message
Author: Patrick Donahue
Date:  
To: exim-users
Subject: [exim] Filtering MIME Parts
Hello,

I'm currently using exim and faxmail (http://linux.die.net/man/1/faxmail) to
route messages to Hylafax (http://www.hylafax.org). Users attach the PDFs
they would like to fax and send the email to 1XXXXXXXXXX@???.
Unfortunately, when users send these messages from Outlook they come through
as multipart MIME entities and the first few pages of the fax are filled
with garbage. Here are the MIME parts:

1. The body as HTML or alternatively ASCII
2. The PDF attachment

I'd like to somehow strip out #1 so that only the PDF is passed along. (Even
if the users delete the contents of the body, Outlook still nicely includes
some HTML formatting). While a simple answer may be "don't use Outlook", we
don't have that option so I need to handle this on the exim side.

The messages get routed to faxmail using a router regular expression that
sends to a faxmail transport that pipes to the application. I've thought
about using a transport filter, but this seems quite brittle. Any other
solutions out there?

Thanks