On 2013-10-07, Aurelin <[email protected]> wrote:
>
> Hi all,
>
> My customer wants to be able to send an e-mail with an attached image  
> (up to ~2 MB) to have this posted to their website.
> Now what I set up is a router that forwards the e-mail to a pipe and  
> then gets processed by a scrip. In order to transmit the e-mail to the  
> script, I use the $message_body and $message_body variables, but  
> here's my problem: If the attachment is bigger than ~50 KB, those  
> variables will not hold the entire e-mail text and the attachment is  
> broken (due to the attachment being sent as a base64 encoded string).
> Now my questions are:

> 1. Can I somehow get exim to save the attachment before the e-mail is  
> piped to the script?

possibly I haven't looked into content scanning much.

> 2. Is there a variable that holds the entire e-mail content, without  
> character limitation?

You can read it from the spool file but that's probably not the best
way.

> 3. Would it somehow be possible to change the attachment format from a  
> base64 encoded string to something that uses less characters?

yenc, or 8-bit  use less but not sufficiently less.

> I have tried to change the limit for $message_body, but if I increase  
> it above 99999, the e-mail will be bounced. Also, I have a feeling  
> that this is not the way to go..

Use the pipe transport instead.

Most standard configurations of exim (and other MTAs) accept 
"|/path/to/script-name" as a destination in ~/.forward or in /etc/aliases
 
-- 
⚂⚃ 100% natural

-- 
## List details at https://lists.exim.org/mailman/listinfo/exim-users
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/

Reply via email to