Addition/Always accept messages for special aliases

Mission

Reason

You should always allow to be contacted on the four special aliases listed above.
For example, in certain circumstances another postmaster from an external domain would like to contact you about messages coming from his server and considered spam by your local server and not delivered because of a misconfiguration.

Step-by-step configuration

Requirements:

A properly working iRedMail system;

Note:

This article was written with a CentOS-based system in mind. Adapt it for your system.

Step 1.

Create the lookup table /etc/postfix/accept_special with the following contents (a regular text file):

File:

abuse@ OK
postmaster@ OK
webmaster@ OK
hostmaster@ OK

Step 2.

Compile the above file using postmap, type hash:

Terminal:

cd /etc/postfix
postmap hash:accept_special

Step 3.

Check that the file /etc/postfix/accept_special.db exists.

Step 4.

Edit /etc/postfix/main.cf and add the accept_special.db lookup table to smtpd_recipient_restrictions, to a place in the rule chain you see fit for your server:

The place where you add it is quite important. For example, I choosed not to add it further above, so I can cut down on the amount of spam I receive on the special aliases. You might want to add it further above or below in the rule chain.

For usual iRedMail configuration that's the recommended place to add it.

Step 5.

Restart postfix service and make sure everything is working ok by tail-ing the logs.