You've got mail. But how did it get here? A comic about an email's incredible journey through the Wild West of the internet.
x

Upcoming changes to attachment validation — action may be required

Historically Postmark has accepted invalid content-types and content-id for attachments. To accommodate future infrastructure improvements, we’re changing how we handle attachment validation. After June 3rd, we will start to reject content-types and content-ids that are invalid. If you send messages without attachments, no changes are necessary. This also only applies to outgoing messages.

Show details

What’s changing

There are two places where an attachment could be invalid:

  • content-type will need to be a valid MIME type (for example application/pdf or image/png).
  • content-id will need to contain only ASCII characters, no spaces or non-ASCII characters are allowed. This follows RFC2392.

In the majority of cases the invalid data stems from using the filename as the content-type and/or content-id. Instead, the correct MIME type should be specified in the ContentType field, and an appropriate unique ContentID should be generated for each attachment, For example:

Invalid


{
 "Name": "readme (1).txt",
 "Content": "dGVzdCBjb250ZW50",
 "ContentType": "readme (1).txt",
 "ContentID": "readme (1).txt"
}

Valid


{
 "Name": "readme(1).txt",
 "Content": "dGVzdCBjb250ZW50",
 "ContentType": "text/plain",
 "ContentID": "c7d-2q41-zfw"
}

What you need to do

For messages you send with attachments, you can check the “Raw Source” of the message in Postmark to make sure you have your attachment formatted in a valid way. If you have access to review the logging for how you’re sending messages to Postmark for your server, you can also review how the attachment is formatted there. A vast majority of senders will find their attachments are valid, and no action will be needed.

We’re contacting senders who we’ve detected who have sent a high volume of messages that will be affected by this change.

If you have any questions or concerns about any of these changes, please let us know.

Sign up to receive new updates by email