{"id":328,"date":"2015-01-27T20:00:57","date_gmt":"2015-01-27T19:00:57","guid":{"rendered":"http:\/\/www.anginf.de\/?p=328"},"modified":"2015-01-28T14:57:54","modified_gmt":"2015-01-28T13:57:54","slug":"postfix-reject-some-recipient-adresses-while-using-catchall-on-a-domain","status":"publish","type":"post","link":"https:\/\/www.anginf.de\/?p=328","title":{"rendered":"postfix: Reject some recipient adresses while using catchall on a domain"},"content":{"rendered":"<p>If you have a catchall on a domain &#8211; like anginf.de &#8211; you will probably get spam on some adresses which you would like to exclude from the general catchall. This can be achieved by doing some simple steps.<\/p>\n<p>First you have to create a file <code>\/etc\/postfix\/recipient_block<\/code> with all those email adresses you want rejected:<\/p>\n<pre lang=\"bash\">\r\nspam@anginf.de REJECT\r\nmorespam@anginf.de REJECT\r\n<\/pre>\n<p>To be useable for postfix, you have to <code>postmap<\/code> this file.<\/p>\n<pre lang=\"bash\">\r\nroot@host:~# postmap \/etc\/postfix\/recipient_block\r\n<\/pre>\n<p>In your <code>\/etc\/postfx\/main.cf<\/code>, add a new line to your <code>smtpd_recipient_restrictions<\/code>:<\/p>\n<pre lang=\"bash\">\r\nhash:\/etc\/postfix\/recipient_block\r\n<\/pre>\n<p>Now you only have to reload postfix and all mails to those mentioned in <code>\/etc\/postfix\/recipient_block<\/code> will be rejected:<\/p>\n<pre lang=\"bash\">\r\nroot@host:~# service postfix reload\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>If you have a catchall on a domain &#8211; like anginf.de &#8211; you will probably get spam on some adresses which you would like to exclude from the general catchall. This can be achieved by doing some simple steps. First you have to create a file \/etc\/postfix\/recipient_block with all those email adresses you want rejected: &hellip; <a href=\"https:\/\/www.anginf.de\/?p=328\" class=\"more-link\"><span class=\"screen-reader-text\">postfix: Reject some recipient adresses while using catchall on a domain<\/span> weiterlesen <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-328","post","type-post","status-publish","format-standard","hentry","category-allgemein"],"_links":{"self":[{"href":"https:\/\/www.anginf.de\/index.php?rest_route=\/wp\/v2\/posts\/328","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.anginf.de\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.anginf.de\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.anginf.de\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.anginf.de\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=328"}],"version-history":[{"count":3,"href":"https:\/\/www.anginf.de\/index.php?rest_route=\/wp\/v2\/posts\/328\/revisions"}],"predecessor-version":[{"id":331,"href":"https:\/\/www.anginf.de\/index.php?rest_route=\/wp\/v2\/posts\/328\/revisions\/331"}],"wp:attachment":[{"href":"https:\/\/www.anginf.de\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=328"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.anginf.de\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=328"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.anginf.de\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=328"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}