SPF record for amazon ec2

Where can I get the correct syntax for creating the correct SPF record for Amazon EC2 server? I understand how to create a dns record, but I have no idea what to use for the SPF record.

+3
source share
3 answers

This is very easy to do:

  • Providing Elastic IP for your server.
  • Configure record "A" for the server that will send mail with your favorite registrar. Good practice is to include “svr” somewhere in the host name, for example app-svr-01.youdomain.com
  • Click here to contact amazon and request a reverse dns entry for IP

  • add the following to your SPF record and you should be fine:

    a: app-svr-01.youdomain.com

Note. If you need to relay mail through this server from other AWS servers or communicate between the servers in any other way, you should not use this new fully qualified domain name, but rather the AWS fully qualified domain name from the AWS console (it will look like ec2-xxx- xxx-xx-xx.compute-1.amazonaws.com).

Using your custom domain name will go through the "WAN" and bandwidth charges will apply.

+11
source

You can use Amazon Simple Email Service (SES). If you use this service (and not directly), then your SPF may be as simple as described in the FAQ:

http://docs.amazonwebservices.com/ses/latest/DeveloperGuide/SPF.html

it can be changed to a certain malfunction in case of non-compliance:

v=spf1 include:amazonses.com -all 
0
source

Creating an SPF record for an EC2 instance is a waste of time. Each major ISP and blacklist will send black mail from the EC2 IP address no matter what you do. Since everyone can deploy the instance, get a new IP address, send spam and disappear, no one trusts their mail.

Use an external mail server, such as SendGrid.

-3
source

All Articles