Specify DNSBL reject code in postscreen reply map?

Previous Topic Next Topic
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Specify DNSBL reject code in postscreen reply map?

I'm trying to understand reply maps' use.  Specifically postscreen's.

If I set up config in main.cf as

    default_rbl_reply = $rbl_code [P4] Service unavailable; $rbl_class [$rbl_what] blocked using $rbl_domain${rbl_reason?; $rbl_reason}

    postscreen_dnsbl_reply_map = pcre:/etc/postfix/postscreen_dnsbl_reply_map.pcre

    rbl_reply_maps = ${stress?lmdb:/etc/postfix/rbl_reply_maps}


    b.barracudacentral.org= 521 4.7.1 Service unavailable;
     $rbl_class [TEST1] [$rbl_what] blocked using
     $rbl_domain${rbl_reason?; $rbl_reason}

/etc/postfix/postscreen_dnsbl_reply_map.pcre                                                                                                                    /barracudacentral\.org$/    [TEST2] DNSBL[Barracuda]

When postscreen hits on a Barracuda DNSBL, my logs show

    Sep  3 02:12:55 virt1 postfix/postscreen[53233]: NOQUEUE: reject: RCPT from []:5897: 550 5.7.1 Service unavailable; client [] blocked using [TEST2] DNSBL[Barracuda]; from=<[hidden email]>, to=<[hidden email]>, proto=SMTP, helo=<mail.com>

So obviously the postscreen_dnsbl_reply_map is kicking in.

But it's rejecting with the default "550 5.7.1".

What do I need to edit if I want to postscreen to reject -- in this example -- Barracuda hits with "521 4.7.1", leaving the default as-is?