mirror of
https://github.com/valitydev/wazuh-kibana-app.git
synced 2024-11-08 02:38:51 +00:00
4045278ca4
This commit reorders all the CSS from the app, removing the hard-coded one from the templates, and making a first approach of reordering in the `less` folder.
205 lines
13 KiB
HTML
205 lines
13 KiB
HTML
<div flex ng-if="!loading && globalRuleSet == 'ruleset' && globalsubmenuNavItem2 == 'rules'" ng-controller="rulesController"
|
|
layout="column" id="rulesContainer" layout-padding layout-align="start space-around">
|
|
|
|
<div class='uil-ring-css' ng-show="loading">
|
|
<div></div>
|
|
</div>
|
|
|
|
<div ng-show="!loading" layout="row" layout-align="start stretch" layout-align="center start" class="manager-ruleset-rules-top-row">
|
|
<md-card flex>
|
|
<md-card-content class="wazuh-column">
|
|
<span class="md-headline-small">Top 24h - Rule ID</span>
|
|
<kbn-vis vis-id="'Wazuh-App-Manager-Ruleset-Rules-Top-24h-Rule-ID'" id="Wazuh-App-Manager-Ruleset-Rules-Top-24h-Rule-ID"></kbn-vis>
|
|
</md-card-content>
|
|
</md-card>
|
|
<md-card flex>
|
|
<md-card-content class="wazuh-column">
|
|
<span class="md-headline-small">Top 24h - Groups</span>
|
|
<kbn-vis vis-id="'Wazuh-App-Manager-Ruleset-Rules-Top-24h-Groups'" id="Wazuh-App-Manager-Ruleset-Rules-Top-24h-Groups"></kbn-vis>
|
|
</md-card-content>
|
|
</md-card>
|
|
<md-card flex>
|
|
<md-card-content class="wazuh-column">
|
|
<span class="md-headline-small">Top 24h - PCI DSS requirements</span>
|
|
<kbn-vis vis-id="'Wazuh-App-Manager-Ruleset-Rules-Top-24h-PCI-DSS-requirements'" id="Wazuh-App-Manager-Ruleset-Rules-Top-24h-PCI-DSS-requirements"></kbn-vis>
|
|
</md-card-content>
|
|
</md-card>
|
|
<md-card flex>
|
|
<md-card-content class="wazuh-column">
|
|
<span class="md-headline-small">Top 24h - Level</span>
|
|
<kbn-vis vis-id="'Wazuh-App-Manager-Ruleset-Rules-Top-24h-Level'" id="Wazuh-App-Manager-Ruleset-Rules-Top-24h-Level"></kbn-vis>
|
|
</md-card-content>
|
|
</md-card>
|
|
</div>
|
|
|
|
<div ng-show="!loading" flex layout="column">
|
|
<div id="content" layout="row" layout-align="start start" class="manager-ruleset-rules-button-bar">
|
|
<span layout="row" class="manager-ruleset-rules-button-bar-span" flex layout-align="space-between center">
|
|
<md-autocomplete flex md-select-on-match="true" md-no-cache="true" md-selected-item="filter" md-selected-item-change="rules.addFilter(filter.type, filter.name)"
|
|
md-search-text="searchTerm" md-items="rule in autoComplete | filter : searchTerm" md-item-text="rule.name" md-min-length="0"
|
|
md-no-asterisk="false" md-menu-class="autocomplete-custom-agents-bar" md-search-text-change="analizeRules(searchTerm)"
|
|
placeholder="Search for rule file, group or PCI requirement">
|
|
<md-item-template>
|
|
<span class="item-title">
|
|
<strong md-highlight-text="search" md-highlight-flags="i"> {{rule.name}} </strong>
|
|
</span>
|
|
<span class="item-metadata">
|
|
<span class="item-metastat" ng-if="rule.type != 'pci'"> {{rule.type}} </span>
|
|
<span class="item-metastat" ng-if="rule.type == 'pci'">PCI control</span>
|
|
</span>
|
|
</md-item-template>
|
|
<md-not-found>
|
|
No results matching "{{searchTerm}}" were found.
|
|
</md-not-found>
|
|
</md-autocomplete>
|
|
</span>
|
|
|
|
<md-button flex="10" ng-class="(globalsubmenuNavItem2 == 'rules') ? 'button-active' : 'buttonBlueLightRuleset'"
|
|
ng-click="setRulesTab('rules')" class="md-primary manager-ruleset-rules-rulbtn">
|
|
Rules
|
|
</md-button>
|
|
<md-button flex="10" ng-class="(globalsubmenuNavItem2 == 'decoders') ? 'button-active' : 'buttonBlueLightRuleset'"
|
|
ng-click="setRulesTab('decoders')" class="md-primary manager-ruleset-rules-decbtn">
|
|
Decoders
|
|
</md-button>
|
|
</div>
|
|
|
|
<md-chips readonly="true" ng-show="rules.hasFilter('search') || rules.hasFilter('file') || rules.hasFilter('group') || rules.hasFilter('pci')">
|
|
<md-chip class="wazuh-chip" ng-click="rules.removeFilter('search', true)" ng-if="rules.hasFilter('search')">
|
|
<span class="bold">Search: {{rules.getFilter('search')}}
|
|
<i class="fa fa-times" aria-hidden="true"></i>
|
|
</span>
|
|
</md-chip>
|
|
<md-chip class="wazuh-chip" ng-click="rules.removeFilter('file', true)" ng-if="rules.hasFilter('file')">
|
|
<span class="bold">File: {{rules.getFilter('file')}}
|
|
<i class="fa fa-times" aria-hidden="true"></i>
|
|
</span>
|
|
</md-chip>
|
|
<md-chip class="wazuh-chip" ng-click="rules.removeFilter('group', true)" ng-if="rules.hasFilter('group')">
|
|
<span class="bold">Group: {{rules.getFilter('group')}}
|
|
<i class="fa fa-times" aria-hidden="true"></i>
|
|
</span>
|
|
</md-chip>
|
|
<md-chip class="wazuh-chip" ng-click="rules.removeFilter('pci', true)" ng-if="rules.hasFilter('pci')">
|
|
<span>PCI control: {{rules.getFilter('pci')}}
|
|
<i class="fa fa-times" aria-hidden="true"></i>
|
|
</span>
|
|
</md-chip>
|
|
</md-chips>
|
|
|
|
<md-toolbar layout="row" class="md-toolbar-tools manager-ruleset-rules-mdtoolbar">
|
|
<span flex="5" ng-click="rules.sort('id')">ID
|
|
<i class="fa" ng-class="rules.sortValue === 'id' ? (rules.sortDir ? 'fa-sort-asc' : 'fa-sort-desc') : 'fa-sort'" aria-hidden="true"></i>
|
|
</span>
|
|
<span flex="15" ng-click="rules.sort('file')">File
|
|
<i class="fa" ng-class="rules.sortValue === 'file' ? (rules.sortDir ? 'fa-sort-asc' : 'fa-sort-desc') : 'fa-sort'" aria-hidden="true"></i>
|
|
</span>
|
|
<span flex="35" ng-click="rules.sort('description')">Description
|
|
<i class="fa" ng-class="rules.sortValue === 'description' ? (rules.sortDir ? 'fa-sort-asc' : 'fa-sort-desc') : 'fa-sort'"
|
|
aria-hidden="true"></i>
|
|
</span>
|
|
<span flex="25">Groups</span>
|
|
<span flex="15">Requirement</span>
|
|
<span flex="5" ng-click="rules.sort('level')">Level
|
|
<i class="fa" ng-class="rules.sortValue === 'level' ? (rules.sortDir ? 'fa-sort-asc' : 'fa-sort-desc') : 'fa-sort'" aria-hidden="true"></i>
|
|
</span>
|
|
</md-toolbar>
|
|
|
|
<md-content flex layout="column" class="manager-ruleset-rules-col-300" when-scrolled="decoders.nextPage('')">
|
|
<md-list ng-repeat='rule in rules.items | orderBy : rules.sortValue : rules.sortDir' ng-class-odd="'odd'" ng-class-even="'even'"
|
|
class="agents-preview-table" ng-class="showDetails[rule.id] ? 'ruleset_rules_row_active' : ''">
|
|
<md-list-item class="rules-item-list" ng-click="showDetails[rule.id] = !showDetails[rule.id]" ng-class="showDetails[rule.id] ? 'ruleset_rules_row_active' : ''">
|
|
<span flex="5">{{rule.id}}</span>
|
|
<span flex="15">{{rule.file}}</span>
|
|
<span flex="35">{{rule.description}}</span>
|
|
<span flex="25">
|
|
<span ng-repeat="group in rule.groups">{{ group }}
|
|
<span ng-if="!$last">, </span>
|
|
</span>
|
|
</span>
|
|
<span flex="15">
|
|
<span ng-repeat="pci in rule.pci">{{ pci }}
|
|
<span ng-if="!$last">, </span>
|
|
</span>
|
|
</span>
|
|
<span flex="5">{{rule.level}}</span>
|
|
</md-list-item>
|
|
|
|
<div class="ruleset_card_info manager-ruleset-rules-card-info" layout="column" flex layout-align="start stretch" ng-show="showDetails[rule.id]">
|
|
<md-content flex>
|
|
<div class="ruleset_card_info manager-ruleset-rules-card-info-padding" layout="row" flex layout-align="center start" ng-show="showDetails[rule.id]">
|
|
<md-card flex="10">
|
|
<md-card-content class="manager-ruleset-rules-center">
|
|
<div class="ng-binding manager-ruleset-rules-bold">ID</div>
|
|
<div class="metric-value ng-binding manager-ruleset-rules-f12">{{rule.id}}</div>
|
|
</md-card-content>
|
|
</md-card>
|
|
<md-card flex>
|
|
<md-card-content class="manager-ruleset-rules-center">
|
|
<div class="ng-binding manager-ruleset-rules-bold">Description</div>
|
|
<div class="metric-value ng-binding manager-ruleset-rules-f12">{{rule.description}}</div>
|
|
</md-card-content>
|
|
</md-card>
|
|
<md-card flex="10">
|
|
<md-card-content class="manager-ruleset-rules-center">
|
|
<div class="ng-binding manager-ruleset-rules-bold">Level</div>
|
|
<div class="metric-value ng-binding manager-ruleset-rules-f12">{{rule.level}}</div>
|
|
</md-card-content>
|
|
</md-card>
|
|
<md-card class="cardHover" ng-click="rules.addFilter('file', rule.file); $event.stopPropagation();" flex="20">
|
|
<md-card-content class="manager-ruleset-rules-center">
|
|
<div class="ng-binding manager-ruleset-rules-bold">File</div>
|
|
<div class="metric-value ng-binding manager-ruleset-rules-f12">{{rule.file}}</div>
|
|
</md-card-content>
|
|
</md-card>
|
|
</div>
|
|
|
|
<div class="ruleset_card_info manager-ruleset-rules-card-info-padding" layout="row" flex layout-align="space-between stretch" ng-show="showDetails[rule.id]">
|
|
<md-card flex ng-if="rule.groups.length > 0">
|
|
<md-card-content>
|
|
<h3 class="wazuh-h3">Groups</h3>
|
|
<span ng-repeat="group in rule.groups">
|
|
<span class="listHover" ng-click="rules.addFilter('group', group)" layout="row" layout-align="space-between center">
|
|
<p>{{ group }}</p>
|
|
</span>
|
|
<md-divider ng-if="!$last"></md-divider>
|
|
</span>
|
|
</md-card-content>
|
|
</md-card>
|
|
|
|
<md-card flex ng-if="rule.pci.length > 0">
|
|
<md-card-content>
|
|
<h3 class="wazuh-h3">PCI DSS </h3>
|
|
<span ng-repeat="pci in rule.pci">
|
|
<span class="listHover" ng-click="rules.addFilter('pci', pci)" layout="row" layout-align="space-between center">
|
|
<p>{{ pci }}</p>
|
|
</span>
|
|
<md-divider ng-if="!$last"></md-divider>
|
|
</span>
|
|
</md-card-content>
|
|
</md-card>
|
|
|
|
<md-card flex>
|
|
<md-card-content>
|
|
<h3 class="wazuh-h3">Extra settings</h3>
|
|
<span ng-repeat="(detailk, detailv) in rule.details">
|
|
<span layout="row" layout-align="space-between center">
|
|
<p>{{detailk}}</p>
|
|
<p class="right-text">{{detailv}}</p>
|
|
</span>
|
|
<md-divider ng-if="!$last"></md-divider>
|
|
</span>
|
|
</md-card-content>
|
|
</md-card>
|
|
</div>
|
|
</md-content>
|
|
</div>
|
|
</md-list>
|
|
</md-content>
|
|
<md-divider></md-divider>
|
|
<md-content>
|
|
<md-progress-linear class="md-accent" md-mode="indeterminate" ng-show="rules.busy"></md-progress-linear>
|
|
</md-content>
|
|
</div>
|
|
</div>
|