How do I strip email attachments server side, or send email with attachments to a different address?
January 29, 2004 8:07 PM Subscribe
How do I strip email attachments server side? Or, alternatively, how do I redirect email containing binary attachments to an alternate email address? I own my own domain and, because I am forced to use Outlook, I don't want attachments touching my inbox. [more inside]
My initial thought was to use procmail, but all the procmail approaches I've seen appear clunky and unreliable, at best. Then again, this is not my forte, so maybe I just don't understand what I'm looking at.
My domain is pretty much full-featured, and I'm willing to switch hosting providers to get the tools I need to do this job right. So any practical technology solution is fair game.
Thanks in advance. I appreciate it.
My initial thought was to use procmail, but all the procmail approaches I've seen appear clunky and unreliable, at best. Then again, this is not my forte, so maybe I just don't understand what I'm looking at.
My domain is pretty much full-featured, and I'm willing to switch hosting providers to get the tools I need to do this job right. So any practical technology solution is fair game.
Thanks in advance. I appreciate it.
what's the problem with procmail (why does it look unreliable)? it's not inherently unreliable (it's the standard mail filtering tool, used everywhere - as i guess you know). is the problem how to select the right messages? if it's just that procmail is complicated, i'd suggest asking a procmail mailing list (or discussion group or wiki or whatever the appropriate support group is).
i don't have to deal with outlook, but i do a simple filter of all incoming messages over a certain size (i also filter based on sender, check against black lists and call spam-assassin). it works reliably.
posted by andrew cooke at 4:07 AM on January 30, 2004
i don't have to deal with outlook, but i do a simple filter of all incoming messages over a certain size (i also filter based on sender, check against black lists and call spam-assassin). it works reliably.
posted by andrew cooke at 4:07 AM on January 30, 2004
Response by poster: what's the problem with procmail
Procmail is great - for what it does. But it doesn't appear to have been designed for this sort of task, and as a result it doesn't appear to be great at recognizing or dealing with binary attachments.
Then again, maybe I just don't know what I'm talking about. Filtering by size isn't a perfect solution, but it might work in most cases. I hadn't thought of that.
fvw may be on to something with his suggestion. I don't know anything about perl, but I'm looking into it.
Why are you forced to use Outlook?
Because I use NEO. I get far too much email each day to function without it.
posted by gd779 at 8:07 AM on January 30, 2004
Procmail is great - for what it does. But it doesn't appear to have been designed for this sort of task, and as a result it doesn't appear to be great at recognizing or dealing with binary attachments.
Then again, maybe I just don't know what I'm talking about. Filtering by size isn't a perfect solution, but it might work in most cases. I hadn't thought of that.
fvw may be on to something with his suggestion. I don't know anything about perl, but I'm looking into it.
Why are you forced to use Outlook?
Because I use NEO. I get far too much email each day to function without it.
posted by gd779 at 8:07 AM on January 30, 2004
NEO claims to "Effortlessly transform Microsoft Outlook into a complete email organizer." Wouldn't it be easier to just use a good e-mail program in the first place, rather than using Outlook plus a third-party add-on to bring it up to par?
posted by kindall at 12:10 PM on January 30, 2004
posted by kindall at 12:10 PM on January 30, 2004
Response by poster: Wouldn't it be easier to just use a good e-mail program in the first place
Over the years, I've used just about every email program out there, from The Bat! to PicoMail to Netscape to Pine, and nothing lets me handle email as efficiently as NEO. (Well, Pine's more efficient in terms of raw keystroke speed, but NEO makes it easier to track relationships and email history, which is important to me and makes NEO more efficient on the whole).
Using NEO, I cut my time spent on email down from about 2 hours a day to about 30 minutes, plus I'm much more organized, which means I never miss the important emails in the mass of unimportant emails, and I never lose track of the emails I really want to read but don't have time for right now. Plus it's zero-configuration, which I think is an important value in personal information management software.
I'm sorry, I sound like a commercial here, so I'll stop. I just really like the program.
posted by gd779 at 12:51 PM on January 30, 2004
Over the years, I've used just about every email program out there, from The Bat! to PicoMail to Netscape to Pine, and nothing lets me handle email as efficiently as NEO. (Well, Pine's more efficient in terms of raw keystroke speed, but NEO makes it easier to track relationships and email history, which is important to me and makes NEO more efficient on the whole).
Using NEO, I cut my time spent on email down from about 2 hours a day to about 30 minutes, plus I'm much more organized, which means I never miss the important emails in the mass of unimportant emails, and I never lose track of the emails I really want to read but don't have time for right now. Plus it's zero-configuration, which I think is an important value in personal information management software.
I'm sorry, I sound like a commercial here, so I'll stop. I just really like the program.
posted by gd779 at 12:51 PM on January 30, 2004
gd779: Predicated on your being root (or able to otherwise su mail) on the mail servers in question, what you're looking for is a combination of the Exim MTA, the < href="http://duncanthrax.net/exiscan-acl/">exiscan patches along with the various utilities it uses to cope with attachments, and basic procmail rules.
If your stiffed with another MTA, look into its filtering and tagging possibilities. sendmail offers something called "milters" that seem to be capable of some of this functionality. Postfix probably has something as well, although I'm not familiar enough with it to say what that is. There's pretty much no excuse not to be using Exim in modern times.
If you've only got control of MDA or MUA, Procmail is going to have to do. You'll be writing some shell scripts to string together mime-defang and such to implement your rules. Not pretty, but doable.>
posted by majick at 2:22 PM on January 30, 2004
If your stiffed with another MTA, look into its filtering and tagging possibilities. sendmail offers something called "milters" that seem to be capable of some of this functionality. Postfix probably has something as well, although I'm not familiar enough with it to say what that is. There's pretty much no excuse not to be using Exim in modern times.
If you've only got control of MDA or MUA, Procmail is going to have to do. You'll be writing some shell scripts to string together mime-defang and such to implement your rules. Not pretty, but doable.>
posted by majick at 2:22 PM on January 30, 2004
Response by poster: Thanks, majick. Following on your suggestion, I think I've found a working solution. After some more testing, I'll come back here and post the details in case anyone with the same question ever finds this post using Google.
posted by gd779 at 12:52 PM on January 31, 2004
posted by gd779 at 12:52 PM on January 31, 2004
This thread is closed to new comments.
posted by fvw at 8:34 PM on January 29, 2004