unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Tim Cross <theophilusx@gmail.com>
To: emacs-devel@gnu.org
Subject: Re: oauth2 support for Emacs email clients
Date: Mon, 09 Aug 2021 02:05:23 +1000	[thread overview]
Message-ID: <87im0frj5r.fsf@gmail.com> (raw)
In-Reply-To: <m3lf5cc5sg.fsf@fitzsim.org>


Thomas Fitzsimmons <fitzsim@fitzsim.org> writes:

> David Engster <deng@randomsample.de> writes:
>
>>> David Engster <deng@randomsample.de> writes:
>>>
>>>>>   Others have mentioned "officially" registering Emacs as IMAP/SMTP
>>>>>   clients for Office365 (and possibly Gmail), similar to what seems
>>>>>   to be the case for Thunderbird.  I am wondering how davmail is
>>>>>   doing this.
>>>>
>>>> Microsoft has actually recognized that it does not make sense for
>>>> desktop applications to embed secrets into their code, so they
>>>> distinguish between "public" and "confidential" client applications:
>>>>
>>>> https://docs.microsoft.com/en-us/azure/active-directory/develop/msal-client-applications
>>>>
>>>> Public client applications do not have a client secret but only an ID
>>>> which can simply be embedded into the application, which is how DavMail
>>>> does it. Public client applications are only allowed to access web APIs
>>>> on behalf of the user, but this is usually enough.
>>>
>>> Interesting, but are public client applications allowed to use
>>> IMAP/SMTP?  Or must public client applications use WebDAV to communicate
>>> with Microsoft servers, like DavMail does?
>>
>> As I've written: Public client applications are only allowed to access
>> web APIs, so no IMAP/SMTP.
>
> OK; I wasn't sure if by "web APIs" you meant only "OAuth-related web
> APIs".  Thanks for confirming.
>
> I wonder why Microsoft does not allow public client applications to use
> IMAP/SMTP.
>

MS doesn't like people using IMAP/SMTP mainly because email is really
only just a part of their 'environment'. Office 365 and Exchange are not
mail servers - they are a 'unified communication stack', which includes
email, calendaring, chat, document sharing, etc.

The other reason they don't want direct access to IMAP and even SMTP is
because they are also adding lots of other 'enterprise' and security
features - for example, not allowing attachments which have not got the
right policy classification, preventing 'sensitive' data being sent to
external parties and adding features like read receipts, ability to
recall messages and even have emails which 'auto destruct' or timeout.

They cannot add these features to IMAP or SMTP and if they allow these
protocols, then all these other 'features' can be bypassed. MS will
advise organisations not to enable IMAP or external direct SMTP access
and the C level execs will follow that advice because if they don't and
something goes wrong (even if unrelated), they will be blamed. Things
will still go wrong, but at least they can say they were following the
'experts' advice and 'best practice'. 

I wouldn't be at all surprised if MS didn't remove IMAP support
altogether at some point in the future. There is even a growing
resistance to Email in the corporate sector and try talking to young
people about Email - most of them only deal with it under sufferance. My
plumber actually told me last week that they no longer send invoices via
email - instead, they send an SMS with a link to the invoice on a
server. If they weren't such good and reliable plumbers, I would
consider changing companies.

>> I usually use DavMail to get my mail downloaded to a locally running
>> IMAP server.
>>
>> So yes, simply registering Gnus as a public client is not enough, one
>> would also need a new backend specifically for Exchange.
>
> Hmm, yeah.  I'd prefer to keep using IMAP/SMTP, standards designed for
> email.  Excorporate does some email operations via EWS, but it seems
> strange to extend Excorporate (and make a Gnus backend for it) to handle
> all of email just to avoid application registration issues with a new
> IMAP/SMTP authentication method.
>
> IMAP/SMTP are already implemented and work fine for other email
> services, and they can authenticate via OAuth (assuming registration is
> sorted out).
>
>>> It seems like Thunderbird could act as a public client application,
>>> however I believe it is currently acting as a confidential client
>>> application.  I wonder why.
>>
>> Because they want to use IMAP/SMTP.
>
> Maybe the FSF could request that Emacs be registered as a public client
> application and also be allowed to use IMAP/SMTP.  That would solve the
> "embedding a secret in Free Software" part of the OAuth registration
> issue, at least for Microsoft servers.
>

I think this is unlikely due to the reason outlined above. MS isn't
really that interested in either the 'individual' or simply providing
email. They are selling a much bigger picture with a focus on the
'enterprise' and selling snake oil to those C level executives who are
worried about security and PR who think the solution is to manage and
restrict what users can do.

