Le 14/06/2011 04:21, Janantha Marasinghe a écrit :
> Thanks Sahil
> 
> Basically What i want to check is when a mail is recieved from postfix
> if it can reject the e-mail is the sending e-mail server is in the
> blacklist rbl
> 
> smtpd_recipient_restrictions is about "Mail To:" right. So if I have an
> e-mail account on my postfix server and the spammer says "mail to"
> address it will still pass ? Am I correct?
> 


you are confusing
- the stage at which a check is done (smtp_recipient_restrictions,
smtpd_client_restrictions, ...)

- the nature of the check (check_client_access, ... reject_rbl_client, ...)

for a starter, begin by putting all your checks under
smtpd_recipient_restrictions. here is a "pedagogic" example. (obviously,
this is not a copy-paste sample)

smtp_recipient_restrictions =
        reject_non_fqdn_sender
        reject_non_fqdn_recipient
        #
        permit_sasl_authenticated
        permit_mynetworks
        reject_unauth_destination
        #
        reject_unlisted_recipient
        reject_unlisted_sender
        #
        reject_invalid_helo_hostname
        reject_non_fqdn_helo_hostname
        reject_unknown_reverse_client_hostname
        #
        check_recipient_access                  ${db}/access_recipient
        #whitelists
        check_client_access                     ${cidr}/access_client
        check_client_access                     ${db}/access_client
        check_client_access                     ${dnswl}
        #!notyet!permit_dnswl_client swl.spamhaus.org
        #!notyet!permit_dnswl_client list.dnswl.org
        #
        reject_rbl_client                       zen.spamhaus.org
        reject_rhsbl_sender                     dbl.spamhaus.org
        #reject_rhsbl_client                    dbl.spamhaus.org
        reject_rhsbl_reverse_client             dbl.spamhaus.org
        #
        reject_rbl_client                       bl.spamcop.net
        reject_rbl_client                       psbl.surriel.com
        reject_rbl_client                       korea.services.net
        ....

Reply via email to