Added Alerts section

This commit is contained in:
JuanjiJG 2018-09-12 15:26:45 +02:00
parent cfbb85fa9b
commit 536e7d43f8
9 changed files with 604 additions and 3 deletions

View File

@ -0,0 +1,23 @@
<div flex="auto" layout="column" ng-if="!load && configurationTab === 'alerts'" ng-init="switchConfigurationSubTab('general-alerts')">
<!-- Headline -->
<div layout="column" layout-padding>
<div>
<span class="font-size-18">Alerts</span>
</div>
<span class="md-subheader">Configure everything related to the alerts and their format</span>
</div>
<!-- End headline -->
<!-- Alerts navigation bar -->
<md-nav-bar
class="wz-nav-bar"
md-selected-nav-item="configurationSubTab"
nav-bar-aria-label="Alerts navigation links">
<md-nav-item class="wz-nav-item" md-nav-click="switchConfigurationSubTab('general-alerts')" name="general-alerts">General</md-nav-item>
<md-nav-item class="wz-nav-item" md-nav-click="switchConfigurationSubTab('labels')" name="labels">Labels</md-nav-item>
<md-nav-item class="wz-nav-item" md-nav-click="switchConfigurationSubTab('email-alerts')" name="email-alerts">Email alerts</md-nav-item>
<md-nav-item class="wz-nav-item" md-nav-click="switchConfigurationSubTab('reports')" name="reports">Reports</md-nav-item>
<md-nav-item class="wz-nav-item" md-nav-click="switchConfigurationSubTab('syslog')" name="syslog">Syslog output</md-nav-item>
</md-nav-bar>
<!-- End Alerts navigation bar -->

View File

@ -0,0 +1,7 @@
include ./alerts.head
include ./email-alerts/email-alerts.html
include ./general-alerts/general-alerts.html
include ./labels/labels.html
include ./reports/reports.html
include ./syslog/syslog.html
include ../../../footer.foot

View File

