* Wietse Venema <wie...@porcupine.org> [2012-04-04 01:22]:
> To soft-reject unknown recipients in selected domains, in mail from
> clients outside the local network, request defer_if_reject at the end
> of smtpd_recipient_restrictions:
> 
> /etc/postfix/main.cf:
>     smtpd_recipient_restrictions =
>       permit_mynetworks
>       ...
>       reject_unauth_destination
>       ...
>       check_recipient_access hash:/etc/postfix/final_rcpt_access
> 
> /etc/postfix/final_rcpt_access:
>     example.com defer_if_reject
> 
> This is approximately the solution that Rob0 proposed.

Hi,

this works for me, but I put the check before my greylist/whitelist
lines:

smtpd_recipient_restrictions =
    permit_mynetworks,
    permit_inet_interfaces,
    permit_sasl_authenticated,
    reject_unauth_destination,
    reject_unauth_pipelining,
    check_recipient_access hash:$config_directory/defer_unkown_users, <---- here
    # Prevent greylisting for known "good" senders
    permit_dnswl_client list.dnswl.org,
    # Do greylisting for a few users/domains
    check_recipient_access pcre:$config_directory/greylist.pcre

I did debug the smtp connections as I wasn't sure if a
"defer_if_reject" lookup match would prevent the following checks to
run but that's not the case.

Thanks again for all your help!

Regards

Sebastian

-- 
GPG Key: 0x93A0B9CE (F4F6 B1A3 866B 26E9 450A  9D82 58A2 D94A 93A0 B9CE)
'Are you Death?' ... IT'S THE SCYTHE, ISN'T IT? PEOPLE ALWAYS NOTICE THE SCYTHE.
            -- Terry Pratchett, The Fifth Elephant

Reply via email to