Postfix – Only Allow Specfic Recipient Domains

Step 1.Open /etc/postfix/main.cf & enter below line at end

transport_maps = hash:/etc/postfix/transport

Step 2:Open /etc/postfix/transport & need to insert line specifying which domain should be allowed as below:

test.com :
* discard:

Step 3:Now need to create a hash of the file
postmap /etc/postfix/transport

Step 4:Finally reload or restart postfix and you are done.

Comments are closed.