Problems configuring Service Management Email Requests (mail handler) with a shared mailbox using Basic Authentication

Still need help?

The Atlassian Community is here for you.

Ask the community

    

Summary


Configuring a Service Management Mail Handler with a Shared Mailbox can be a tricky task, as it requires to setup the proper mailbox, username, protocol and port. This knowledge base was created to show how to do this when using a Share Mailbox in office 365. 

Environment

Tested in Service Management Server/Data Center 4.13.x

Solution

Let's assume that:

  • you have a shared mailbox with the email address testsharedmailbox@test.com
  • one of the user who has access to the inbox folder of this shared mailbox is userwithmailboxaccess@test.com

To configure this shared mailbox using this user to access it, you will need to use the following settings in Project Settings > Email Requests > Other and click on the Update button:

  • email address: testsharedmailbox@test.com
  • username: userwithmailboxaccess@test.com\testsharedmailbox
  • password: password of the username who has access to the mailbox
  • email protocol: SECURE POP
  • mail server: outlook.office365.com
  • port number: 995
  • timeout: 50000 (default value)
  • request type: request type of your choice

(warning) Note that IMAP cannot be used when configuring a mail handler with basic authentication (please refer to Issue 3 for more information).

Known Issues

Issue 1: the configuration of the Mail Handler was successful, but no email is read from the shared mailbox

Possible root causes:

  • The emails are not located in the Inbox folder of the shared mailbox (the mail handler only pulls emails located in the Inbox folder)
  • The emails were sent to the shared mailbox box before the mail handler was configured (the mail handler only pulls emails sent to the shared mailbox after it was configured)
  • The emails sent to the shared mailbox were already marked as READ before the mail handler tried to pull them (the mail handler only pulls emails marked as UNREAD)
  • The user does not have access the Inbox  folder of the shared mailbox
  • The user name was configured in Email Requests  without "\testsharedmailbox" at the end

Issue 2: the configuration of the Mail Handler keeps being overwritten in the UI

If you switch between the Outlook  and the Other  tab in Project Settings > Email Requests, the username will be automatically overwritten by the value from the email address field, due to the known bug below. (warning) Note that it is only a UI bug, and that it does not impact the actual configuration of the mail handler which is stored in the database:

Issue 3: the configuration of the Mail Handler was not successful, and the error "IMAP fails with A3 BAD User is authenticated but not connected error" is thrown

This error usually occurs when configuring a Mail Handler with a shared mailbox, and using the IMAP protocol and the basic authentication:

This configuration is unfortunately not supported as per the feature request  JRASERVER-30688 - Getting issue details... STATUS

There are options available to make the configuration with the shared mailbox:

  • keep using the basic authentication method, along with the POP protocol (instead of IMAP)
  • or change the basic authentication method to the Oauth 2.0 authentication method, which was introduced in Jira Service Management 4.10.0, and which supports the combination shared mailbox + IMAP

Issue 4: the configuration of the Mail Handler was not successful, and the error "OAuth token not defined for connection. OAuth Authorisation required" is thrown

This error will happen if you choose to configure the Mail Handler in Project Settings > Email Requests > Microsoft using the Oauth 2.0 authentication (rather than using the Basic Authentication with the username/password of the user who access to the shared mailbox). It is due to the following bug below which occurs if the Inbox folder is translated in a different language than English:


Last modified on Apr 7, 2022

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.