Whitelist и Blacklist в postfix

Возникла проблема с подтверждение facebook аккаунтов на ново созданные почтовые ящики, было решено исключить адреса с которых шлет facebook письма из проверок на спам, rbl, graylisting …

Оригинал статьи тут


In this little howto, I will describe, howto configure whitelist and / or blacklist to your postfix installation.

There are two different parameters we can set in postfix, which acts differently.

Blocks by client IP, Client IP Range or Hostname

Block by sender e-mail address (In the FROM field)

#block by client IP, IP range, hostname
check_client_access hash:/etc/postfix/client_checks

#block by sender e-mail address. (In the FROM field)
check_sender_access hash:/etc/postfix/sender_checks

It is important that check_client_access and check_sender_access are defined as some of the first in smtpd_recipient_restrictions.
We do this, so the e-mail is not caught by some of the other filters we have set.

Here is an sample output of the main.cf file.

We will define the whitelist or blacklist with and OK or REJECT, followed by an optional answer text.
OK is allowed
REJECT is block

When a change have been made to any of the files, remember to run postmap, for postfix lookup tables updates, and reload postfix.

That was it, quite simple.

Добавить комментарий

Ваш e-mail не будет опубликован. Обязательные поля помечены *