Incoming Email Handler converts .msg attachments to .eml with no extension.

I have set up inbound email handlers to create issues forwarded to a mailbox.

We like to have to original client email attached to the ticket, so we "Forward as Attachement" in Outlook. This generates a .msg file from the original email that we are forwarding, and attaches it to a new email.

When the new email arrives in our jira inbox, the attachment is a binary .msg file. (Filename: "subject xyz.msg")

When JIRA processes the message, the file attached to the new Issue is a text .eml file, but the .eml extension is missing from the filename (Filename: "subject xyz"). I can tell it's an .eml by downloading it and opening it in a text editor.

As a result, if we want to view the original email, we have to download the file, then rename it to a .eml, and then open it with Outlook.

Does anyone know how we can fix this? I'd either like for the attachments to be the original .msg, or the .eml is ok as long as the filename is correct.

4 answers

Comments Closed

Walter,

Instead of forwarding as attachment to the Jira email handler address, could you try doing "Edit as new" on the message, then send it to the handler? This allows you to send the message as if you were composing it as a new message. This is a process change for your users, but will get the subject and body of the message directly in the Jira summary/description.

Andrew

Hi Andrew,

Thanks for the suggestion, however, we want to preserve the email as close to the original as possible. JIRA will strip out any formatting that may be in the email. Plus, we like to keep the JIRA descriptions technical and turse. We attach the user emails to the issues to provide context, but the users are not technical at all.

Walter,

Hi Walter,

I'm having an identical issue. JIRA deletes the file extension everytime my users forward emails as attachment from Outlook (i.e. Outlook attaches the email as a *.msg file). So if the email to JIRA contained an attachment "TITLE.msg", it will appear in the Issues attachment as "TITLE" with no file extension.

Have you managed to sort out the issue yet? I've been looking at the solution that you recommended but I have no idea how to hack the database..

With Thanks,

Nicholas

Hi Nicholas,

Sorry, I have not found a solution for this issue. If you have the hosted JIRA OnDemand, you won't be able to modify the database. If you have an installed JIRA instance, you just have to run the database query that I mentioned. But, it sounds like you're not familiar with connecting to a database server. I would suggest you ask your local DBA to run the query on your behalf.

Thanks,

Walter

Checking again, any update or workaround for this issue? Apart from renaming ?

Our users also complain about this issue since they have the same need for full trace of the message and also attachments inside the first email. All other filetypes gets their extension set correctly so some kind of bug inside the messagehandler it seems. An answer from Atlassian is most welcome. btw we use the Regex Comment Handler supplied by Atlassian.

I have created the following bug at Atlassian: https://jira.atlassian.com/i#browse/JRA-34220

This is the "work around" that I've come up with. Basically, I go into the JIRA database and rename the files to add the extension. It's probably not wise to muck about too much in the database, but I feel this is a safe-enough hack. It of course has to be performed periodically, unless you put in a trigger (I wouldn't).

UPDATE dbo.fileattachment
  SET [FILENAME] = [FILENAME] + '.eml'
  WHERE MIMETYPE = 'message/rfc822'
  AND [FILENAME] NOT LIKE '%.eml'

Thanks Walter. I'm using JIRA OnDemand so I'll have to raise the issue with Atlassian. I'm surprised that not many users have raised this issue. I found Carsten's (one of the responders to this thread) bug report and I've promoted it.

Not sure if Atlassian will fix it any time soon seeing that Carsten has raised the issue way back in 2013 and it hasn't been progressed at all.

Regards,

Nicholas

Community showcase
Sarah Schuster
Posted Jan 29, 2018 in Jira

What are common themes you've seen across successful & failed Jira Software implementations?

Hey everyone! My name is Sarah Schuster, and I'm a Customer Success Manager in Atlassian specializing in Jira Software Cloud. Over the next few weeks I will be posting discussion topics (8 total) to ...

2,934 views 12 18
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot