Forum Discussion
Can't send SMTP mail after setting Default Security in Office 365
- Dec 01, 2020
LusoAdmin Hey there. I'll put the solution here because as far as I can tell, everyone should also have that problem now. It took 1 week with the Microsoft support to finally find the solution. Just like I thought, because now the default security is enabled when you create a new tenant, even if you disable it, smtp somehow stays disabled and that overrides the settings in your admin panel.
All you have to do is enable it in Powershell. To connect with Powershell, first you have to execute this:
Connect-MsolService
Import-Module ExchangeOnlineManagement
Connect-ExchangeOnlineThen you enter your admin credentials. After that, you can check the "smtp disabled" flag, it should be set to "true":
Get-TransportConfig | Format-List SmtpClientAuthenticationDisabled
To enable smtp and get things working again, you enter this command:
Set-TransportConfig -SmtpClientAuthenticationDisabled $false
Worked for all my tenants. I hope this helps you too!
New tenant, came with Security Defaults active by default (thanks Microsoft), which I have disabled in Azure Portal, doesn't work with the same exact connector configuration! We use this for our multifunctional printers to scan documents.... Spend 1 hour yesterday with Microsoft on the phone, they check both tenants, checked pretty much what i have already checked and reach no conclusion.... They told me that tenant was dehydrated, they would do something on the background and that they would get back in touch today!
2 Days fighting this stupid problem when I have other important things to do!
LusoAdmin Hey there. I'll put the solution here because as far as I can tell, everyone should also have that problem now. It took 1 week with the Microsoft support to finally find the solution. Just like I thought, because now the default security is enabled when you create a new tenant, even if you disable it, smtp somehow stays disabled and that overrides the settings in your admin panel.
All you have to do is enable it in Powershell. To connect with Powershell, first you have to execute this:
Connect-MsolService
Import-Module ExchangeOnlineManagement
Connect-ExchangeOnline
Then you enter your admin credentials. After that, you can check the "smtp disabled" flag, it should be set to "true":
Get-TransportConfig | Format-List SmtpClientAuthenticationDisabled
To enable smtp and get things working again, you enter this command:
Set-TransportConfig -SmtpClientAuthenticationDisabled $false
Worked for all my tenants. I hope this helps you too!
- PhilipD4GoodFeb 12, 2021Copper Contributor
ssimard Thank you for this info.
Does this work with Security Defaults on or did you also have to disable Security Defaults and leave it off for your tenants?- ssimardFeb 12, 2021Copper Contributor
PhilipD4Good Glad I could help you guys. Security Default is disabled for all my tenants, so I don't know if you could leave it on.
- scottay1217Feb 11, 2021Copper Contributor
ssimard You , my friend, are my savior. I've been battling this issue for 2 days, messing with every setting I could find in O365 and Azure AD, and this simple PowerShell solved my issue instantly.