It is likely that if you have to use Office 365/Outlook, then davmail
may be the best solution. At least it is GPL'd software. 



  parent reply	other threads:[~2021-08-08 16:05 UTC|newest]

Thread overview: 75+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-03  5:00 oauth2 support for Emacs email clients Roland Winkler
2021-08-03  6:32 ` Uwe Brauer
2021-08-03  8:21 ` Andrew Cohen
2021-08-03 19:38   ` Roland Winkler
2021-08-04  0:56     ` Andrew Cohen
2021-08-04  7:27       ` Andrew Cohen
2021-08-04  7:41       ` Andreas Schwab
2021-08-04 23:12         ` Andrew Cohen
2021-08-04  7:03   ` Lars Ingebrigtsen
2021-08-04  7:21     ` Andrew Cohen
2021-08-05 10:34       ` Lars Ingebrigtsen
2021-08-03  9:00 ` Gregory Heytings
2021-08-03 19:27   ` Roland Winkler
2021-08-03 22:02     ` Gregory Heytings
2021-08-05  0:21     ` Andrew Cohen
2021-08-10 14:39       ` Roland Winkler
2021-08-11  0:43         ` Andrew Cohen
2021-08-11  0:54           ` Andrew Cohen
2021-08-12  2:16             ` Richard Stallman
2021-08-12  2:33               ` Andrew Cohen
2021-08-03 20:21   ` Arthur Miller
2021-08-03 20:40     ` Gregory Heytings
2021-08-03 21:14       ` Eric Abrahamsen
2021-08-03 21:19         ` Gregory Heytings
2021-08-14 10:46       ` Richard Stallman
2021-08-14 11:12         ` Gregory Heytings
2021-08-14 11:47           ` Ulrich Mueller
2021-08-15  3:04           ` Richard Stallman
2021-08-15  3:04           ` Making your own application credentials as a user Richard Stallman
2021-08-15  4:10             ` Tim Cross
2021-08-03  9:20 ` oauth2 support for Emacs email clients Eric S Fraga
2021-08-03 11:17   ` Tim Cross
2021-08-03 12:55     ` Gregory Heytings
2021-08-03 13:14       ` tomas
2021-08-05 14:15         ` Richard Stallman
2021-08-03 15:04     ` Eric S Fraga
2021-08-03 19:45       ` Roland Winkler
2021-08-04  6:58         ` Eric S Fraga
2021-08-03 19:41   ` Roland Winkler
2021-08-04  6:59     ` Eric S Fraga
2021-08-04 14:45     ` Thomas Fitzsimmons
2021-08-04 22:45       ` Tim Cross
2021-08-04 23:29         ` Thomas Fitzsimmons
2021-08-05  7:45         ` Ulrich Mueller
2021-08-08  3:58       ` Richard Stallman
2021-08-09  8:30         ` Eric S Fraga
2021-08-12  2:15           ` Richard Stallman
2021-08-12 18:59             ` Roland Winkler
2021-08-03 23:38 ` Richard Stallman
2021-08-08  6:01   ` Roland Winkler
2021-08-08  6:30     ` Andreas Schwab
2021-08-08 23:48       ` Roland Winkler
2021-08-09  0:01         ` Andrew Cohen
2021-08-08  8:52     ` David Engster
2021-08-08 14:22       ` Thomas Fitzsimmons
2021-08-08 14:47         ` David Engster
2021-08-08 15:30           ` Thomas Fitzsimmons
2021-08-08 16:00             ` David Engster
2021-08-08 23:31               ` Roland Winkler
2021-08-10  2:01               ` Thomas Fitzsimmons
2021-08-10  9:07                 ` David Engster
2021-08-10 14:41                   ` Thomas Fitzsimmons
2021-08-10 15:56                     ` David Engster
2021-08-11  6:37                       ` Alexandre Garreau
2021-08-11  3:00                   ` Richard Stallman
2021-08-11  9:57                     ` David Engster
2021-08-13  3:10                       ` Richard Stallman
2021-08-11  2:55                 ` Richard Stallman
2021-08-14 15:00                   ` Thomas Fitzsimmons
2021-08-14 15:26                     ` Gregory Heytings
2021-08-08 16:05             ` Tim Cross [this message]
2021-08-09  8:39               ` Eric S Fraga
2021-08-10  3:29       ` Richard Stallman
2021-08-10  6:08         ` Tim Cross
2021-08-10 14:18           ` Roland Winkler

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87im0frj5r.fsf@gmail.com \
    --to=theophilusx@gmail.com \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).