Basically we utilise a multidrop system that dumps all incoming mail throughout our domain into 1 pop3 account. We collect this using fetchmail and sendmail processes and delivers it to the correct mailbox.
We get a lot of our office mail coming in Bcc: We are having problems getting Fetchmail/Sendmail to deal with this properly. Nemely our ISP server doesn't rewrite the headers properly, so that the address goes into the received header, so sendmail doesn't have any idea what to do with it.
Any ideas? Does anybody know of a replacement to fetchmail that might do this job better?
I haven't used fetchmail for ages, but I believe you can configure it to deliver the mail to any program of your liking.
I don't know of any MTA that would rewrite headers as you describe (on your ISP's server), leaving you with very little way of deciding which address an email was orginally BCC'ed to.
If you can convince fetchmail to deliver the incoming mail to a home made program, it shouldn't be too hard to make a program that tries to extract the BCC'ed address from a Received line and then forwards the message to that address.