Difference between revisions of "IPv6/Cheatsheet"

From braindump
Jump to navigation Jump to search
Line 28: Line 28:
With the preliminary checks done the next thing is to send a test message to a recipient over IPv6 using <tt>curl</tt>.
With the preliminary checks done the next thing is to send a test message to a recipient over IPv6 using <tt>curl</tt>.


Create a plain text file with content similar to this one.
Create a plain text file with content similar to this one for the purpose of this example the file is called <tt>mail.txt</tt>
From "IPv6 Mail Test" <span class="input"><whoever@example.com></span>
From "IPv6 Mail Test" <span class="input"><whoever@example.com></span>
To: "Recipient" <span class="input"><recipient@example.com></span>
To: "Recipient" <span class="input"><recipient@example.com></span>

Revision as of 10:40, 12 November 2016


SMTP

Checking if the MTA is IPv6 Ready

There are a lot of SMTP server out there that are actually IPv6 ready but this fact is not reflected in the MX record. This hack lets one test the connectivity of prior to amending the MX records in DNS.

Finding the AAAA record of the MTA

Get the MX record.

$ dig +short mx example.com
10 mail.example.com.

Do a reverse lookup of the IP address

$ dig +short  -x $(dig +short mail.example.com)
mx1.big-isp.com.

Take the resulting name and see if an AAAA record exists.

$ dig +short aaaa mx1.big-isp.com.
2001:db8::f00:b4  

Or for the impatient

$ domain=example.com
$ dig +short aaaa $(dig +short -x $(dig +short $(dig +short mx $domain | awk '{print $2}')))
2001:db8::f00:b4

Sending a test message with curl

With the preliminary checks done the next thing is to send a test message to a recipient over IPv6 using curl.

Create a plain text file with content similar to this one for the purpose of this example the file is called mail.txt

From "IPv6 Mail Test" <whoever@example.com>
To: "Recipient" <recipient@example.com>
Subject: Test Mail via IPv6

This is a test mail sent using the IPv6 protocol.