[Bug]: OAuth authenticated, but testing throws an error
Is there an existing issue for this?
- [x] I have searched the existing issues
What happened?
I set up the OAuth Exchange Online SMTP settings in DNN 10.1.2 and verified "Your OAuth provider's configuration has been completed."
However, when I test the SMTP settings, I get the following error: There is a problem with the configuration of your SMTP Server. Mail was not sent. 535: 5.7.3 Authentication unsuccessful [MN0PR02CA0003.namprd02.prod.outlook.com 2025-10-17T16:03:50.567Z 08DE0D6838535D6C]
I guess I'm confused as to why the configuration was successful, but the mail can't be sent.
Steps to reproduce?
Current Behavior
No response
Expected Behavior
No response
Relevant log output
Anything else?
No response
Affected Versions
10.1.2 (latest v10 release)
What browsers are you seeing the problem on?
No response
Code of Conduct
- [x] I agree to follow this project's Code of Conduct
I could be wrong, but it looks like the DNN side is fully setup, but seeing 5.7.3 seems like you haven't jumped through all the (setup) hoops on the "Exchange side" of things to allow the connection (from DNN). Could be API permissions or a handful of other things. What docs or other reference are you using to set this up? Are you able to drill down on the Exchange side and see the logs of the SMTP conversation?
We followed these: https://docs.dnncommunity.org/content/tutorials/server/smtp-servers/set-up-oauth-microsoft-365/index.html
Microsoft may also have rules about the "from" address needing to be part of the account. Just a shot in the dark here as I do not use it for sending website mail, but you could try making sure the from matches the account email?
Now I got this error...
Strange, does it happen with other mail providers, like if you setup a free account with resend.com? I do not use outlook for website mailing, don't know if anyone else has a clue on testing that...