@ -0,0 +1,120 @@
<!-- This section contains the main content and the right sidenav -->
<div flex="auto" layout="row" ng-if="configurationSubTab === 'email-alerts'">
<!-- This section appears when there's no configuration -->
<wz-no-config flex ng-if="false"></wz-no-config>
<!-- End no configuration section -->
<!-- This section is the main content -->
<div flex layout="column">
<!-- The main card will all the settings -->
<md-card class="wz-md-card" ng-if="!JSONContent && !XMLContent">
<md-card-content>
<span class="font-size-16">Main settings</span>
<md-divider class="wz-margin-top-10"></md-divider>
<!-- Configuration block -->
<div class="wz-padding-top-10">
<wz-config-item
label="Send alerts to this email address"
value="enabled">
</wz-config-item>
<wz-config-item
label="Minimum severity level to send the alert by email"
value="enabled">
</wz-config-item>
<wz-config-item
label="Send only alerts that belong to one of these groups"
value="enabled">
</wz-config-item>
<wz-config-item
label="Send alerts when they match this event location"
value="enabled">
</wz-config-item>
<wz-config-item
label="Format for email alerts"
value="enabled">
</wz-config-item>
<wz-config-item
label="SSend only alerts that belong to one of these rule IDs"
value="enabled">
</wz-config-item>
<wz-config-item
label="Disable delayed email delivery"
value="enabled">
</wz-config-item>
<wz-config-item
label="Disable alerts grouping into the same email"
value="enabled">
</wz-config-item>
</div>
<!-- End configuration block -->
</md-card-content>
</md-card>
<!-- End main card with all the settings -->
<!-- JSON card -->
<md-card flex="auto" class="wz-md-card" ng-if="JSONContent">
<md-card-content flex layout="column">
<span class="font-size-16">JSON viewer</span>
<md-divider class="wz-margin-top-10"></md-divider>
<!-- The JSON viewer -->
<div flex="auto" class="wz-margin-top-10 wz-code-viewer">
<pre><code wz-dynamic="JSONContent"></code></pre>
</div>
<!-- End JSON viewer -->
</md-card-content>
</md-card>
<!-- End JSON card -->
<!-- XML card -->
<md-card flex="auto" class="wz-md-card" ng-if="XMLContent">
<md-card-content flex layout="column">
<span class="font-size-16">XML viewer</span>
<md-divider class="wz-margin-top-10"></md-divider>
<!-- The XML viewer -->
<div flex="auto" class="wz-margin-top-10 wz-code-viewer">
<pre>{{ XMLContent }}</pre>
</div>
<!-- End XML viewer -->
</md-card-content>
</md-card>
<!-- End XML card -->
</div>
<!-- End main content section -->
<!-- This section is the right sidenav content -->
<md-sidenav
class="md-sidenav-right"
md-is-locked-open="true">
<md-list>
<md-subheader>Any questions?</md-subheader>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://documentation.wazuh.com/current/user-manual/manager/manual-email-report/index.html">How to configure email alerts</md-list-item>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://documentation.wazuh.com/current/user-manual/manager/manual-email-report/smtp_authentication.html">How to configure authenticated SMTP server</md-list-item>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://documentation.wazuh.com/current/user-manual/reference/ossec-conf/email_alerts.html">Email alerts reference</md-list-item>
<md-divider></md-divider>
<md-subheader>Having trouble?</md-subheader>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://groups.google.com/forum/#!forum/wazuh">Ask on the mailing list</md-list-item>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://github.com/wazuh/wazuh/issues">Ask on GitHub</md-list-item>
<md-divider></md-divider>
<md-subheader>More options</md-subheader>
<md-list-item layout-wrap>
<md-button ng-class="JSONContent ? 'active' : ''" class="wz-button md-raised md-primary small" ng-click="getJSON('email_alerts')">{{ JSONContent ? "Close JSON viewer" : "Open JSON viewer" }}</md-button>
<md-button ng-class="XMLContent ? 'active' : ''" class="wz-button md-raised md-primary small" ng-click="getXML('email_alerts')">{{ XMLContent ? "Close XML viewer" : "Open XML viewer" }}</md-button>
</md-list-item>
</md-list>
</md-sidenav>
<!-- End right sidenav section -->
</div>
<!-- End main content and right sidenav section -->

View File

