- To: "Peter Rundle" <prundle@xxxxxxxxxxxxxx>, <slug@xxxxxxxxxxx>
- Subject: RE: [SLUG] Program to detach e-mail attachment
- From: "Roger Barnes" <Roger.Barnes@xxxxxxx>
- Date: Wed, 6 Jul 2005 09:47:00 +1000
- Thread-index: AcWBu04wAnKynIndQJ2TEYXvXdgX3wAABX6A
- Thread-topic: [SLUG] Program to detach e-mail attachment
> looking for some pointers on getting together some code to
> auto process incoming e-mails, detach their attachments and
> save them as files. The MTA is qmail so the appropriate
> "|myprog" entry in .qmail gets the mail passed to the program
> then I need to code up something that will take the
> attachment, detach & decode it and save it as a file.
Give munpack a try, I think it's available in many distributions all packaged up (as "mpack"). I have a procmail recipe thus ...
| munpack -f -q -C /somepath/
HTH, YMMV, etc. :)
- Rog