On Mon, Dec 29, 2008 at 03:45:05PM +0200, D. Karapiperis wrote: > > > Hi All > > > >I have a question regarding postfix restrictions. > > > >Is there a way for Postfix to enforce some kind of policy so that all > >the outgoing (allowed) mails be " @business.com" and all the others be > >rejected. > >Of course this policy should be enforced only to the outgoing emails > >not in the incoming. > > > > > - if mail comes from mynetworks, require that the sender address is > *...@example.com. you can do this with a restriction class based on > check_client_access. > > > Thanks for the reply > > I did this > > mynetworks = cidr:/etc/postfix/inside_network > > smtpd_restriction_classes= > from_inside_network > > from_inside_network = > check_client_access cidr:/etc/postfix/inside_network > > > smtpd_recipient_restrictions = > check_sender_access hash:/etc/postfix/sending-domains, > reject_unauth_destination > > > > /etc/postfix/inside_network > 192.168.2.0/24 OK > 127.0.0.0/8 OK > > > /etc/postfix/sending-domains > business.gr from_inside_network > > So I did a logical AND -> all clients form my network have the relay > privilege and moreover they can send e-mails only from business.gr > (hopefully) > I need to test it on a production server.
THis is really broken, don't do this. -- Viktor. Disclaimer: off-list followups get on-list replies or get ignored. Please do not ignore the "Reply-To" header. To unsubscribe from the postfix-users list, visit http://www.postfix.org/lists.html or click the link below: <mailto:majord...@postfix.org?body=unsubscribe%20postfix-users> If my response solves your problem, the best way to thank me is to not send an "it worked, thanks" follow-up. If you must respond, please put "It worked, thanks" in the "Subject" so I can delete these quickly.