On 10/24/2016 9:24 AM, Nikolaos Milas wrote: > On 24/10/2016 5:15 μμ, Fazzina, Angelo wrote: > >> Can't you use REGEX to write a rule to catch them, and then decide >> what you want to do with those emails ? > > Would the following be valid? > > smtpd_recipient_restrictions = > ... > check_sender_access hash:/etc/postfix/blacklisted_senders > header_checks pcre:/etc/postfix/blacklisted_maillists > ... > > /etc/postfix/blacklisted_maillists > > /^Return-Path: <oursuperclub-members+bnc(.*)@googlegroups.com>/ > REJECT > > Nick >
header_checks can't be used there. Use a second check_sender_access instead. smtpd_recipient_restrictions = ... check_sender_access hash:/etc/postfix/blacklisted_senders check_sender_access pcre:/etc/postfix/blacklisted_maillists ... /etc/postfix/blacklisted_maillists /^oursuperclub-members+bnc(.*)@googlegroups\.com$/ REJECT superclub not allowed -- Noel Jones