Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Mac OS X > Spamassassin on Virtual Hosts (Leopard Server)

Spamassassin on Virtual Hosts (Leopard Server)
Thread Tools
Professional Poster
Join Date: Jan 2000
Location: Stoneham, MA, USA
Status: Offline
Reply With Quote
May 12, 2008, 12:42 AM
 
My server is hosting web and email for a bunch of domains. But spamassassin only filters mail to the primary domain, the one who's name is the server's name. No mail in any of the other domains are getting filtered. Is there some list I have to add these domains to? Or something else I have to do?
     
Clinically Insane
Join Date: Mar 2001
Location: yes
Status: Online
Reply With Quote
May 12, 2008, 08:49 AM
 
SpamAssassin is configured as a milter or content filter of Postfix (or whatever MTA you use). Postfix determines what mail gets spam checked, not SpamAssassin. SpamAssassin will dutifully check any mail passed its way by the MTA. It shouldn't be configured to whitelist by default.

Do the MX records for your domains resolve to different IPs that Postfix is not bound to? What happens when you send mail to these domains (i.e. what is logged?) Can you show us your Postfix configuration?
     
Professional Poster
Join Date: Jan 2000
Location: Stoneham, MA, USA
Status: Offline
Reply With Quote
May 13, 2008, 01:25 AM
 
These domains all point to my server, mail goes through both ways no problems. The only issue is that spamassassin for whatever reason seems to ignore mail from these other domains. Which file exactly do you want to see? I use OS X Server with the Server Admin app to configure thing but i can post any relevant parts of a .cf file if it would help.
     
Clinically Insane
Join Date: Mar 2001
Location: yes
Status: Online
Reply With Quote
May 13, 2008, 01:33 AM
 
