On Fri, May 7, 2010 at 5:29 PM, Noel Jones <njo...@megan.vbhcs.org> wrote: > On 5/7/2010 2:53 PM, Andrés Gattinoni wrote: >> > Here's an example of a shell script that receives all mail. Shouldn't be > much of a stretch to use PHP instead. > http://www.postfix.org/FILTER_README.html#simple_filter > > If you still want to use amavisd-new, then use multiple postfix instances > for each filter hop. > > Another alternative is to integrate your code into amavisd-new, either as a > custom hook or as a pseudo antivirus scanner. Check the amavis-users > archives for other folks doing similar things.
Thanks for your response Noel. I've checked out that link. The thing is that I don't actually to do any filtering inside my script, I just need to gather some information. Maybe there's an easier way that I can do that without having to call sendmail again. Could you tell me more about how to use multiple postfix instances to keep using amavisd-new? This is what I added to my master.cf to make amavisd-new work. What would I need to add? #the amavis connector, to send to amavis amaviasd-new unix - - - - 2 smtp -o smtp_data_done_timeout=1200 -o smtp_send_xforward_command=yes -o disable_dns_lookups=yes #The amavis receiver 127.0.0.1:10026 inet n - y - - smtpd -o content_filter= #Stop Postfix from cleaning emails before sending to amavis pre-cleanup unix n - y - 0 cleanup -o virtual_alias_maps= -o canonical_maps= -o sender_canonical_maps= -o recipient_canonical_maps= -o masquerade_domains= #Regular messsages can get cleaned up cleanup unix n - y - 0 cleanup -o mime_header_checks= -o nested_header_checks= -o body_checks= -o header_checks= smtp inet n - n - - smtpd -o cleanup_service_name=pre-cleanup submission inet n - n - - smtpd -o cleanup_service_name=pre-cleanup pickup fifo n - y 60 1 pickup -o cleanup_service_name=pre-cleanup I would checkout the idea of the hook for amavisd-new. Maybe if it's not to messy it could be a good solution. Regards, A