Hi Daniel,

On 12-dec-2006, at 1:15, Daniel Kasak wrote:

Hi all. Not specifically a dbmail question, but surely something that people have encountered, as it related to virtual hosting ...

I've noticed that email coming in to our system ( dbmail ==> dspam ==> postfix ) isn't being checked against our list of valid users. Instead of rejecting email to unknown users, they are being passed to dspam, which then dies when it tries to insert a record into the dbmail users table for the new user ( I haven't given dspam permission to insert records ). The worst parts of this are:

- the spammer thinks the message is delivered
- our mail queue is full of delivery failure messages going to unsuspecting individuals who had their 'from' address borrowed by spammers

My /etc/postfix/main.cf has:

local_recipient_maps = mysql:/etc/postfix/sql-recipients.cf

and sql-recipients.cf has:

user = dbmail
password = _______
host = 127.0.0.1
dbname = dbmail
table = dbmail_aliases
select_field = alias
where_field = alias

Also, this works:

screamer postfix # postmap -q [EMAIL PROTECTED] mysql:/ etc/postfix/sql-recipients.cf
[EMAIL PROTECTED]
screamer postfix #

... but this doesn't:

screamer postfix # postmap -q dkasak mysql:/etc/postfix/sql- recipients.cf
screamer postfix #

I'm not sure if that's normal or not, but at least the 1 one shows that postfix is seeing the dbmail users, right?

Yes, that's normal. You've told postfix to look only for aliases and dkasak is not an alias.


Does anyone know why postfix isn't rejecting unknown users?

Entire postfix main.cf:

---

soft_bounce = no
queue_directory = /var/spool/postfix
command_directory = /usr/sbin
daemon_directory = /usr/lib/postfix
mail_owner = postfix
myhostname = mail.nusconsulting.com.au
mydomain = nusconsulting.com.au
myorigin = $mydomain
inet_interfaces = $myhostname, localhost
mydestination = $myhostname
local_recipient_maps = mysql:/etc/postfix/sql-recipients.cf
unknown_local_recipient_reject_code = 550
mynetworks = 10.146.0.0/16 nusconsulting.com.au
relay_domains = nusconsulting.com.au

This doesn't seem right. Why do you have your domain in
relay_domains on the final destination box for that domain?


transport_maps = hash:/etc/postfix/transport
mailbox_transport = dbmail-lmtp:127.0.0.1:24
debug_peer_level = 2
debugger_command =
        PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin
        xxgdb $daemon_directory/$process_name $process_id & sleep 5
sendmail_path = /usr/sbin/sendmail
newaliases_path = /usr/bin/newaliases
mailq_path = /usr/bin/mailq
setgid_group = postdrop
html_directory = /usr/share/doc/postfix-2.3.4/html
manpage_directory = /usr/share/man
sample_directory = /etc/postfix
readme_directory = /usr/share/doc/postfix-2.3.4/readme
home_mailbox = .maildir/
dspam_destination_recipient_limit = 1
dspam-spam_destination_recipient_limit = 1
dspam-ham_destination_recipient_limit = 1
smtpd_recipient_restrictions =
                           permit_mynetworks,
                           reject_unauth_destination,
                           reject_invalid_hostname,
                           reject_non_fqdn_sender,
                           reject_non_fqdn_recipient,
                           reject_unknown_recipient_domain,
                           reject_unauth_pipelining,
                           reject_unknown_sender_domain,
                           reject_rbl_client relays.ordb.org,
                           permit_sasl_authenticated,
                           permit

Leander
_______________________________________________
DBmail mailing list
[EMAIL PROTECTED]
https://mailman.fastxs.nl/mailman/listinfo/dbmail

Reply via email to