ML a écrit : > Hi, > > I wonder how to bypass a dspam filter for some sender only (aka a filter > whitelist), the issue is that i'm using a double filtering system : > > [snip] > 127.0.0.1:10028 inet n - n - 16 smtpd > -o content_filter=dspam:unix:/var/run/dspam.sock > -o > receive_override_options=no_unknown_recipient_checks,no_header_body_checks,no_address_mappings > > -o smtpd_helo_restrictions= > -o smtpd_client_restrictions= > -o smtpd_sender_restrictions= > -o smtpd_recipient_restrictions=permit_mynetworks,reject > -o mynetworks_style=host > -o smtpd_authorized_xforward_hosts=127.0.0.0/8 > dspam unix - - n - 5 lmtp > -o lmtp_send_xforward_command=yes > > the antivirus filter (clamsmtpd) send back to 127.0.0.1:10028 using > smtp, postfix send to dspam using LMTP, and dspam send back to postfix > for delivery using SMTP again on 10025 > > now how to bypass dspam for some *senders* ? > > i planned to use an option on 127.0.0.1:10028 this way : > -o smtpd_sender_restrictions=check_sender_access > hash:/usr/local/etc/postfix/dspam_whitelist > where dspam_whitelist would contain a fake filter : > [EMAIL PROTECTED] FILTER scan:[127.0.0.1]:10025 > > but of course this doesn't work because spaces are not allowed after -o > smtpd_sender_restrictions= (fatal: unexpected command-line argument: > hash:/usr/local/etc/postfix/dspam_whitelist) > > so, how to achieve this ? >
use a custom variable that you define in main.cf. something like this: -o smtpd_sender_restrictions=${smtpd10028_sender_restrictions} and define smtpd10028_sender_restrictions = .... in main.cf