Email Format

64 views
Skip to first unread message

test wazuh

unread,
Aug 8, 2022, 10:17:26 AM8/8/22
to Wazuh mailing list
Hi ,
Is there a way to pretty print the formatting of emails sent via Wazuh?

Nicolas Zapata

unread,
Aug 8, 2022, 10:53:59 AM8/8/22
to Wazuh mailing list

Hi, thanks for using Wazuh

At this moment, email alerts cannot be configured without editing the source code.

Alternatively, you can use a custom integration (I recommend you to have a look at this blogpost) and use a python script that gets the alerts and send them.

In the manager you need to add these lines to the configuration:

<integration> 
        <name>custom-email-alerts</name> 
        <hook_url>emailre...@example.com</hook_url> 
        <level>10</level> 
        <group>multiple_drops|authentication_failures</group> 
        <alert_format>json</alert_format> 
  </integration>

The python script has to be in a specific path (/var/ossec/integrations/custom-email-alert) and with the proper permissions. You can use these commands to set the permissions and the owner.

chmod 750 /var/ossec/integrations/custom-email-alerts.py 
chown root:ossec /var/ossec/integrations/custom-email-alerts.py

I attached an example of the script. 

You can follow this github issue to find out if there are new developments in the format of email alerts
custom-email-alert.py
Reply all
Reply to author
Forward
0 new messages