Skip to content

Instantly share code, notes, and snippets.

@fak
Last active January 2, 2016 01:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fak/8229684 to your computer and use it in GitHub Desktop.
Save fak/8229684 to your computer and use it in GitHub Desktop.
Thunderbird attachments bounce with message ''BANNED: application/x-msdownload,.pdf"

Noticed some strange behaviour when sending a pdf file that had been compiled with LuaTex. Messages sent with this file attached would come bouncing right back at me with a message BANNED: application/x-msdownload,.pdf and would be saved under the name nsmail.exe in Thunderbird's cache folder. Other pdf files would be sent without problems. Even more confusing, saving the file using Preview solved the problem in some kind of blackbox process. The only obvious difference between the two files was that the LuaTex header said pdf 1.5 while the header of the Preview-saved file said pdf 1.3.

I found some threads that dealt with similar problems here and here. Apparently TB assigned the incorrect MIME type to the pdf file I compiled with LuaTex, in this case application/x-msdownload,.pdf rather than simply application/pdf. By then I had a feeling that this behaviour was something TB learnt from user input and that somewhere in TB this could be reversed. Finally, this site proposes to delete a file mimeTypes.rdf from Users/username/Library/Thunderbird/Profiles/xxxxxxx.default where xxxxxx is some random combination. This file apparently keeps track of programs/actions used to deal with specific file types. Deleting the file did actually solve my problem. One day I will figure out how to change it rather than delete it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment