Bug 467734 - Automatic detection of email providers using Office 365
Summary: Automatic detection of email providers using Office 365
Status: REPORTED
Alias: None
Product: kmail2
Classification: Applications
Component: config dialog (show other bugs)
Version: 5.22.3
Platform: Neon Linux
: NOR wishlist
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-03-23 23:37 UTC by Louis Moureaux
Modified: 2023-03-23 23:37 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Louis Moureaux 2023-03-23 23:37:24 UTC
Microsoft provides many organization emails around the world through its Office 365 product so it would be good to have first-class support in KMail. KMail already features EWS support, but setting it up for O365 is far from intuitive [1].

Fortunately, detecting O365 emails is easy. If the address is user@example.com:
1. Perform a MX DNS lookup for example.com
2. Look at the first exchange record. The provider uses Office 365 if the exchange is of
   the form:

     example-com.mail.protection.outlook.com

   One can then reasonably assume that Office 365 EWS is supported.

Adding this simple check to the account setup wizard could enhance its results for a large number of (corporate) domains. Saving the users from the hassle of setting up EWS all resources (incoming, outgoing, contacts, calendar) by hand would be a significant improvement.

[1] https://userbase.kde.org/Kmail/Configuring_Kmail/Accounts/Office_365

ADDITIONAL INFORMATION

Office 365 setup instructions with MX record details: https://learn.microsoft.com/en-us/microsoft-365/admin/get-help-with-domains/create-dns-records-at-any-dns-hosting-provider?view=o365-worldwide#add-an-mx-record-for-email-outlook-exchange-online

Some example domains using O365 (as of 2023): ulb.be, student.uclouvain.be, cern.ch

In my testing, QDnsLookup did the MX lookups perfectly well.