Invalid login or password for IMAP, Exchange

Hello, I’m working on version 7.12 and on an AWS ec2 ubuntu instance. I was able to successfully connect my personal outlook account to inbound email via the following settings:
Mail Server Address:
Mail Server Protocol: IMAP
Mail Server Port:993

But, when I try with an office 365 business account with a specified domain:, it repeatedly complains about invalid login and password, despite it being correct. I was not able to locate anything in suitecrm.log, and my server log just complains: PHP Notice: Unknown: Can not authenticate to IMAP server: AUTHENTICATE failed

I went to the office 365 admin and made sure IMAP is enabled for every user, also looked into azure apps and OAuth, but still could not get it to work. Are there any hints to better debug or solutions for this? Thanks in advance!!!

Hi @peterze,
please have a look: A Beginner's Guide to IMAP and SMTP Server Settings.
Video guide: - How to Bypass 2 step verification for Third-Party Apps using App Password - YouTube
You need to generate an app password because policy change on 30 May 2022. Please look:- Less secure apps & your Google Account - Google Account Help?


hi @vijay1992

Any idea on how to solve this once App passwords are disabled?
End of support for Basic Authentication access to Exchange Online API’s for Office 365 customers - SuiteCRM Forum - English Language / Developer Collaboration - SuiteCRM

You can try this method here you don’t need to enable the APP Password