Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I want to start an indepth discussion on all ways of avoiding mail being flagged as spam. I have done most of what i knew to prevent mail from being listed as spam. i have tried the following

1) using phpmailer to setup appropriate headers 2) used SPF correctly 3) implemented DKIM correctly 4) my sender score is 93 https://www.senderscore.org/lookup.php?lookup=50.57.111.177&ipLookup.x=55&ipLookup.y=9

I have even gone as far as asking hotmail etc to add me to a permited sender policy.

all these have been all in vain. below is a header i get from my gmail account. and the mail is still flagged as spam.

Delivered-To: jorfergie03@gmail.com
Received: by 10.220.15.207 with SMTP id l15cs5000vca;
        Wed, 26 Oct 2011 05:33:28 -0700 (PDT)
Received: by 10.42.135.66 with SMTP id o2mr18662906ict.0.1319632407924;
        Wed, 26 Oct 2011 05:33:27 -0700 (PDT)
Return-Path: <apache@veepiz.com>
Received: from veepiz.com (veepiz.com. [50.57.111.177])
        by mx.google.com with ESMTP id x1si830537icv.118.2011.10.26.05.33.27;
        Wed, 26 Oct 2011 05:33:27 -0700 (PDT)
Received-SPF: pass (google.com: domain of apache@veepiz.com designates 50.57.111.177 as permitted sender) client-ip=50.57.111.177;
Authentication-Results: mx.google.com; spf=pass (google.com: domain of apache@veepiz.com designates 50.57.111.177 as permitted sender) smtp.mail=apache@veepiz.com; dkim=pass header.i=@veepiz.com
Received: from veepiz.com (localhost [127.0.0.1])
    by veepiz.com (Postfix) with ESMTP id 90FC6164356
    for <jorfergie03@gmail.com>; Wed, 26 Oct 2011 12:33:27 +0000 (UTC)
X-DKIM: OpenDKIM Filter v2.4.1 veepiz.com 90FC6164356
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=veepiz.com;
    s=default; t=1319632407;
    bh=Yx04NJ7TwKKjTvy0uhLTyTJZD9zjcioUaHvOP32UGOw=;
    h=To:Subject:Date:From:Reply-to:Message-ID:MIME-Version:
     Content-Type;
    b=dqOcgQInMj5B5JZv6sFIEVcrscrj+ayYAMf4OnOVQokEmcluMkUpRnEfyEo7NkL3t
     T84oTZIroG3yjdU9oqfUCNg9s/14zmbPbqE7j9cPLAsBOrfdMVfnl8b2YLBGS9nuh2
     0if4pjJBtFOjdduCp29DiWj9qg8BTZEiqFSOckoc=
Received: (from apache@localhost)
    by veepiz.com (8.13.8/8.13.8/Submit) id p9QCXRHt031452;
    Wed, 26 Oct 2011 12:33:27 GMT
To: Hassan Hussein <jorfergie03@gmail.com>
Subject: Hassan Hussein?, You've got unseen alerts pending
Date: Wed, 26 Oct 2011 12:33:27 +0000
From: Veepiz Alert <veepiz-notify-system@veepiz.com>
Reply-to: Veepiz Alert <veepiz-notify-system@veepiz.com>
Message-ID: <1b841dbd639524b970b9adcf77a08704@localhost.localdomain>
X-Priority: 3
X-Mailer: PHPMailer 5.1 (phpmailer.sourceforge.net)
MIME-Version: 1.0
Content-Type: multipart/alternative;
    boundary="b1_1b841dbd639524b970b9adcf77a08704"


--b1_1b841dbd639524b970b9adcf77a08704
Content-Type: text/plain; charset = "iso-8859-1"
Content-Transfer-Encoding: 8bit

Dear Hassan Hussein,
 You have a total of 6 alert(s) at veepiz.com.
These are listed below;

- 6 Unread Message(s).

Please visit http://www.veepiz.com and view these
unseen notifications.

Remember, to view your notifications, hover over
the yellow notifications icon on the menubar.

Thanks Management


--b1_1b841dbd639524b970b9adcf77a08704
Content-Type: text/html; charset = "iso-8859-1"
Content-Transfer-Encoding: 8bit

Dear Hassan Hussein,<br />
 You have a total of 6 alert(s) at <a href='http://www.veepiz.com'>veepiz.com</a>. These are listed below;<br />
<br />
- 6 Unread Message(s).<br />
<br />
Please visit <a href='http://www.veepiz.com'>http://www.veepiz.com</a> and view these unseen notifications.<br />
<br />
Remember, to view your notifications, hover over the yellow notifications icon on the menubar.<br />
<br />
Thanks Management

Forgotten your password? go to <a href='http://www.veepiz.com/forgot.php'>http://www.veepiz.com/forgot.php</a>



--b1_1b841dbd639524b970b9adcf77a08704--
share|improve this question
2  
A) This isn't really a place for in-depth discussion. –  Bart Silverstrim Oct 26 '11 at 13:02
    
B) You don't mention the content of the mail, which can significantly influence having messages flagged. –  Bart Silverstrim Oct 26 '11 at 13:03
    
Then where are you seeing it get filtered as spam? At the email provider, or at your mail client? Are you getting your messages flagged at the actual clients, or just your system? –  Bart Silverstrim Oct 26 '11 at 13:09
    
in actual client emails like if you check gmail... the emails reside in spam.ive just done a test here allaboutspam.com/email-server-test-report/… –  Sir Lojik Oct 26 '11 at 13:29
2  
If it's happening in your mail client software (I mixed the definition above...client software, and I was asking about actual subscribers to your service as clients) then you may have to look at how it was trained to search for email. –  Bart Silverstrim Oct 26 '11 at 13:36
add comment

2 Answers

If you've set up SPF and DKIM correctly, and there's a valid PTR (reverse DNS) record, that's about all you can do on your server. This has been discussed here before...

Prevent mail being marked as spam

Why are emails sent from my applications being marked as spam?

One thing that I don't think has been included in other questions about this has been what - if anything - can be done about client filtering.

Unfortunately, there's nothing you can do on a to guarantee that some client - e.g. Gmail in your posted sample - won't classify a message as SPAM. Looking in my Gmail Spam folder, I see some semi-legitimate messages with headers like yours that indicate SPF, etc. is fine, but they're filtered because I've marked similar messages as Spam.

Since you have no control over what email client recipients might be using and how those clients are configured, probably the only other step you could take would be to ask them to include your sending address in their address book or other whitelist. It's no guarantee, and it's not really possible to give general instructions on how they do it, but it might help a bit.

share|improve this answer
    
My Spam filter would trigger on the mail content. This doesn't really look like legitimate mail. The header, PTR, DKIM and SPF would confirm that this is Ham, but the content is really ... spammy. –  mailq Oct 26 '11 at 20:22
add comment

If you look at your IP's reputation at http://www.mcafee.com/threat-intelligence/ip/default.aspx?ip=50.57.111.177, then you will notice that you had heavy outbreaks of mails (probably Spam) at the beginning of October. This may also have a big impact on the reputation at Google (currently).

Google probably doesn't use McAffee's database as a valid resource, but they have their own (secret) reputation system that will capture your overall traffic. And if they noticed a bad reputation in the past, it will take some time until they revalidate their findings and put your IP on "good reputation".

This is how Spam prevention works nowadays. It is not based on "this message" or "that message" but on your overall behavior. If the outbreak in October was a fault due to a malware infection then this is bad for you (even currently) but maybe disappear in the future.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.