@ -0,0 +1,99 @@
<!-- This section contains the main content and the right sidenav -->
<div flex="auto" layout="row" ng-if="configurationSubTab === 'general-alerts'">
<!-- This section appears when there's no configuration -->
<wz-no-config flex ng-if="false"></wz-no-config>
<!-- End no configuration section -->
<!-- This section is the main content -->
<div flex layout="column">
<!-- The main card will all the settings -->
<md-card class="wz-md-card" ng-if="!JSONContent && !XMLContent">
<md-card-content>
<span class="font-size-16">Main settings</span>
<md-divider class="wz-margin-top-10"></md-divider>
<!-- Configuration block -->
<div class="wz-padding-top-10">
<wz-config-item
label="Minimum severity level to store the alert"
value="3">
</wz-config-item>
<wz-config-item
label="Minimum severity level to send the alert by email"
value="enabled">
</wz-config-item>
<wz-config-item
label="Enable GeoIP lookups"
value="no">
</wz-config-item>
</div>
<!-- End configuration block -->
</md-card-content>
</md-card>
<!-- End main card with all the settings -->
<!-- JSON card -->
<md-card flex="auto" class="wz-md-card" ng-if="JSONContent">
<md-card-content flex layout="column">
<span class="font-size-16">JSON viewer</span>
<md-divider class="wz-margin-top-10"></md-divider>
<!-- The JSON viewer -->
<div flex="auto" class="wz-margin-top-10 wz-code-viewer">
<pre><code wz-dynamic="JSONContent"></code></pre>
</div>
<!-- End JSON viewer -->
</md-card-content>
</md-card>
<!-- End JSON card -->
<!-- XML card -->
<md-card flex="auto" class="wz-md-card" ng-if="XMLContent">
<md-card-content flex layout="column">
<span class="font-size-16">XML viewer</span>
<md-divider class="wz-margin-top-10"></md-divider>
<!-- The XML viewer -->
<div flex="auto" class="wz-margin-top-10 wz-code-viewer">
<pre>{{ XMLContent }}</pre>
</div>
<!-- End XML viewer -->
</md-card-content>
</md-card>
<!-- End XML card -->
</div>
<!-- End main content section -->
<!-- This section is the right sidenav content -->
<md-sidenav
class="md-sidenav-right"
md-is-locked-open="true">
<md-list>
<md-subheader>Any questions?</md-subheader>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://documentation.wazuh.com/current/getting-started/use-cases.html">Use cases about alerts generation</md-list-item>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://documentation.wazuh.com/current/user-manual/reference/ossec-conf/alerts.html">Alerts reference</md-list-item>
<md-divider></md-divider>
<md-subheader>Having trouble?</md-subheader>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://groups.google.com/forum/#!forum/wazuh">Ask on the mailing list</md-list-item>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://github.com/wazuh/wazuh/issues">Ask on GitHub</md-list-item>
<md-divider></md-divider>
<md-subheader>More options</md-subheader>
<md-list-item layout-wrap>
<md-button ng-class="JSONContent ? 'active' : ''" class="wz-button md-raised md-primary small" ng-click="getJSON('alerts')">{{ JSONContent ? "Close JSON viewer" : "Open JSON viewer" }}</md-button>
<md-button ng-class="XMLContent ? 'active' : ''" class="wz-button md-raised md-primary small" ng-click="getXML('alerts')">{{ XMLContent ? "Close XML viewer" : "Open XML viewer" }}</md-button>
</md-list-item>
</md-list>
</md-sidenav>
<!-- End right sidenav section -->
</div>
<!-- End main content and right sidenav section -->

View File

@ -0,0 +1,103 @@
<!-- This section contains the main content and the right sidenav -->
<div flex="auto" layout="row" ng-if="configurationSubTab === 'labels'">
<!-- This section appears when there's no configuration -->
<wz-no-config flex ng-if="false"></wz-no-config>
<!-- End no configuration section -->
<!-- This section is the main content -->
<div flex layout="column">
<!-- The main card will all the settings -->
<md-card class="wz-md-card" ng-if="!JSONContent && !XMLContent">
<md-card-content>
<span class="font-size-16">Defined labels</span>
<md-divider class="wz-margin-top-10"></md-divider>
<!-- Configuration block -->
<div class="wz-padding-top-10">
<table class="table table-striped table-condensed" style="table-layout: fixed !important; margin: 0 !important;">
<thead class="wz-text-bold">
<th class="wz-text-left col-lg-9">Label key</th>
<th class="wz-text-left col-lg-3">Hidden</th>
</thead>
<tbody class="wz-word-wrap">
<tr>
<td>test</td>
<td>test</td>
</tr>
<tr>
<td>test</td>
<td>test</td>
</tr>
</tbody>
</table>
</div>
<!-- End configuration block -->
</md-card-content>
</md-card>
<!-- End main card with all the settings -->
<!-- JSON card -->
<md-card flex="auto" class="wz-md-card" ng-if="JSONContent">
<md-card-content flex layout="column">
<span class="font-size-16">JSON viewer</span>
<md-divider class="wz-margin-top-10"></md-divider>
<!-- The JSON viewer -->
<div flex="auto" class="wz-margin-top-10 wz-code-viewer">
<pre><code wz-dynamic="JSONContent"></code></pre>
</div>
<!-- End JSON viewer -->
</md-card-content>
</md-card>
<!-- End JSON card -->
<!-- XML card -->
<md-card flex="auto" class="wz-md-card" ng-if="XMLContent">
<md-card-content flex layout="column">
<span class="font-size-16">XML viewer</span>
<md-divider class="wz-margin-top-10"></md-divider>
<!-- The XML viewer -->
<div flex="auto" class="wz-margin-top-10 wz-code-viewer">
<pre>{{ XMLContent }}</pre>
</div>
<!-- End XML viewer -->
</md-card-content>
</md-card>
<!-- End XML card -->
</div>
<!-- End main content section -->
<!-- This section is the right sidenav content -->
<md-sidenav
class="md-sidenav-right"
md-is-locked-open="true">
<md-list>
<md-subheader>Any questions?</md-subheader>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://documentation.wazuh.com/current/user-manual/capabilities/labels.html">Labels documentation</md-list-item>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://documentation.wazuh.com/current/user-manual/reference/ossec-conf/labels.html">Labels reference</md-list-item>
<md-divider></md-divider>
<md-subheader>Having trouble?</md-subheader>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://groups.google.com/forum/#!forum/wazuh">Ask on the mailing list</md-list-item>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://github.com/wazuh/wazuh/issues">Ask on GitHub</md-list-item>
<md-divider></md-divider>
<md-subheader>More options</md-subheader>
<md-list-item layout-wrap>
<md-button ng-class="JSONContent ? 'active' : ''" class="wz-button md-raised md-primary small" ng-click="getJSON('labels')">{{ JSONContent ? "Close JSON viewer" : "Open JSON viewer" }}</md-button>
<md-button ng-class="XMLContent ? 'active' : ''" class="wz-button md-raised md-primary small" ng-click="getXML('labels')">{{ XMLContent ? "Close XML viewer" : "Open XML viewer" }}</md-button>
</md-list-item>
</md-list>
</md-sidenav>
<!-- End right sidenav section -->
</div>
<!-- End main content and right sidenav section -->

