Forum Discussion
bradsalvin
Sep 26, 2023Copper Contributor
IMAP login to office365
Hello everyone
I am ROR developer working on a application in which I have to read emails received on this office365 account via IMAP but currently I am not able to login via IMAP (did logged in once about 5 to 6 months ago by disabling "security defaults", but this thing is not working now).
I don't have enough technical knowledge of Azure or Exchange I just want to login remotely using IMAP and read emails. I went through the docs but at the end, I was just confused.
Preferably I want to login without following OAUTH flow if it is possible on today's date (26 sept 23) but if there is no way forward without OAUTH then guide me to login using OAUTH.
Please tell what i need enable/disable , 2FA, security defaults anything else. as It is urgent. thank you.
- Only OAuth is supported nowadays, as Microsoft pulled the plug on any basic authentication methods in the service, "plain" IMAP included. If you have an app that leverages IMAP, you need to update it to use leverage OAuth to get an access token/SASL XOAUTH2 encode and transmit it, as detailed here: https://learn.microsoft.com/en-us/exchange/client-developer/legacy-protocols/how-to-authenticate-an-imap-pop-smtp-application-by-using-oauth
- bradsalvinCopper ContributorFirst of all, thank you Vasil for sparing time.
Google terminated plain IMAP access last year but we use plain authentication by enabling 2FA and then using app password so havn't microsoft provided any way like this to use plain authentication.- They did, but that's not a real solution to the basic auth problem. So now that basic auth is deprecated, you have to switch to OAuth/SASL XOAUTH2.