Working with 2FA-enabled mail (app password not possible)

Brian May brian at
Wed Jan 8 12:50:50 PST 2020

Chris Coutinho <chrisbcoutinho at> writes:

> My company recently made our Office365 mail service 2FA-enabled by
> default and disallowed app-specific passwords. Before this, I used
> Offlineimap to download my mail and index/search it using Notmuch. Now
> that that's no longer possible, I'm looking to the community for
> options.
> What do you use for syncing your mail to your local system(s) and
> utilizing the power of Notmuch?

Hmm. Wonder if this is the real reason IMAP suddenly stopped working for
me on my work Office365 domain after updating my password. Although it
does work for some people. Weird.

OAuth is the solution for Google, and I suspect OAuth may be the
solution for Microsoft too. If so, you need a program that supports IMAP
using OAuth.

gemail supports Google OAuth, I suspect it might be possible to get it
to work with Microsoft too. However I don't know anything about how to
register the Oauth app with Microsoft.

Apparently OfflineIMAP also supports Oauth.

Another option might be davmail.
Brian May <brian at>

More information about the notmuch mailing list