Hi,
You say that the alerts were sent correctly via email before, right? Has any configuration been changed recently? Either in the wazuh-manager or in the SMTP server?
Before starting debugging process in the wazuh-manager, I would try with the test messages until you get these messages sent and received correctly.
echo "Test mail from postfix" | mail -s "Test Postfix" -r "y...@example.com" y...@example.com
From here, if you receive these test emails and not the alerts, I would start with the wazuh-manager debugging.
Now, starting with the debugging of your SMTP server configuration, the easiest and fastest way would be to check if there has been any configuration change, IPs, DNSs … that could have caused the conflict and make it not work.
Surely, the postfix logs recorded in /var/log/maillog of your SMTP server host, can give you some more information, for example, I share some “error” logs after trying to send the test message:
Aug 1 11:03:28 mail2 postfix/bounce[53348]: warning: /etc/postfix/main.cf, line 745: overriding earlier entry: smtp_tls_CAfile=/etc/pki/tls/certs/ca-bundle.crt
Aug 1 11:03:28 mail2 postfix/smtp[53347]: 438D5188511C: to=<x...@hotmail.com>, relay=smtp.office365.com[40.x.138.x]:587, delay=5.4, delays=0.02/0.02/0.31/5, dsn=5.7.57, status=bounced (host smtp.office365.com[40.101.x.2] said: 530 5.7.57 Client not authenticated to send mail. [PR2P264CA0005.FRAP264.PROD.OUTLOOK.COM] (in reply to MAIL FROM command))
Aug 1 11:03:28 mail2 postfix/smtp[53347]: 438D5188511C: lost connection with smtp.office365.com[40.101.x.2] while sending RCPT TO
Aug 1 11:03:28 mail2 postfix/cleanup[53345]: A5A60188511D: message-id=<2022080111032...@mail2.localdomain>
Aug 1 11:03:28 mail2 postfix/qmgr[51743]: A5A60188511D: from=<>, size=2605, nrcpt=1 (queue active)
Aug 1 11:03:28 mail2 postfix/bounce[53348]: 438D5188511C: sender non-delivery notification: A5A60188511D
Aug 1 11:03:28 mail2 postfix/qmgr[51743]: 438D5188511C: removed
From this information, I would check configurations, connections … until you actually manage to send them.
x x 00:58:35 mwiapp01 postfix/smtp[26151]: 28D5A4078131:
to=<som...@somecompany.com>, relay=example.outlook.com[104.47.100.36]:25,
delay=7.8, delays=0.06/0.05/4.2/3.5, dsn=2.6.0,
status=sent (250 2.6.0 <5f236cb4.kaTYiINfdbNN2Gyr%user...@gritfy.com> [InternalId=22905060593379, Hostname=MAXPR01MB4031.INDPRD01.PROD.OUTLOOK.COM] 8684 bytes in 0.610, 13.883 KB/sec Queued mail for delivery)
x x 00:58:35 mwiapp01 postfix/qmgr[25474]: 28D5A4078131: removed
Regarding your ossec.conf file configuration I don’t see anything strange, so I imagine that as soon as you solve the problems and configurations of your SMTP server, you should receive the alert emails. If this is not the case, do not hesitate to let me know so I can help you with that issue.
Best regards.
--
You received this message because you are subscribed to a topic in the Google Groups "Wazuh mailing list" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/wazuh/tbYixGJtpKQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to wazuh+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/wazuh/475ddbde-483f-4d11-9a1f-34f7b2c22964n%40googlegroups.com.