• Contact Us
  • Pricing
  • Search
  • Register
  • Login
  • DNS Tools
    • MX Records
    • A Records
    • CNAME Record
    • PTR Record
    • SPF/TXT Records
    • NS Records
  • Domain Tools
    • ARIN Records
    • WHOIS Records
  • Blacklists
    • Blacklist Checker
    • Whitelist Checker
    • Email Blacklist Removal Tool
  • Email Tools
  • Port Scans
  • Other Tools
    • IP Tools
      • IP Address Converter
      • IP Address Locator
      • IP Range To CIDR
    • Chrome Extension - Email Deliverability Checker
    • 3D Trace Route
  • Blog
    • First Time Sender
      • Email Certification
      • Email Throttling
      • IP Warming
    • Formatting Emails
      • For Browsers
      • For Devices
      • For Email Clients
    • How To Avoid
    • How To Set Up
    • Mail Tester Guide
      • Email Headers Explained
      • MX Records, PTR Records, and Reverse PTR Records AKA rDNS
      • RFC Syntax Checking
      • Email Port Checks
      • SPF Record and Alignment
      • DKIM Signatures and Alignment
      • DMARC Validation
      • Mail Tester Test Tool
    • Measuring Peformance
      • Bounces
      • Clickthrough Rates
      • Open Rates
    • Related Resources
      • Abuse Contacts
      • Common Ports
      • DMARC and the Contact Us Form
      • Email Identifier
      • Email Headers
      • Email Statistics
      • How Email Works
      • How to Treat Spammers
      • Securing Your Server
    • Rules to Follow
      • Can Spam Act
      • Postmaster Guidelines
  • Member Services
    • Members Area
    • Community Forums
    • Blacklist Monitoring
    • Bulk Email Validation Tool
    • Complete Monitoring Solution
    • Domain Name Monitoring
    • Feedback Loop Submissions
    • Full Port Scan Monitoring
    • Mail Tester Pro Tool
    • Mail Miner
    • Spam Detector Toolbox
    • Trusted Sender Site Seal

Mail Tester
Email RFC Syntax Checking


Some email headers are subject to validation rules, they must conform to the different RFC Standards. Mail Tester looks for these email headers and validates the information contained within them.

The RFC5322.FROM header, which contains a name and email address, should conform to section 3.4 of the RFC 5322 documentation as seen below. Mail Tester validates the RFC522.FROM against the specification below and if it doesn't match it is flagged as a Critical Error. 
   address         =   mailbox / group
  mailbox         =   name-addr / addr-spec
  name-addr       =   [display-name] angle-addr
  angle-addr      =   [CFWS] "<" addr-spec ">" [CFWS] /
                       obs-angle-addr
  group           =   display-name ":" [group-list] ";" [CFWS]
  display-name    =   phrase
  mailbox-list    =   (mailbox *("," mailbox)) / obs-mbox-list
  address-list    =   (address *("," address)) / obs-addr-list
  group-list      =   mailbox-list / CFWS / obs-group-list
The next check is MIME-Version which at the writing of this blog should be 1.0, but the RFC allows for future versions. If this email header is missing, 1.0 will be assumed and flagged as a warning. If it contains any value, that's not defined in the specification, it will be flagged a  critical.  The specifation is below.
version := "MIME-Version" ":" 1*DIGIT "." 1*DIGIT
The next check is Content-Type, which can be many different values. Too many to list out in thie blog, but Mail Tester does check for all known email content types. The content type defines what the email consists of and which character set is being used. If Mail Tester doesn't recognize the content-type, it will be flagged a  critical.  The specification is below.
 
      content := "Content-Type" ":" type "/" subtype
                *(";" parameter)
                ; Matching of media type and subtype
                ; is ALWAYS case-insensitive.
     type := discrete-type / composite-type
     discrete-type := "text" / "image" / "audio" / "video" /
                      "application" / extension-token
     composite-type := "message" / "multipart" / extension-token
     extension-token := ietf-token / x-token
     ietf-token := 
     x-token := 
     subtype := extension-token / iana-token
     iana-token := 
     parameter := attribute "=" value
     attribute := token
                  ; Matching of attributes
                  ; is ALWAYS case-insensitive.
     value := token / quoted-string
     token := 1*
     tspecials :=  "(" / ")" / "<" / ">" / "@" /
                   "," / ";" / ":" / "\" / <">
                   "/" / "[" / "]" / "?" / "="
                   ; Must be in quoted-string,
                   ; to use within parameter values
The next check is Content-Transfer-Encodings, which can be many different values. The content transfer encoding defines how the email is encoded. If Mail Tester doesn't recognize the content-transfer-encoding, it will be flagged a  critical.  The specifation is below.
      encoding := "Content-Transfer-Encoding" ":" mechanism
     mechanism := "7bit" / "8bit" / "binary" /
                  "quoted-printable" / "base64" /
                  ietf-token / x-token

Read out next blog in the Mail Tester Series: Mail Tester - Email Port Checks

The Mail Tester Pro Report - RFC Header Validation Section

RFC5322.FROM - Address Specification Test - Section 3.4
RFC5322.FROM Result
"Mail Test" <mailtest@unlocktheinbox.com> Passed

MIME-Version - Syntax Check - RFC2045
MIME-Version Result
1.0 Passed

Content-Type - Syntax Check - RFC2045
Content-Type Result
text/plain; charset=utf-8 Passed

Content-Transfer-Encoding - Syntax Check - RFC2045
Content-Transfer-Encoding Result
quoted-printable Passed
Copyright © 2017 Unlock The Inbox