Disabling bounce mails

Discuss the Scalix Server software

Moderators: ScalixSupport, admin

FrostyCoolSlug

Disabling bounce mails

Postby FrostyCoolSlug » Fri Jun 01, 2007 8:38 am

Hi,

Is it possible to disable email bounces from scalix when the user is unknown? Or simply return an error at the RCPT TO: phase if the user doesn't exist? Due to the nature of my company, the amount of spam mail received is excessive, and sendmail seems to be choking under the amount of rejection mails it's being forced to send out.

Any help would be appreciated

Thanks

Spirou

Postby Spirou » Sat Jun 02, 2007 10:37 am

Hello FrostyCoolSlug,

one possibility is to add a catchall account and make a rule to delete all e-mails sent to this account:

add

CATCH @example.com spamtrap@example.com

to smtp.conf and restart smtpd. Next add the user spamtrap@example.com and create a rule to delete all incoming messages for this user. (Either via Webmail and rules wizzard or sxaa-tool)

hth

Kurt

adhodgson
Posts: 176
Joined: Thu Mar 02, 2006 8:09 am

Postby adhodgson » Sun Jun 03, 2007 9:31 am

Hi,

Here is how we do it:

1. Add every domain you receive mail for in Scalix to /etc/mail/local-host-names - one per line, like this:

echo domain1.com >>/etc/mail/local-host-names
echo domain2.com >>/etc/mail/local-host-names

Now edit the smtpd.cfg file and find the part where the relay statements are located. You should see the relay accept line for your domain, looks something like this:

RELAY accept .domain.com

Add the rest of your domains to the file in the same format, one per line.

Now restart omsmtp:
omoff -d0 omsmtpd
omon smtpd

What is confusing about this is that the information in the config file seems to indicate that the relay accept .domain.com statement would allow any machine with a PTR record ending in domain.com to relay through the server. After experience, I find that it actually controls the domains allowed in the RCPT to command. Without these lines in the smtpd.cfg file, if someone outside the network attempts to send to an unknown user at your domain, they will receive a message about being denied due to spam list. This is possibly because the omsmtp is going to have to pass the mail through to Sendmail, and possibly cause an open relay. possible clarification on this point would be good, as it caused me a bit of heartache to get right, and obviously by the look of these boards other users as well.

Thanks.
Andrew.

FrostyCoolSlug

Postby FrostyCoolSlug » Mon Jun 04, 2007 9:22 pm

Spirou wrote:Hello FrostyCoolSlug,

one possibility is to add a catchall account and make a rule to delete all e-mails sent to this account:

add

CATCH @example.com spamtrap@example.com

to smtp.conf and restart smtpd. Next add the user spamtrap@example.com and create a rule to delete all incoming messages for this user. (Either via Webmail and rules wizzard or sxaa-tool)

hth

Kurt


It's amazing how simple the solution can be, i was thinking about using things to verify user existence, then send a 551 message if the user didn't exist, but this works exceptionally well. I created the account, added the catch all and put a filter rule in via web mail. The only other thing i did (and i'll put this here in case anyone else needs it), is add the following to crontab:

0,15,30,45 * * * * /opt/scalix/bin/omtidyu -u "Spam Trap" -p "password" -d -q -k -T w -a 0

thus nuking the spamtraps waste basket every 15mins :)

Thanks again for such a simple solution to my spam woes.

Regards
Craig


Return to “Scalix Server”



Who is online

Users browsing this forum: No registered users and 1 guest

cron