Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 678846 - gnome-extra/evolution-ews >=3.30 is missing support for oauth2 authentication (Office365)
Summary: gnome-extra/evolution-ews >=3.30 is missing support for oauth2 authentication...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Linux Gnome Desktop Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-02-26 16:53 UTC by b2c
Modified: 2019-03-04 22:36 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge-info.txt (emerge-info.txt,7.00 KB, text/plain)
2019-02-26 16:53 UTC, b2c
Details

Note You need to log in before you can comment on or make changes to this bug.
Description b2c 2019-02-26 16:53:22 UTC
Created attachment 566598 [details]
emerge-info.txt

evolution-ews supports OAuth2 authentication for Office365 since evolution-ews-3.27.91. I was able to test this on Arch Linux [2,3] with the same package versions and it works. However on Gentoo Linux the choice to pick the authentication type "OAuth2 (Office 365)" is missing when trying to connect an Office365 account.

It should appear when setting up a new account, on the third page "Receiving E-Mail" when the "Host URL" field matches "https://outlook.office365.com/EWS/Exchange.asmx" [1]. However only the authentication types "Basic", "NTLM" and "Kerberos" are displayed. The type "OAuth2 (Office 365)" is missing however.

I compiled evolution and evolution-ews with the following use flags:

[I] mail-client/evolution
     Installed versions:  3.30.5(2.0)(05:22:42 PM 02/26/2019)(spell ssl -archive -bogofilter -geolocation -gtk-doc -highlight -ldap -spamassassin -weather -ytnef)

[I] gnome-extra/evolution-ews
     Installed versions:  3.30.5^t(05:23:06 PM 02/26/2019)(-test)

Did I miss some necessary useflags or dependencies?

[1] https://wiki.gnome.org/Apps/Evolution/EWS/OAuth2
[2] https://www.archlinux.org/packages/extra/x86_64/evolution
[3] https://www.archlinux.org/packages/extra/x86_64/evolution-ews
Comment 1 Mart Raudsepp gentoo-dev 2019-02-26 17:15:19 UTC
This requires at least USE=oauth on evolution-data-server. Do you have that already? You are showing only evo and evo-ews flags above.
Comment 2 b2c 2019-02-27 07:34:08 UTC
Ah, that was possibly the hint I was missing, I didn't check evolution-data-server. Added the "oauth" usefalg and now it works. Thanks!
Comment 3 Mart Raudsepp gentoo-dev 2019-02-27 11:13:18 UTC
I wonder how common these oauth use cases are and if we maybe should mirror the USE flag somehow to avoid such trouble more. Or maybe we should default enable oauth on eds
Comment 4 b2c 2019-02-27 13:10:37 UTC
I'd guess it's a rather niche case, since OAuth for Exchange is only needed if the "normal" authentication is disabled for some reason. In my case the company switched the identity provider and used SAML2 logon. Therefore I had to switch to OAuth (thank god Milan Crha cared to implement it!) which still works fine.

It probably wouldn't hurt to move the use flag to the evolution ebuild as it's usually the first place people might look for it (at least for me it was).
Comment 5 Mart Raudsepp gentoo-dev 2019-02-27 13:13:02 UTC
It can't be moved, because it controls if the support is built or not in evolution-data-server, so the actual feature control has to be done there. It would have to be mirrored somewhere else instead. But then the case could be made to mirror all of them, and that's not something we would want to do for everything.
Comment 6 Pacho Ramos gentoo-dev 2019-03-04 22:36:25 UTC
(In reply to Mart Raudsepp from comment #3)
> I wonder how common these oauth use cases are and if we maybe should mirror
> the USE flag somehow to avoid such trouble more. Or maybe we should default
> enable oauth on eds

I am not using evolution-ews but, in my case, after updating to evolution-data-server-3.30 (from 3.26), my gmail account *using POP3* stopped to work without evolution-data-server[oauth]. In that case I was getting the error:
Failed to authenticate: Data source "XXX" does not support OAuth 2.0 authentication"

If I tried to use "Password" instead of (default chosen by the assistant) Oauth, gmail was rejecting the connection because it thinks an "insecure app" is trying to connect to it.

I wonder if this could be caused by a mis-sync between Evolution 3.30 stack and gnome-online-accounts-3.28... but in current situation, I need evolution-data-server with oauth USE flag to allow to re-add the POP3 Gmail account