Mails reported as SPAM

Hi,

I am using php mail() function to send mails from my application. I almost did everything to make sure that notification not to be marked as SPAM. But, till this point unsuccessful to achieve this objective.

Gmail is considering all my mails generated from my domain as SPAM and putting them into SPAM folder. Any help in this regard will be highly appreciated.

Following activities accomplished so far.

1. rDNS setup (Reverse DNS)

2. SPF setup at DNS

3. Correct mail header formats using PostFix MTA

I am struggling to resolve this issue since last 1 week.

Thanks,

Pranay

6 Replies

Did you check the mail headers at gmail to see if SPF passes? Also check the IP of your Linode here, sometimes an old IP managed to get himself on the blacklist - http://mxtoolbox.com/blacklists.aspx

If it's on a blacklist, request a new IP from Linode or you can contact the blacklist to get your IP removed.

You can also get a service like this to see your spam score: http://www.isnotspam.com/

Below is the mail receiver header. I have checked at http://mxtoolbox.com/blacklists.aspx but not able to deduce conclusion from it. It is showing almost with 200 records with green icon.

Delivered-To: pranay.somyajula@gmail.com

Received: by 10.70.4.196 with SMTP id m4csp43784pdm;

Sun, 9 Mar 2014 01:14:52 -0800 (PST)

X-Received: by 10.140.87.172 with SMTP id r41mr283565qgd.101.1394356492469;

Sun, 09 Mar 2014 01:14:52 -0800 (PST)

Return-Path: <admin@korpus.co.in>

Received: from li282-46.members.linode.com (korpus.co.in. [66.228.32.46])

by mx.google.com with ESMTP id p73si7692683qga.136.2014.03.09.01.14.52

for <pranay.somyajula@gmail.com>;

Sun, 09 Mar 2014 01:14:52 -0800 (PST)

Received-SPF: pass (google.com: domain of admin@korpus.co.in designates 66.228.32.46 as permitted sender) client-ip=66.228.32.46;

Authentication-Results: mx.google.com;

spf=pass (google.com: domain of admin@korpus.co.in designates 66.228.32.46 as permitted sender) smtp.mail=admin@korpus.co.in

Received: by li282-46.members.linode.com (Postfix, from userid 33)

id 0567E152A8; Sun, 9 Mar 2014 09:14:52 +0000 (UTC)

To: =?UTF-8?B?UHJhbmF5IFNvbXlhanVsYQ==?= <pranay.somyajula@gmail.com>

Subject: =?UTF-8?B?UmVxdWVzdCBmb3IgbmV3IHBhc3N3b3JkLg==?=

X-PHP-Originating-Script: 33:functions.php

From: =?UTF-8?B?S29ycHVz?= <admin@korpus.co.in>

X-Mailer: PHP/5.3.10-1ubuntu3.9

MIME-Version: 1.0

Content-Type: multipart/alternative; boundary="Korpus531c310bf289e"

Message-Id: <20140309091452.0567E152A8@li282-46.members.linode.com>

Date: Sun, 9 Mar 2014 09:14:52 +0000 (UTC)

Thanks,

Pranay

"Received: from li282-46.members.linode.com (korpus.co.in. [66.228.32.46])"

Looks like you haven't changed your hostname from the default, or haven't restarted your mailserver since. So when you make an outgoing connection it says "HELO li282-46…." and some anti-spam rules dislike that sort of hostname.

In theory it's not a mistake and any site that behaves that way is silly, but it happens.

I'd recommend setting your hostname to match the rDNS, reboot, and see if that helps.

Thanks or your reply. Postfix captured default values due to which it was appended on header. Changed the postfix configuration. But still, mails are landing at SPAM.

Please find the revised header for your reference.

Delivered-To: korpus4u@gmail.com

Received: by 10.224.124.135 with SMTP id u7csp32549qar;

Sun, 9 Mar 2014 07:02:59 -0700 (PDT)

X-Received: by 10.140.39.50 with SMTP id u47mr32870378qgu.46.1394373779053;

Sun, 09 Mar 2014 07:02:59 -0700 (PDT)

Return-Path: <admin@korpus.co.in>

Received: from korpus.co.in (korpus.co.in. [66.228.32.46])

by mx.google.com with ESMTP id q1si7981105qab.127.2014.03.09.07.02.58

for <korpus4u@gmail.com>;

Sun, 09 Mar 2014 07:02:59 -0700 (PDT)

Received-SPF: pass (google.com: domain of admin@korpus.co.in designates 66.228.32.46 as permitted sender) client-ip=66.228.32.46;

Authentication-Results: mx.google.com;

spf=pass (google.com: domain of admin@korpus.co.in designates 66.228.32.46 as permitted sender) smtp.mail=admin@korpus.co.in;

dkim=pass (test mode) header.i=@korpus.co.in

Received: by korpus.co.in (Postfix, from userid 33)

id 5707E152A5; Sun, 9 Mar 2014 14:02:58 +0000 (UTC)

DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=korpus.co.in;

s=mail; t=1394373778;

bh=NfOWwvctUWV5J0fhW6tY3NI7Kcf1o/LNV1y+lxPbRVc=;

h=To:Subject:From:Date;

b=MZKWfBraM+m8IBbtfCkGAMdYZdM9OYqOIzuMDk2nhEKLZLrJxVFpFlhfbYiWP9191

glAy0HzL5N9rgzCUnljSg4XE36oXuIbtz855wjDW0F0w2kZKT9S6b0+sA2zLNv1eRb

H8R971kaCjIJPkErXO5WkYwjBjmGDxqJJwjZUa5Q=

To: =?UTF-8?B?a29ycHVzIHRlc3Q=?= <korpus4u@gmail.com>

Subject: =?UTF-8?B?UmVxdWVzdCBmb3IgbmV3IHBhc3N3b3JkLg==?=

X-PHP-Originating-Script: 33:functions.php

From: =?UTF-8?B?S29ycHVz?= <admin@korpus.co.in>

X-Mailer: PHP/5.3.10-1ubuntu3.9

MIME-Version: 1.0

Content-Type: multipart/alternative; boundary="Korpus531c749250f6c"

Message-Id: <20140309140258.5707E152A5@korpus.co.in>

Date: Sun, 9 Mar 2014 14:02:58 +0000 (UTC)

Thanks,

Pranay

I noticed your DKIM key is in test mode. Try removing "t=y\;" from it to see if it makes a difference.

Your IP address does not seem to be on any blacklists, but you might be getting penalized by your domain being so young.

I noticed that the Subject and From headers don't appear to be in English. I have no idea if that makes a difference (I would hope not), but you could try sending some mails with all English content to see if it makes a difference.

Beyond that, the body of the email might be triggering the spam filter too. Are there any links in the email? Gmail sometimes penalizes email with links.

Whatever the case, make sure you mark these emails in gmail as "not spam" in case that helps.

You are correct. e-mail body contains url links to direct user to content for which mail has been triggered. It can be account registration or content update. This is the primary feature of notification and difficult to compromise.

Actual mail contains the plain English content for subject and body. The header info posted in earlier threads taken from actual mail header which is usually encrypted.

Anyway, I have raised request to Gmail for further investigation to resolve this issue.

I will update this forum once I get any information from Gmail. Meanwhile, if you find any resolution then kindly share the same with me.

I really appreciate this Forum for kind of help offered.

Thanks again to all of you for quick help.

Thanks,

Pranay

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct