Uploaded image for project: 'Jira Service Management Data Center'
  1. Jira Service Management Data Center
  2. JSDSERVER-1792

Having a .msg attachment or Content-Type: multipart/alternative will not create mail issue, NullPointerException in log file.

      NOTE: This bug report is for JIRA Service Desk Server. Using JIRA Service Desk Cloud? See the corresponding bug report.

      Summary:

      An e-mail that is send to the JIRA Service Desk e-mail channel will fail if the e-mail has another e-mail attached to it in the .msg format. This occurs on windows with Service Desk 2.3.5.

      Steps to Reproduce:

      1. Save an e-mail and attach it to another e-mail
      2. Send this message with the attached e-mail to the e-mail channel

      Expected Results:

      Issue is created from e-mail

      Actual Results:

      Error is thrown in atlassian-jira-incoming-mail.log:

      2015-04-17 21:31:39,416 ERROR [] atlassian-scheduler-quartz1.clustered_Worker-3 anonymous     Exception when MailHandlerWorker handles message: 
      java.lang.NullPointerException
      	at javax.mail.internet.MimeUtility.decodeText(MimeUtility.java:573)
      	at com.atlassian.servicedesk.squalor.email.ServiceDeskMailUtils.addAttachments(ServiceDeskMailUtils.java:310)
      	at com.atlassian.servicedesk.squalor.email.ServiceDeskMailUtils.getAttachments(ServiceDeskMailUtils.java:260)

      Notes:

      • The message we have tested it with had a nested attachment (xls format) within the attached e-mail .msg file.
      • The same error also happens with .eml as attached files
      • The problem seems to be more related with the email client being used than the message attached. From the tests, the problem happens only with Outlook and does not happen with Gmail and the Mac OS X Mail client.
      • The same error will happens as well for Email that is coming from Open Technology Real Service(OTRS). OTRS Email Settings
      • The same behaviour also occurs when using Novel Groupwise and both e-mails are from the same domain and this can be avoided using POP instead of IMAP.
      • Another one confirmed for an email that is coming from IBM Notes 9.
      • Airmail is also confirmed having the same error.
      • Zarafa is confirmed having the same error.

          Form Name

            [JSDSERVER-1792] Having a .msg attachment or Content-Type: multipart/alternative will not create mail issue, NullPointerException in log file.

            We have created a workaround until we switch to the latest version.
            For that it runs an outlook client in a virtual machine in which a rule is running with the following script.
            Maybe it will help someone.

            Sub ConvertToPlain(MyMail As MailItem)
            Dim strID As String
            Dim objMail As Outlook.MailItem
            Dim objMail2 As Outlook.MailItem
            Dim myRecipient As Outlook.Recipient

            strID = MyMail.EntryID
            Set objMail = Application.Session.GetItemFromID(strID)
            Set myattachments = objMail.Attachments

            While myattachments.Count > 0
            myattachments.Remove 1
            Wend

            objMail.BodyFormat = olFormatPlain
            objMail.Save
            Set objMail2 = objMail.Forward

            With objMail2
            .To = "maxmuster@mustermann.de"
            .Send
            End With
            End Sub

            Deleted Account (Inactive) added a comment - We have created a workaround until we switch to the latest version. For that it runs an outlook client in a virtual machine in which a rule is running with the following script. Maybe it will help someone. Sub ConvertToPlain(MyMail As MailItem) Dim strID As String Dim objMail As Outlook.MailItem Dim objMail2 As Outlook.MailItem Dim myRecipient As Outlook.Recipient strID = MyMail.EntryID Set objMail = Application.Session.GetItemFromID(strID) Set myattachments = objMail.Attachments While myattachments.Count > 0 myattachments.Remove 1 Wend objMail.BodyFormat = olFormatPlain objMail.Save Set objMail2 = objMail.Forward With objMail2 .To = "maxmuster@mustermann.de" .Send End With End Sub

            Hi Nguyen,

            Sorry, I should have mentioned that I have a ticket open (SDS-4973).

            Damon Morda added a comment - Hi Nguyen, Sorry, I should have mentioned that I have a ticket open (SDS-4973).

            Hi damon.morda,
            Could you create a support ticket at https://support.atlassian.com?
            That way we can provide you with support specific to your circumstances and with higher security.
            The credentials should be the same as for this site (https://jira.atlassian.com).
            Thanks!
            JIRA Service Desk Product Team

            Chuong Nam Nguyen (Inactive) added a comment - Hi damon.morda , Could you create a support ticket at https://support.atlassian.com? That way we can provide you with support specific to your circumstances and with higher security. The credentials should be the same as for this site ( https://jira.atlassian.com ). Thanks! JIRA Service Desk Product Team

            I put a file test.msg as an attachement to an email and sent it in. This generated a ticket with the file attached properly no issue. I am running Service_Desk 2.5.0 currently.
            I can't say when this started working. The reason I noticed it originally was secure mail with Office 365 but that isn't a problem now. Maybe try updating it and see. It is a fast update.

            Aaron Braun added a comment - I put a file test.msg as an attachement to an email and sent it in. This generated a ticket with the file attached properly no issue. I am running Service_Desk 2.5.0 currently. I can't say when this started working. The reason I noticed it originally was secure mail with Office 365 but that isn't a problem now. Maybe try updating it and see. It is a fast update.

            I just tested this with Service Desk 2.4.3 and the issue still seems to exist. Is anyone else still having this problem?

            Damon Morda added a comment - I just tested this with Service Desk 2.4.3 and the issue still seems to exist. Is anyone else still having this problem?

            Hello, we have the same problem here. The server version we have is 2.3.5 of Service Desk, but can not upgrade to 2.4.3. The new version of SD forces to pay more lisences of SD agents and we only have 15. Could be a fix without upgrade? If not, will be a patch for older versions?

            Jesús Martin Barroso added a comment - Hello, we have the same problem here. The server version we have is 2.3.5 of Service Desk, but can not upgrade to 2.4.3. The new version of SD forces to pay more lisences of SD agents and we only have 15. Could be a fix without upgrade? If not, will be a patch for older versions?

            Hi atlassian1239
            For the server version, it would be in JSD 2.4.3 as stated in Fixed Version.

            Thanks

            Thong Bui Quang (Inactive) added a comment - Hi atlassian1239 For the server version, it would be in JSD 2.4.3 as stated in Fixed Version. Thanks

            tbuiquang, how about the fix for the Server version?

            Atlassian Partner [Cententia] added a comment - tbuiquang , how about the fix for the Server version?

            Hi,
            This issue was fixed in JSD 2.5.1-OD-02 which is under release pipeline at present. Release team are working on delivering it to production as soon.

            Thanks
            Service Desk support team

            Thong Bui Quang (Inactive) added a comment - Hi, This issue was fixed in JSD 2.5.1-OD-02 which is under release pipeline at present. Release team are working on delivering it to production as soon. Thanks Service Desk support team

            Thank you for the update on this regarding testing/development and rollout. You are noting ti will release to the Cloud based on QA soon. When with this be available on a larger scale?

            Aaron Braun added a comment - Thank you for the update on this regarding testing/development and rollout. You are noting ti will release to the Cloud based on QA soon. When with this be available on a larger scale?

              cnguyen Chuong Nam Nguyen (Inactive)
              ilabras Ibrahim (Inactive)
              Affected customers:
              15 This affects my team
              Watchers:
              37 Start watching this issue

                Created:
                Updated:
                Resolved: