How do I prevent that my E-Mail’s getting tagged as SPAM?
Your SMTP Server’s greeting banner should display the FQDN of your MX Record.
I use the command line SMTP mailer “michus mail sender”, this tool can be found here.
Bad example (Banner is SMTP):
1 2 3 4 5 | :: michus mail sender v1.6 © by michael vogt <admin@derrolf.ch> »>MAIL SERVER OUTPUT: 220 SMTP service ready »>SEND: HELO localhost |
Good example (Banner is mx.google.com):
1 2 3 4 5 6 | :: michus mail sender v1.6 © by michael vogt <admin@derrolf.ch> »>MAIL SERVER OUTPUT: 220 mx.google.com ESMTP x33si1064255ugc »>SEND: HELO localhost «<RECEIVE: |
The SMTP greeting should be a 3-digit code, followed by a space or a dash, then the hostname (FQDN, RFC821 4.3 and RFC2821 4.3.1). Note that the hostname given in the SMTP greeting should have an A record pointing back to the same server.
Reverse DNS Lookup issues
The IP address of the sending server cannot be resolved into a hostname by doing a reverse DNS lookup because of a missing DNS PTR. Or your delivery server is not configured properly / uses the internal DNS name.
If you are using MS Exchange 2k or MS Exchange 2k3 you might check the properties of your “Default SMTP Virtual Server” / Delivery, Advanced. In this window you’ll see a text field called “Fully-qualified domain name”, enter the public DNS name you use as MX record.
Your sending SMTP IP address does not match the registered MX Record address, this might happen for example when your use one mail server a receiver (DMZ) and another one as sender (LAN). You might configure your internal (LAN) mail server to relay mail via the external (DMZ) mail server or add another MX record.
Use SPF (Sender Policy Framework)
Use an SPF record in your DNS to validate mail servers. Their web site is http://www.openspf.org, a rip from the introduction site:
SPFv1 allows the owner of a domain to specify their mail sending policy, e.g. which mail servers they use to send mail from their domain. The technology requires two sides to play together:
(1) the domain owner publishes this information in an SPF record in the domain’s DNS zone, and when someone else’s mail server receives a message claiming to come from that domain, then
(2) the receiving server can check whether the message complies with the domain’s stated policy. If, e.g., the message comes from an unknown server, it can be considered a fake.
All you have to do is add another TXT entry in your DNS. A standard value looks like this:
“v=spf1 mx ~all”
This means:
- v=spf1:
SPF version 1 - mx:
the incoming mail servers (MXes) of the domain are authorized to also send mail. - ~all:
all other machines are not authorized
So if your receiving mail servers also send your mails and you host only 1 domain this works straight away… Check their web site for tutorials, setup wizard to create SPF records and test tools.