I'm looking to embed a Perl script somewhere to interact with Postfix's SMTPD agent. Basically I do not want to determine whether a message gets injected back into the postfix queue or not. I simply want to parse the message, stuff some data into a database using DBI, and let postfix handle the rest. I need to know where in Postfix I can pipe my perl script into to handle this technique.
Could you specify what you do want the perl script to do? Do you want postfix under certain conditions to pass the message to the perl script? Or do you want the perl script to be a pass through mechanism that will allow the script to extract certain data and then let postfix finish the delivery?