How about your Postfix main.cf file and your SA local.cf file? Do these domains have MX records? Do you have any manual SA whitelisting setup (other than SA's auto-whitelist)?

I know nothing about Server Admin, I don't use OS X Server.
     
Professional Poster
Join Date: Jan 2000
Location: Stoneham, MA, USA
Status: Offline
Reply With Quote
May 13, 2008, 03:16 AM
 
Yes all the domains have MX records. All MX records point to their own domains. The only lists i have are realtime blacklists setup in server admin's mail tab.

main.cd is a pretty big file. I've never edited it by hand btw. Is there anything specific you want?
I don't see a local.cf, is it in a different folder?
     
Clinically Insane
Join Date: Mar 2001
Location: yes
Status: Online
Reply With Quote
May 13, 2008, 09:04 AM
 
What is the value of "smtpd_recipient_restrictions" in your main.cf file? Local.cf is your SpamAssassin settings, look for it.
     
Professional Poster
Join Date: Jan 2000
Location: Stoneham, MA, USA
Status: Offline
Reply With Quote
May 13, 2008, 11:20 PM
 
Originally Posted by besson3c View Post
What is the value of "smtpd_recipient_restrictions" in your main.cf file? Local.cf is your SpamAssassin settings, look for it.
smtpd_recipient_restrictions = permit_sasl_authenticated,permit_mynetworks,reject _unauth_destination,permit


I found local.cf, not much in it. nothing I see that would cause it to only filter some domains:
# This is the right place to customize your installation of SpamAssassin.
#
# See 'perldoc Mail::SpamAssassin::Conf' for details of what can be
# tweaked.
#
################################################## #########################
#
# rewrite_subject 0
# report_safe 1
# trusted_networks 212.17.35.

# Bayesian Auto Learn
auto_learn 1

# Safe Reporting
safe_reporting 0

# Full/Terse Reporting
use_terse_report 0

# Subject Tag
subject_tag [x]

# Rewrite the Subject
rewrite_subject 0

# Use Bayesian Filtering
use_bayes 1

# OK locals
ok_locales en

# OK languages
ok_languages en fr de ja

# Required hits to be marked as spam
required_hits 4
     
Clinically Insane
Join Date: Mar 2001
Location: yes
Status: Online
Reply With Quote
May 13, 2008, 11:38 PM
 
Originally Posted by l008com View Post
smtpd_recipient_restrictions = permit_sasl_authenticated,permit_mynetworks,reject _unauth_destination,permit
Is this literally how you have this value set, or is something chopped off here after the last "permit"?

What happens when you do a:

spamassassin --lint ?
     
Clinically Insane
Join Date: Mar 2001
Location: yes
Status: Online
Reply With Quote
May 13, 2008, 11:42 PM
 
Honestly, if you Google search spamassassin, you'll find a ton of people using spamassassin in conjunction with amavis and ClamAV. If it were me, I would totally scrap any stuff that Apple tries to set via the OS X Server GUI and configure your mail environment by hand. I wouldn't trust Server Admin at all, and getting your hands dirty learning about the options that are available to you and how these pieces work will be extremely useful to you, rather than relying on whatever Apple provides in their GUI - obfuscation, bugs and all.

Like I said, there are tons of Postfix + Amavis + SpamAssassin + ClamAV guides out there, this is a very common config (this is what I use too).

Spam checking only certain domains is definitely not the default config, so perhaps this is some goofy thing that Apple is doing via Server Admin.
     
Professional Poster
Join Date: Jan 2000
Location: Stoneham, MA, USA
Status: Offline
Reply With Quote
May 13, 2008, 11:47 PM
 
Yes that is exactly how the line appears. Minus the line break. The whole idea of OS X Server is that i don't want to get my hands dirty. There are many more things I'd rather be doing, and many more things I need to get done. That --lint thing didn't return very positive results though:
[90960] warn: config: failed to parse line, skipping, in "//etc/mail/spamassassin/local.cf": auto_learn 1
[90960] warn: config: failed to parse line, skipping, in "//etc/mail/spamassassin/local.cf": safe_reporting 0
[90960] warn: config: failed to parse line, skipping, in "//etc/mail/spamassassin/local.cf": use_terse_report 0
[90960] warn: config: failed to parse line, skipping, in "//etc/mail/spamassassin/local.cf": subject_tag [x]
[90960] warn: config: failed to parse line, skipping, in "//etc/mail/spamassassin/local.cf": rewrite_subject 0
[90960] warn: config: failed to parse, now a plugin, skipping, in "//etc/mail/spamassassin/local.cf": ok_languages en fr de ja
[90960] warn: lint: 5 issues detected, please rerun with debug enabled for more information
     
Clinically Insane
Join Date: Mar 2001
Location: yes
Status: Online
Reply With Quote
May 14, 2008, 12:08 AM
 
Originally Posted by l008com View Post
Yes that is exactly how the line appears. Minus the line break. The whole idea of OS X Server is that i don't want to get my hands dirty. There are many more things I'd rather be doing, and many more things I need to get done. That --lint thing didn't return very positive results though:

Your config is corrupt then, because there is no argument that is simply "permit".

The problem with your approach here is that sometimes when one tries to take shortcuts, they hit a wall they cannot get past and have to start over. This may be one of those times.

It is not hard to set this stuff up manually, most of the defaults are fine as is.
(Last edited by besson3c; May 14, 2008 at 12:31 AM )
     
Clinically Insane
Join Date: Mar 2001
Location: yes
Status: Online
Reply With Quote
May 14, 2008, 10:46 AM
 
As it turns out, I believe I was wrong about "permit" not being a valid argument
     
Fresh-Faced Recruit
Join Date: May 2008
Status: Offline
Reply With Quote
May 28, 2008, 06:48 AM
 
The following comes from Making Virtual Mail users
in Mac OS X 10.5.x/10.4.x Server by Alex

... in /etc/amavisd.conf :

For Mac OS X 10.5.x:
Search for the parameter that reads:
@local_domains_maps = ( ".$mydomain" );
and change it to:
@local_domains_maps = ( 1 );

For Mac OS X 10.4.x:
Search for the section that reads:
@local_domains_acl = ( ".$mydomain" );
below it add this line:
@local_domains_maps = ( 1 );

Save.
Stop and Start Mail Services
     
   
Thread Tools
 
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 10:37 PM.
All contents of these forums © 1995-2008 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.7.2 © 2000-2008, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.2.0 RC8