Email Parser Pack
A mail parser has to cope with messages written by dozens of clients over forty years. This pack is the shortest path to finding out which of them yours cannot read.
SHA-256 7021a5cfb50bd7d3207f78b069e645d3aff9e6b516b1c5bccec4a50974ff581c
What is inside
| File | Format | Size | Expected result |
|---|---|---|---|
| apple-mail.emlx | EMLX | 742 bytes | Apple Mail import and migration. The leading byte count and trailing plist break every tool that assumes a .emlx is just an .eml, which is the usual reason Mail exports fail to import elsewhere. |
| attachment-tricky-filename.eml | EML | 643 bytes | Filename sanitising on save. The name decodes to a double-extension file, which is exactly the pattern used to disguise executables. Also catches parsers that only understand the simple filename="..." form. |
| dkim-spf-headers.eml | EML | 1007 bytes | Header-chain parsing and authentication display. Useful for testing code that surfaces SPF/DKIM/DMARC results, and for checking that a long Received chain is folded and read correctly. |
| empty-body.eml | EML | 273 bytes | Readers that assume every message has content. A subject-only message is legitimate and common for calendar and notification mail. |
| forwarded-nested.eml | EML | 864 bytes | Recursive parsing. Catches extractors that treat the nested message as opaque text, and anything that does not recurse into message/rfc822 when scanning attachments. |
| html-multipart.eml | EML | 593 bytes | Clients that pick the wrong alternative, or render the HTML part as literal text. Also catches parsers that stop at the first part. |
| inline-image-cid.eml | EML | 774 bytes | Inline-image rendering. Catches clients that show the image as a separate attachment instead of inline, and HTML sanitisers that strip cid: references. |
| long-folded-headers.eml | EML | 1.0 KB | Header unfolding. Catches parsers that read one physical line per header, truncate at 78 characters, or lose recipients after the first fold. |
| mailbox.mbox | MBOX | 1.1 KB | mbox splitting. A parser that splits on every line starting with "From " will corrupt the third message; one that never unescapes ">From " will silently alter the body text. |
| missing-required-headers.eml | EML | 103 bytes | Parsers that assume Date and Message-ID always exist, and ones that only split the header block on CRLFCRLF. Both are extremely common assumptions. |
| outlook-message.msg | MSG | 6.5 KB | Outlook-specific handling. A .msg is a property bag, not a mail format, so no RFC 5322 parser can read it. Opens in Outlook and parses in extract_msg. Also a second OLE2 fixture, sharing its container with legacy .doc and .xls. |
| plain-text.eml | EML | 337 bytes | Baseline for any .eml parser. Confirms header parsing, CRLF handling and that the body is separated by exactly one blank line. |
| quoted-printable.eml | EML | 535 bytes | Quoted-printable decoding. Catches decoders that mishandle soft line breaks (a trailing =) or fail to unescape =XX sequences. |
| spoofed-display-name.eml | EML | 410 bytes | Phishing display. Any client that shows only the display name presents this as coming from [email protected], when the actual address is [email protected]. The single most common real-world phishing pattern. |
| threaded-reply.eml | EML | 551 bytes | Conversation threading. Clients that thread on subject alone will group this wrongly; ones that ignore References will orphan it. |
| unicode-headers.eml | EML | 427 bytes | Header decoding. A client that prints the raw =?UTF-8?B?...?= instead of the decoded text, or mangles the display name in a reply. |
| web-archive.mht | MHTML | 689 bytes | MHTML handling. Same MIME container as email, which is why mail parsers often accept it and why it is a recurring vector for smuggling HTML past filters that only inspect the outer content type. |
| winmail-tnef.eml | EML | 695 bytes | The classic "why did I receive winmail.dat" bug. Catches clients that surface the TNEF blob as an unreadable attachment instead of decoding the attachments inside it. |
| with-attachment.eml | EML | 693 bytes | Attachment extraction: base64 decoding, filename parsing, and handlers that assume every part is text. |
sha256sum -c. Every file is generated from source, carries no third-party copyright, and is free to redistribute.Questions
What is the difference between .eml and .msg?
An .eml is the raw RFC 5322 message: text headers followed by a MIME body, readable by almost any client. A .msg is Microsoft-specific and structurally unrelated, a compound binary document holding MAPI properties in named streams. Code that handles one will not handle the other. Both are in this pack.
Is the personal data in these emails real?
No. Every name, address and phone number is invented and every domain is under example.test, which IANA reserves for exactly this purpose. None of the messages can be delivered anywhere.
Other packs
Upload Torture Test Pack · Filename Compatibility Pack · Encoding and Unicode Pack · Archive and ZIP Security Pack · Document Parser Pack · Image Pipeline Pack · Structured Data Pack