{"id":284,"date":"2007-05-03T03:27:00","date_gmt":"2007-05-03T03:27:00","guid":{"rendered":"https:\/\/defragged.org\/ossec\/?p=284"},"modified":"2020-07-03T03:28:34","modified_gmt":"2020-07-03T03:28:34","slug":"granular-e-mail-alerting","status":"publish","type":"post","link":"https:\/\/defragged.org\/ossec\/2007\/05\/granular-e-mail-alerting\/","title":{"rendered":"Granular e-mail alerting"},"content":{"rendered":"\n<p>One of the most popular feature requests for&nbsp;<a href=\"http:\/\/www.ossec.net\/\">ossec<\/a>&nbsp;that I received lately was the availability of granular e-mail alerting options. Well, if you have been waiting for it, it is now available to be used\u2026 Just try our first beta release of&nbsp;<strong>version 1.2<\/strong>&nbsp;and let us know how it goes.<\/p>\n\n\n\n<p>Here are some examples of what you can do:<\/p>\n\n\n\n<p>If you want to e-mail xx@y.z for every event in the group syslog you can add the following to ossec:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">  &lt;email_alerts&gt;\n   &lt;email_to&gt;xx@y.z&lt;\/email_to&gt;\n   &lt;group&gt;syslog&lt;\/group&gt;\n &lt;\/email_alerts&gt;<\/pre>\n\n\n\n<p>To e-mail (sms format) aa@y.z for every event with severity higher than 10 (Note that the SMS format is not grouped, so the e-mail is sent immediately):<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">  &lt;email_alerts&gt;\n   &lt;email_to&gt;aa@y.z&lt;\/email_to&gt;\n   &lt;level&gt;10&lt;\/level&gt;\n   &lt;format&gt;sms&lt;\/format&gt;\n &lt;\/email_alerts&gt;<\/pre>\n\n\n\n<p>To e-mail bb@y.z for every event from rule 123 or rule 124:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"> &lt;email_alerts&gt;\n   &lt;email_to&gt;bb@y.z&lt;\/email_to&gt;\n   &lt;rule_id&gt;123, 124&lt;\/rule_id&gt;\n &lt;\/email_alerts&gt;<\/pre>\n\n\n\n<p>To e-mail cc@y.z for every event with severity higher than 12, from agent qwert, without any delay (immediately):<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"> &lt;email_alerts&gt;\n   &lt;email_to&gt;cc@y.z&lt;\/email_to&gt;\n   &lt;level&gt;12&lt;\/level&gt;\n   &lt;event_location&gt;qwerty&lt;\/event_location&gt;\n   &lt;do_not_delay \/&gt;\n &lt;\/email_alerts&lt;<\/pre>\n\n\n\n<p>You just need to tweak it for you own needs. Send any questions to our mailing list or here in the comments.<\/p>\n\n\n\n<p>Download it from here (always use the latest package available):&nbsp;<a href=\"http:\/\/www.ossec.net\/files\/snapshots\/\">beta snapshots<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>One of the most popular feature requests for&nbsp;ossec&nbsp;that I received lately was the availability of granular e-mail alerting options. Well, if you have been waiting for it, it is now available to be used\u2026 Just try our first beta release of&nbsp;version 1.2&nbsp;and let us know how it goes. Here are some examples of what you [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[2],"tags":[12],"_links":{"self":[{"href":"https:\/\/defragged.org\/ossec\/wp-json\/wp\/v2\/posts\/284"}],"collection":[{"href":"https:\/\/defragged.org\/ossec\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/defragged.org\/ossec\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/defragged.org\/ossec\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/defragged.org\/ossec\/wp-json\/wp\/v2\/comments?post=284"}],"version-history":[{"count":1,"href":"https:\/\/defragged.org\/ossec\/wp-json\/wp\/v2\/posts\/284\/revisions"}],"predecessor-version":[{"id":285,"href":"https:\/\/defragged.org\/ossec\/wp-json\/wp\/v2\/posts\/284\/revisions\/285"}],"wp:attachment":[{"href":"https:\/\/defragged.org\/ossec\/wp-json\/wp\/v2\/media?parent=284"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/defragged.org\/ossec\/wp-json\/wp\/v2\/categories?post=284"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/defragged.org\/ossec\/wp-json\/wp\/v2\/tags?post=284"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}