Dear all
i've installed a postfix server with mysql support.
i've also set-up a custom filter script shell that calls spamc and
some other custom utils, this script cannot handle multiple
recipients, so i've set
filter_destination_recipient_limit = 1
The problem that i've experienced is that when i've got an entry like
this in the alias table:
+---------------------------+----------------------------------------------------------------------+----------------------+---------------------+---------------------+--------+
| address | goto
| domain | created
| modified | active |
+---------------------------+----------------------------------------------------------------------+----------------------+---------------------+---------------------+--------+
| [email protected] | [email protected],[email protected],[email protected] |
foo.com | 0000-00-00 00:00:00 | 2009-12-30 17:37:22 | 1 |
+---------------------------+----------------------------------------------------------------------+----------------------+---------------------+---------------------+--------+
Sending an e-mail to [email protected] causes that my script is called 4 times:
[email protected]
[email protected]
[email protected]
[email protected]
and the result is that [email protected],[email protected],[email protected]
receives the mail twice.
postconf -n:
alias_database = hash:/etc/mail/aliases
alias_maps = hash:/etc/mail/aliases
broken_sasl_auth_clients = yes
command_directory = /usr/sbin
config_directory = /etc/postfix
daemon_directory = /usr/libexec/postfix
data_directory = /var/lib/postfix
disable_vrfy_command = yes
html_directory = no
mail_owner = postfix
mailq_path = /usr/bin/mailq
manpage_directory = /usr/local/man
message_size_limit = 100240000
mydestination = $transport_maps
mydomain = foo.com
myhostname = mail.foo.com
myorigin = $mydomain
newaliases_path = /usr/bin/newaliases
queue_directory = /var/spool/postfix
readme_directory = no
relay_domains =
proxy:mysql:/etc/postfix/mysql_relay_domains_maps.cf,hash:/etc/postfix/relay
sample_directory = /etc/postfix
sendmail_path = /usr/sbin/sendmail
setgid_group = postdrop
smtp_host_lookup = native,dns
smtpd_client_connection_count_limit = 50
smtpd_client_restrictions =
permit_sasl_authenticated,permit_mynetworks,reject_non_fqdn_sender,reject_rbl_client
sbl-xbl.spamhaus.org,reject_non_fqdn_hostname,reject_non_fqdn_recipient
smtpd_helo_required = yes
smtpd_helo_restrictions = permit_sasl_authenticated,
permit_mynetworks, reject_invalid_hostname
smtpd_recipient_restrictions =
permit_mynetworks,permit_sasl_authenticated,check_sender_access
hash:/etc/postfix/whitelist/whitelist_reject_non_fqdn_sender,reject_non_fqdn_sender,reject_non_fqdn_sender,reject_unauth_destination,reject_unauth_pipelining,reject_rbl_client
sbl-xbl.spamhaus.org,reject_non_fqdn_hostname,reject_non_fqdn_recipient
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain =
smtpd_sasl_path = sasl2/smtpd
smtpd_sasl_security_options = noanonymous
smtpd_sasl_type = cyrus
smtpd_sender_restrictions =
permit_sasl_authenticated,permit_mynetworks,check_sender_access
hash:/etc/postfix/whitelist/whitelist_reject_non_fqdn_sender,reject_non_fqdn_sender,reject_unknown_sender_domain,reject_non_fqdn_hostname,reject_non_fqdn_recipient
strict_rfc821_envelopes = yes
virtual_alias_maps = mysql:/etc/postfix/mysql_virtual_alias_maps.cf
virtual_gid_maps = static:102
virtual_mailbox_base = /var/spool/postfix/vmail
virtual_mailbox_domains = mysql:/etc/postfix/mysql_virtual_domains_maps.cf
virtual_mailbox_limit = 100240000
virtual_mailbox_maps = mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf
virtual_minimum_uid = 1000
virtual_transport = virtual
virtual_uid_maps = static:1000
master.cf
smtp inet n - n - - smtpd
-o content_filter=filter:dummy
9009 inet n - n - - smtpd
-o content_filter=filter:dummy
filter unix - n n - 20 pipe
flags=Rq user=filter argv=/var/script/filtra_spamc_1.6 -f
${sender} -- ${recipient} ${sasl_username}
Is that behaviour correct?
How can i avoid to call the custom filter for [email protected] ?
Thanks
--
/*************/
nik600
http://www.kumbe.it