View File

@ -0,0 +1,127 @@
<!-- This section contains the main content and the right sidenav -->
<div flex="auto" layout="row" ng-if="configurationSubTab === 'reports'">
<!-- This section appears when there's no configuration -->
<wz-no-config flex ng-if="false"></wz-no-config>
<!-- End no configuration section -->
<!-- This section is the main content -->
<div flex layout="column">
<!-- The main card will all the settings -->
<md-card class="wz-md-card" ng-if="!JSONContent && !XMLContent">
<md-card-content>
<span class="font-size-16">Main settings</span>
<md-divider class="wz-margin-top-10"></md-divider>
<!-- Configuration block -->
<div class="wz-padding-top-10">
<wz-config-item
label="Report name"
value="enabled">
</wz-config-item>
<wz-config-item
label="Send report to this email address"
value="enabled">
</wz-config-item>
<wz-config-item
label="Include logs when creating a report"
value="enabled">
</wz-config-item>
<wz-config-item
label="Filter by this group"
value="enabled">
</wz-config-item>
<wz-config-item
label="Filter by this category"
value="enabled">
</wz-config-item>
<wz-config-item
label="Filter by this rule ID"
value="enabled">
</wz-config-item>
<wz-config-item
label="Filter by this alert level and above"
value="enabled">
</wz-config-item>
<wz-config-item
label="Filter by this log location"
value="enabled">
</wz-config-item>
<wz-config-item
label="Filter by this source IP address"
value="enabled">
</wz-config-item>
<wz-config-item
label="Filter by this user name"
value="enabled">
</wz-config-item>
</div>
<!-- End configuration block -->
</md-card-content>
</md-card>
<!-- End main card with all the settings -->
<!-- JSON card -->
<md-card flex="auto" class="wz-md-card" ng-if="JSONContent">
<md-card-content flex layout="column">
<span class="font-size-16">JSON viewer</span>
<md-divider class="wz-margin-top-10"></md-divider>
<!-- The JSON viewer -->
<div flex="auto" class="wz-margin-top-10 wz-code-viewer">
<pre><code wz-dynamic="JSONContent"></code></pre>
</div>
<!-- End JSON viewer -->
</md-card-content>
</md-card>
<!-- End JSON card -->
<!-- XML card -->
<md-card flex="auto" class="wz-md-card" ng-if="XMLContent">
<md-card-content flex layout="column">
<span class="font-size-16">XML viewer</span>
<md-divider class="wz-margin-top-10"></md-divider>
<!-- The XML viewer -->
<div flex="auto" class="wz-margin-top-10 wz-code-viewer">
<pre>{{ XMLContent }}</pre>
</div>
<!-- End XML viewer -->
</md-card-content>
</md-card>
<!-- End XML card -->
</div>
<!-- End main content section -->
<!-- This section is the right sidenav content -->
<md-sidenav
class="md-sidenav-right"
md-is-locked-open="true">
<md-list>
<md-subheader>Any questions?</md-subheader>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://documentation.wazuh.com/current/user-manual/manager/automatic-reports.html">How to generate automatic reports</md-list-item>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://documentation.wazuh.com/current/user-manual/reference/ossec-conf/reports.html">Reports reference</md-list-item>
<md-divider></md-divider>
<md-subheader>Having trouble?</md-subheader>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://groups.google.com/forum/#!forum/wazuh">Ask on the mailing list</md-list-item>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://github.com/wazuh/wazuh/issues">Ask on GitHub</md-list-item>
<md-divider></md-divider>
<md-subheader>More options</md-subheader>
<md-list-item layout-wrap>
<md-button ng-class="JSONContent ? 'active' : ''" class="wz-button md-raised md-primary small" ng-click="getJSON('reports')">{{ JSONContent ? "Close JSON viewer" : "Open JSON viewer" }}</md-button>
<md-button ng-class="XMLContent ? 'active' : ''" class="wz-button md-raised md-primary small" ng-click="getXML('reports')">{{ XMLContent ? "Close XML viewer" : "Open XML viewer" }}</md-button>
</md-list-item>
</md-list>
</md-sidenav>
<!-- End right sidenav section -->
</div>
<!-- End main content and right sidenav section -->

