SMTP Microsoft 365 / Corteza

Hello, everyone.

I have been experiencing a problem configuring the Corteza SMTP server for some time now.

The GMAIL configuration works, but the Office 365 configuration does not.

I am getting this error:

server: 504 5.7.4 Unrecognized authentication type

However, with the same configuration settings, I am able to test sending emails with the Swkas tool:

swaks -t test@mail.ci -s smtp.office365.com:587 -tls -au test@mail.ci -ap @test -f test@mail.ci

From what I can see we need to add a few extra parameters to the email sender in order to use Outlook for emails.
I’ll add it when I find some downtime

Hello @tjerman,

Thank you for your feedback.

We are therefore awaiting the update.

I’m not super technical, but have a hunch, the error may not be solely on the Corteza side.

While Office 365 supports SMTP, the error you’re seeing, “504 5.7.4 Unrecognized authentication type,” indicates a problem with the authentication method your Corteza application is using to connect to the Office 365 SMTP server. This is a common issue because Microsoft 365 has specific and strict requirements for SMTP authentication.

The failure is likely due to one or more of the following:

  • SMTP AUTH is disabled: By default, SMTP authentication (SMTP AUTH) may be disabled at a global or user level in Microsoft 365. You need to enable this for the specific mailbox you’re trying to use.

  • Multi-Factor Authentication (MFA): If the user account has MFA enabled, you must use an app password instead of the regular account password.

  • TLS/SSL Mismatch: There may be a mismatch between the encryption method (e.g., STARTTLS) and the port number (587 is standard for STARTTLS) being used. Microsoft 365 requires TLS 1.2. (This would be my primary suspect, but just guessing)

  • Outdated Authentication: Microsoft is in the process of deprecating or has already deprecated basic authentication for some services, which could be causing the “unrecognized” error. Some applications may not be configured to use more modern authentication methods like OAuth 2.0.

1 Like

Hello @simple1 , thank you for your reply.

SMTP AUTH is indeed enabled, and MFA authentication is disabled.

As I mentioned earlier in this thread, I used the SMTP tool

swaks -t test@mail.ci -s smtp.office365.com:587 -tls -au test@mail.ci -ap @test -f test@mail.ci

to run the test to make sure that the Microsoft 365 settings were OK, and the test was successful.

1 Like

The swaks test confirms that the Office 365 settings are correct and that SMTP AUTH is enabled for the user. This means the issue likely lies specifically with the Corteza application’s configuration or its underlying library’s handling of the SMTP connection.
Check Corteza’s internal library to see if it might be using an older TLS version that is not compatible with Office 365’s strict TLS 1.2 requirement.

Last
Corteza application may be hard-coded to use a specific, incompatible type Login.

If none of those, I’m out of ideas . . . :frowning:

1 Like

Thanks for your recommendations.
I’ll try to set up an external SMTP server accessible via API.

1 Like