NetXMS Support Forum

English Support => General Support => Topic started by: ruidias on April 02, 2024, 12:34:08 PM

Title: NETXMS EMAIL NOTIFICATION - OFFICE365
Post by: ruidias on April 02, 2024, 12:34:08 PM
Hello everyone,

I've searched the forum and although I've found a few posts I haven't been able to find a solution for sending notification emails using the Office365 servers.

Example of my configuration:
Server=smtp.office365.com
[email protected]
Password=##########
Port=587
TLSMode=STARTTLS
RetryCount=1
FromName=Account Name
[email protected]
MailEncoding=utf8
IsHTML=yes


How did you encrypt the password? There's some help in the manual, but I'm not sure what kind of encryption Office365 uses.

Are these the right settings or is something missing? When i try to send a email i get DRIVER ERROR


Title: Re: NETXMS EMAIL NOTIFICATION - OFFICE365
Post by: Filipp Sudanov on April 03, 2024, 11:16:51 AM
Try issuing
debug nc 8
debug ncd.* 8

in Tools->Server Debug Console. Then try to send another email and show what you have in your server log (/var/log/netxmsd on Linux)
Title: Re: NETXMS EMAIL NOTIFICATION - OFFICE365
Post by: ruidias on April 03, 2024, 11:41:45 AM
2024.04.03 08:38:18.202 *D* [ncd.smtp          ] Call to curl_easy_perform("smtp://smtp.office365.com:587") failed (67: Login denied)
2024.04.03 08:38:18.202 *D* [nc                ] Driver error for channel "SMTP HTML OFFICE365", message dropped

I try the password as plain text and encrypted with nxencpasswd ..
Title: Re: NETXMS EMAIL NOTIFICATION - OFFICE365
Post by: Filipp Sudanov on April 03, 2024, 11:54:38 AM
The password should normally work unencrypted. The only exception is when the password itself is base-64 encoded and has specific length (44 or 88 characters) - in this case NetXMS will think that it's something encripted by nxencpasswd - in this case the workaround is to actually encrypt it with nxencpasswd.
Also, double-check the "Login" field.
Title: Re: NETXMS EMAIL NOTIFICATION - OFFICE365
Post by: MarcusH on April 05, 2024, 02:21:33 PM
To send mail with authenticated SMTP with 365 user the account has to have that function enabled.
Since it is big security issue for bigger organisations that function is most likely disabled.