下面是我的wazuh管理器的配置
<logall json>no</logall_json>
<email_notification>yes</email_notification>
<smtp_server>smtp.gmail.com</smtp_server>
<email_from>securesally@gmail.com</email_from>
<email_to>mannupriyajb983@gmail.com</email_to>
<email_maxperhour>12</email_maxperhour>
<email_log_source>alerts.log</email_log_source>
<agents_disconnection_time>10m</agents_disconnection_time>
<agents_disconnection_alert_time>0</agents_disconnection_alert_time>
这是 www.example. com configuration relayhost = [ www.example.com ]:587 smtp_sasl_auth_enable = yes smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd smtp_sasl_security_options = noanonymous smtp_tls_CAfile = /etc/ssl/certs/ca-certificates.crt smtp_use_tls = yes smtpd_relay_restrictions = permit_mynetworks,permit_sasl_authenticated,defer_unauth_destination
那么下一步该怎么做才能使它发挥作用呢
2条答案
按热度按时间zfycwa2u1#
要为gmail帐户配置提醒,您可以按照以下documentation操作。
我从你的评论中了解到,你已经按照这个指令一步一步地执行了,你能执行下面的命令来评估到服务器的连接是否正确吗?
我等待你的评论,问候,尼古拉斯
disbfnqx2#
当使用SMTP中继服务器配置Wazuh时,如the documentation中所述,
<smtp_server>
设置应为localhost
,而不是gmail smtp服务器。另外,请确保使用app password而不是gmail凭据。
按照Nof的建议,为了验证继电器是否正常工作,您可以运行:
如果这不起作用,那么请分享
/var/log/maillog
中的任何错误,如果这起作用,但您仍然没有看到Wazuh预期的电子邮件警报,那么分享以下输出: