0

I've setup Amazon SES as the SMTP relayhost in my postfix configuration on the EC2 instance. The domain a.b has been verified by Amazon as well with following properties:

  1. Email Feedback Forwarding: enabled
  2. DKIM Settings Generated: yes
  3. Bounce Notifications SNS Topic: none
  4. DKIM Verification Status: verified
  5. Complaint Notifications SNS Topic: none
  6. DKIM Signing: enabled
  7. Delivery Notifications SNS Topic: none
  8. MAIL FROM Domain: contact.a.b

where, I want my application to send emails as noreply@contact.a.b. My actual email reception/delivery is handled by zoho services. It has been configured not to receive emails for any of the subdomain accounts.

Now, to the actual problem. I sent an email using mail command as follows:

echo "Test mail from postfix" | mail -s "Test Postfix" hjpotter92@a.b -a "From: Mailing Daemon <noreply@contact.a.b>"

and the email was received as spam in my zoho inbox. Checking the original message, I notice that both; the SPF and the DKIM headers are present:

Delivered-To: hjpotter92@a.b
Received-SPF: pass (zoho.com: domain of contact.a.b designates 54.240.27.38 as permitted sender) client-ip=XX.XX.XX.XX; envelope-from=uuid+timestamp@contact.a.b; helo=a27-38.smtp-out.us-west-2.amazonses.com;
Authentication-Results: mx.zoho.com;
    spf=pass (zoho.com: domain of contact.a.b designates XX.XX.XX.XX as permitted sender) smtp.mailfrom=uuid+timestamp@contact.a.b;
Received: from a27-38.smtp-out.us-west-2.amazonses.com (a27-38.smtp-out.us-west-2.amazonses.com [XX.XX.XX.XX]) by mx.zohomail.com
    with SMTPS id 1474914100783465.00613467540006; Mon, 26 Sep 2016 11:21:40 -0700 (PDT)
Return-Path: <uuid+timestamp@contact.a.b>
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple;
    s=rncj6athd6keffyests3zpklorp6m33m; d=a.b; t=1474914098;
    i=@contact.a.b; h=Subject:From:To:Message-Id:Date;
    <KEY CONTENT REDACTED>
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple;
    s=gdwg2y3kokkkj5a55z2ilkup5wp5hhxx; d=amazonses.com; t=1474914098;
    h=Subject:From:To:Message-Id:Date:Feedback-ID;
    <KEY CONTENT REDACTED>
Subject: Test Postfix
From: Mailing Daemon <noreply@contact.a.b>
To: <hjpotter92@a.b>
X-Mailer: mail (GNU Mailutils 2.99.98)
Message-ID: <some-id-here@us-west-2.amazonses.com>
Date: Mon, 26 Sep 2016 18:21:38 +0000
X-SES-Outgoing: 2016.09.26-54.240.27.38
Feedback-ID: 1.us-west-2.IMI7x8kfSuWfF4qNyPxetCzCifHnf+9N5Q1IqSPbtZA=:AmazonSES
X-ZohoMail-Owner: <uuid+timestamp-here@us-west-2.amazonses.com>+zmo_0_<same-uuid+timestamp@contact.a.b>
X-ZohoMail-Sender: 54.240.27.38
X-ZohoMail: RSF_0 Z_633815312 SPT_1 Z_633815311 SPT_1 Ss2 SS_1 SFPZM SFPP UW2468 UB2468 COSF UMS_NDWSD_EXT_Z5 UMS_SPPND_8 SGR1_1_2_0_27046_162
X-Zoho-Virus-Status: 2

So, why is the email received is marked as spam by zoho? My DNS manager (cloudflare) does not contain MX record for contact.a.b domain, as I do not wish to receive/handle the emails received there. Could this be the issue, because this answer mentions existence of forward and reverse DNS values.

PS: I'm currently in the sandbox mode of SES, but have already requested a limit increase. If the sandbox mode could be the issue!

hjpotter92
  • 660
  • 1
  • 10
  • 20

1 Answers1

0

The issue has now been resolved on its own! I've however moved out of the sandbox mode now and the mails are coming in as legitimate since then onwards. It could've been the issue (I highly doubt it though).

At first, I thought it might be because of a hight TTL value of my SPF TXT record in may DNS; but the received-spf: pass header in the email negates that hypothesis.

If anyone else can shed some light on it, I'd highly appreciate it.

hjpotter92
  • 660
  • 1
  • 10
  • 20