View File

@ -0,0 +1,121 @@
<!-- This section contains the main content and the right sidenav -->
<div flex="auto" layout="row" ng-if="configurationSubTab === 'syslog'">
<!-- This section appears when there's no configuration -->
<wz-no-config flex ng-if="false"></wz-no-config>
<!-- End no configuration section -->
<!-- This section is the main content -->
<div flex layout="column">
<!-- The main card will all the settings -->
<md-card class="wz-md-card" ng-if="!JSONContent && !XMLContent">
<md-card-content>
<span class="font-size-16">Main settings</span>
<md-divider class="wz-margin-top-10"></md-divider>
<!-- Configuration block -->
<div class="wz-padding-top-10">
<table class="table table-striped table-condensed" style="table-layout: fixed !important; margin: 0 !important;">
<thead class="wz-text-bold">
<th class="wz-text-left col-lg-2">Server</th>
<th class="wz-text-left col-lg-1">Port</th>
<th class="wz-text-left col-lg-1">Level</th>
<th class="wz-text-left col-lg-1">Format</th>
<th class="wz-text-left col-lg-1">FQDN</th>
<th class="wz-text-left col-lg-2">Rule ID</th>
<th class="wz-text-left col-lg-2">Group</th>
<th class="wz-text-left col-lg-2">Location</th>
</thead>
<tbody class="wz-word-wrap">
<tr>
<td>test</td>
<td>test</td>
<td>test</td>
<td>test</td>
<td>test</td>
<td>test</td>
<td>test</td>
<td>test</td>
</tr>
<tr>
<td>test</td>
<td>test</td>
<td>test</td>
<td>test</td>
<td>test</td>
<td>test</td>
<td>test</td>
<td>test</td>
</tr>
</tbody>
</table>
</div>
<!-- End configuration block -->
</md-card-content>
</md-card>
<!-- End main card with all the settings -->
<!-- JSON card -->
<md-card flex="auto" class="wz-md-card" ng-if="JSONContent">
<md-card-content flex layout="column">
<span class="font-size-16">JSON viewer</span>
<md-divider class="wz-margin-top-10"></md-divider>
<!-- The JSON viewer -->
<div flex="auto" class="wz-margin-top-10 wz-code-viewer">
<pre><code wz-dynamic="JSONContent"></code></pre>
</div>
<!-- End JSON viewer -->
</md-card-content>
</md-card>
<!-- End JSON card -->
<!-- XML card -->
<md-card flex="auto" class="wz-md-card" ng-if="XMLContent">
<md-card-content flex layout="column">
<span class="font-size-16">XML viewer</span>
<md-divider class="wz-margin-top-10"></md-divider>
<!-- The XML viewer -->
<div flex="auto" class="wz-margin-top-10 wz-code-viewer">
<pre>{{ XMLContent }}</pre>
</div>
<!-- End XML viewer -->
</md-card-content>
</md-card>
<!-- End XML card -->
</div>
<!-- End main content section -->
<!-- This section is the right sidenav content -->
<md-sidenav
class="md-sidenav-right"
md-is-locked-open="true">
<md-list>
<md-subheader>Any questions?</md-subheader>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://documentation.wazuh.com/current/user-manual/manager/manual-syslog-output.html">How to configure the syslog output</md-list-item>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://documentation.wazuh.com/current/user-manual/reference/ossec-conf/syslog-output.html">Syslog output reference</md-list-item>
<md-divider></md-divider>
<md-subheader>Having trouble?</md-subheader>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://groups.google.com/forum/#!forum/wazuh">Ask on the mailing list</md-list-item>
<md-list-item target="_blank" class="wz-text-link" ng-href="https://github.com/wazuh/wazuh/issues">Ask on GitHub</md-list-item>
<md-divider></md-divider>
<md-subheader>More options</md-subheader>
<md-list-item layout-wrap>
<md-button ng-class="JSONContent ? 'active' : ''" class="wz-button md-raised md-primary small" ng-click="getJSON('syslog_output')">{{ JSONContent ? "Close JSON viewer" : "Open JSON viewer" }}</md-button>
<md-button ng-class="XMLContent ? 'active' : ''" class="wz-button md-raised md-primary small" ng-click="getXML('syslog_output')">{{ XMLContent ? "Close XML viewer" : "Open XML viewer" }}</md-button>
</md-list-item>
</md-list>
</md-sidenav>
<!-- End right sidenav section -->
</div>
<!-- End main content and right sidenav section -->

View File

@ -1,5 +1,6 @@
include ./configuration.head
include ./welcome.html
include ./alerts/alerts.jade
include ./cluster/cluster.html
include ./database-output/database-output.html
include ./global-configuration/global-configuration.jade

View File

@ -65,13 +65,13 @@
</md-list-item>
<md-list-item flex="100" flex-gt-md="50" flex-gt-lg="33" class="md-2-line">
<div class="md-list-item-text">
<h3 class="wz-text-link" ng-click="switchConfigurationTab('commands-active-response')">Commands & Active response</h3>
<p>Pending description</p>
<h3 class="wz-text-link" ng-click="switchConfigurationTab('alerts')">Alerts</h3>
<p>Configure everything related to the alerts and their format</p>
</div>
</md-list-item>
<md-list-item flex="100" flex-gt-md="50" flex-gt-lg="33" class="md-2-line">
<div class="md-list-item-text">
<h3 class="wz-text-link" ng-click="switchConfigurationTab('alerts')">Alerts</h3>
<h3 class="wz-text-link" ng-click="switchConfigurationTab('commands-active-response')">Commands & Active response</h3>
<p>Pending description</p>
</div>
</md-list-item>