On 1/23/2013 9:00 AM, rsmits-l wrote: > Hello, > > We have a 'challenge' to make something work. I hope someone can > guide me in the right direction. The following has to take place : > > We have a postfix mailserver which uses relay and virtual files for > incoming and outgoing E-Mail traffic. We must be able to accept a > new incoming relay from google-apps for an address rewrite and > outgoing. But we want to make sure the incoming E-Mail from > google-apps is from google, so we want to make some restrictions : > > 1. The incoming relay is from Google (IP address check) > 2. From address is : ***@google1.com (example)
These two are pretty easy using smtpd_restriction_classes. Define a class that checks for your restricted sender address, then use check_client_access to check for the required client, else reject. http://www.postfix.org/RESTRICTION_CLASS_README.html > 3. Custom X header in the E-Mail. This is unclear. Do you want to add a custom header under particular circumstances? Maybe that can be part of your restriction class with a PREPEND action. Do you want to insure that a particular header exists? Postfix can't do that; you'll need a content inspection filter/proxy/milter such as SpamAssassin. -- Noel Jones