O/H mouss έγραψε:
Dimitrios Karapiperis a écrit :
Hi there!
I am using Postfix 2.6 along with GNU Mailman for mailing lists.
My question is
if there is any way to relay e-mails with sender (MAIL FROM) of defined
domain names (eg. x...@domain.tld) originated by a predefined set of ip
addresses
and reject all the others that originate from other ip addresses.
your question is unclear. you may want to show an example.
do you mean that
- if mail comes "from" x...@domain.tld, then
- if IP is in some set, then it's ok
- else reject
if so, then create a restriction class,
smtpd_restriction_class =
...
dont_foo
dont_foo =
check_client_access cidr:/etc/postfix/foo_ok
reject
smtpd_sender_restrictions =
check_sender_acces hash:/etc/postfix/foo_sender
== foo_sender:
j...@example.com dont_foo
Hi
I mean exactly this.
If mail comes from @domain.tld from a predefined set of ips then relay
else if mail comes from @domain.tld from other ips then reject.
For other domains should still function regardless of ips.