From 35355d0496088e738ddc2e0449cae3dad542598a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jes=C3=BAs=20=C3=81ngel=20Gonz=C3=A1lez?= Date: Fri, 23 Feb 2018 18:07:13 +0100 Subject: [PATCH 1/3] First approach --- .../wz-table-header/wz-table-header.html | 2 +- public/directives/wz-table/wz-table.html | 8 ++++---- public/less/agents.less | 2 +- public/less/angular-md.less | 14 ++++++++++---- public/less/buttons.less | 8 ++++++++ public/less/common.less | 10 +++++----- public/less/kbn.less | 6 +++--- public/less/main.less | 6 +++++- public/less/manager.less | 2 +- public/less/not-used.less | 6 ++++-- public/less/tables.less | 4 ++++ 11 files changed, 46 insertions(+), 22 deletions(-) diff --git a/public/directives/wz-table-header/wz-table-header.html b/public/directives/wz-table-header/wz-table-header.html index 759e05f82..529bb05a3 100644 --- a/public/directives/wz-table-header/wz-table-header.html +++ b/public/directives/wz-table-header/wz-table-header.html @@ -1,4 +1,4 @@ - +
{{key.name}}
{{parseItem(item,key) || '---'}} @@ -9,7 +9,7 @@
-
{{parseItem(item,key) || '---'}} @@ -21,7 +21,7 @@
{{parseItem(item,key) || '---'}} @@ -96,7 +96,7 @@
{{parseItem(decoder,key) || '---'}} diff --git a/public/less/agents.less b/public/less/agents.less index f500fdbe8..398d96845 100644 --- a/public/less/agents.less +++ b/public/less/agents.less @@ -3,7 +3,7 @@ } .agentsPreview .md-whiteframe-z1 { - box-shadow: none; + box-shadow: rgba(0, 0, 0, 0.2) 0px 0px 2px 0px, rgba(0, 0, 0, 0.137255) 0px 0px 0px 0px, rgba(0, 0, 0, 0.117647) 0px 0px 0px 0px; } .agents-groups-preview .md-button:not([disabled]):hover { diff --git a/public/less/angular-md.less b/public/less/angular-md.less index 38a68545e..d06562b1f 100644 --- a/public/less/angular-md.less +++ b/public/less/angular-md.less @@ -7,7 +7,7 @@ } md-card-content .ng-binding { - color: rgb(102, 102, 102); + color: black !important; } /* Fix text color from visualizations tooltips */ @@ -43,7 +43,7 @@ md-input-container>md-select { } span.md-headline { - color: #555; + color: black !important; font-size: 17px; } @@ -65,22 +65,28 @@ md-input-container>md-select { border-radius: 0px; } +md-autocomplete-wrap, md-input-container.md-whiteframe-z1.flex.md-input-has-value { - box-shadow: none; + box-shadow: rgba(0, 0, 0, 0.2) 0px 0px 2px 0px, rgba(0, 0, 0, 0.137255) 0px 0px 0px 0px, rgba(0, 0, 0, 0.117647) 0px 0px 0px 0px; background-color: white; } input#searchBox, md-autocomplete-wrap.md-whiteframe-z1.layout-row , md-input-container.md-whiteframe-z1.flex-20.md-input-has-value { - box-shadow: none; + box-shadow: rgba(0, 0, 0, 0.2) 0px 0px 2px 0px, rgba(0, 0, 0, 0.137255) 0px 0px 0px 0px, rgba(0, 0, 0, 0.117647) 0px 0px 0px 0px; + } md-input-container.md-whiteframe-z1.flex-20.md-input-has-value { + box-shadow: rgba(0, 0, 0, 0.2) 0px 0px 2px 0px, rgba(0, 0, 0, 0.137255) 0px 0px 0px 0px, rgba(0, 0, 0, 0.117647) 0px 0px 0px 0px; + background: white; } md-input-container.md-whiteframe-z1.flex-20 { + box-shadow: rgba(0, 0, 0, 0.2) 0px 0px 2px 0px, rgba(0, 0, 0, 0.137255) 0px 0px 0px 0px, rgba(0, 0, 0, 0.117647) 0px 0px 0px 0px; + background: white; } diff --git a/public/less/buttons.less b/public/less/buttons.less index 5d32909ed..5191917e4 100644 --- a/public/less/buttons.less +++ b/public/less/buttons.less @@ -43,3 +43,11 @@ margin-top: 20px; width: 180px; } + +.md-button:not([disabled]).md-raised:active, .md-button:not([disabled]).md-fab:active, +.md-button.md-raised:not([disabled]) { + box-shadow: none !important; +} +.tabView button._md-nav-button.md-accent.md-button.md-ink-ripple.md-active.md-primary { + background-color:white !important; +} \ No newline at end of file diff --git a/public/less/common.less b/public/less/common.less index 1d683d491..b867f8825 100644 --- a/public/less/common.less +++ b/public/less/common.less @@ -72,7 +72,7 @@ pre { position: relative; height: 25px; color: #666666; - background-color: #e4e4e4 !important; + background-color: #white !important; } /* Wazuh Header */ @@ -130,12 +130,12 @@ navbar { } .headBar { - background-color: #f7f7f7; + background-color: white !important; min-width: 463px; } .horizontalTabsBar { - background-color: #f7f7f7 + background-color: white !important; } .tabView md-nav-bar md-nav-ink-bar { @@ -168,7 +168,7 @@ navbar { /* Input filter box styles */ .input-filter-box { - box-shadow: rgba(0, 0, 0, 0.2) 0px 1px 3px 0px, rgba(0, 0, 0, 0.137255) 0px 1px 1px 0px, rgba(0, 0, 0, 0.117647) 0px 2px 1px -1px; + box-shadow: rgba(0, 0, 0, 0.2) 0px 0px 2px 0px, rgba(0, 0, 0, 0.137255) 0px 0px 0px 0px, rgba(0, 0, 0, 0.117647) 0px 0px 0px 0px; font-size: 14px; padding: 0px 15px; margin-top: 18px; @@ -262,7 +262,7 @@ md-progress-linear ._md-bar { } .background-e4 { - background-color: #e4e4e4; + background-color: white; } .background-e2 { diff --git a/public/less/kbn.less b/public/less/kbn.less index 5339cac26..024d8a83c 100644 --- a/public/less/kbn.less +++ b/public/less/kbn.less @@ -53,7 +53,7 @@ border-bottom } .kuiLocalNav { - background-color: #e4e4e4 !important; + background-color: white !important; } .kbn-vis-value td { @@ -122,7 +122,7 @@ border-bottom /* Filter bar */ .filter-bar { - background-color: #e4e4e4 !important; + background-color: white !important; } .chart { @@ -176,7 +176,7 @@ kbn-dis .euiText { .legacy-searchbar .typeahead { padding: 4px 10px 0 !important; - background-color: #e4e4e4 !important; + background-color: white !important; } diff --git a/public/less/main.less b/public/less/main.less index 6e50488ce..047189ca9 100644 --- a/public/less/main.less +++ b/public/less/main.less @@ -85,7 +85,11 @@ md-content._md.layout-row { } md-content { - background-color: #e4e4e4; + background-color: white !important; +} + +md-card { + box-shadow: rgba(0, 0, 0, 0.2) 0px 0px 2px 0px, rgba(0, 0, 0, 0.137255) 0px 0px 0px 0px, rgba(0, 0, 0, 0.117647) 0px 0px 0px 0px !important; } md-card md-card-content { diff --git a/public/less/manager.less b/public/less/manager.less index ddd3ab9c4..b5a59e3ce 100644 --- a/public/less/manager.less +++ b/public/less/manager.less @@ -8,7 +8,7 @@ } .manager-background { - background-color: #e4e4e4; + background-color: white; } .wazuh-chip { diff --git a/public/less/not-used.less b/public/less/not-used.less index 5a5ff7f91..c15638446 100644 --- a/public/less/not-used.less +++ b/public/less/not-used.less @@ -49,7 +49,7 @@ md-select-menu md-content md-option:not([disabled]):focus, md-select-menu.md-default-theme md-content md-option:not([disabled]):hover, md-select-menu md-content md-option:not([disabled]):hover { background-color: rgba(255, 255, 255, 0.1); - color: #555; + color: black !important; } md-select-menu:not(._md-overflow) md-content { @@ -58,7 +58,7 @@ md-select-menu:not(._md-overflow) md-content { } .manager-groups-left-panel { - background-color: #E4E4E4; + background-color: white; overflow: auto; height: 400px; box-shadow: 0 0px 0px rgba(10, 16, 20, .15), 0 0 0px rgba(10, 16, 20, .12) !important; @@ -69,6 +69,8 @@ md-select-menu:not(._md-overflow) md-content { .horizontal-menu-right .md-whiteframe-1dp, .horizontal-menu-right .md-whiteframe-z1 { + box-shadow: rgba(0, 0, 0, 0.2) 0px 0px 2px 0px, rgba(0, 0, 0, 0.137255) 0px 0px 0px 0px, rgba(0, 0, 0, 0.117647) 0px 0px 0px 0px; + box-shadow: none !important; } diff --git a/public/less/tables.less b/public/less/tables.less index 8bd08d25b..41afe7696 100644 --- a/public/less/tables.less +++ b/public/less/tables.less @@ -115,6 +115,10 @@ md-list-item { word-wrap: break-word !important; } +.wz-table-border { + box-shadow: rgba(0, 0, 0, 0.2) 0px 0px 2px 0px, rgba(0, 0, 0, 0.137255) 0px 0px 0px 0px, rgba(0, 0, 0, 0.117647) 0px 0px 0px 0px !important; +} + .padding-right-14 { padding-right: 14px !important; } From c8ffcb5b0fc6f3ad8adcc0fb4e6c2997d11bd734 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jes=C3=BAs=20=C3=81ngel=20Gonz=C3=A1lez?= Date: Mon, 26 Feb 2018 12:25:02 +0100 Subject: [PATCH 2/3] Second iteration new ui --- public/controllers/agents.js | 92 +++++- public/controllers/overview.js | 282 +++++++++++++++++- public/less/angular-md.less | 4 +- public/templates/agents/agents-audit.html | 22 +- public/templates/agents/agents-fim.html | 8 + public/templates/agents/agents-general.html | 116 +++---- public/templates/agents/agents-oscap.html | 16 +- public/templates/agents/agents-pci.html | 3 + public/templates/agents/agents-pm.html | 4 + .../templates/agents/agents-virustotal.html | 3 + public/templates/agents/agents-vuls.html | 3 + public/templates/agents/agents.head | 2 +- .../manager/ruleset/ruleset-decoders.html | 3 +- .../manager/ruleset/ruleset-rules.html | 4 + public/templates/overview/overview-audit.html | 30 +- public/templates/overview/overview-aws.html | 6 + public/templates/overview/overview-fim.html | 69 ++--- .../templates/overview/overview-general.html | 62 ++-- public/templates/overview/overview-oscap.html | 8 + public/templates/overview/overview-pci.html | 6 + public/templates/overview/overview-pm.html | 5 + .../overview/overview-virustotal.html | 5 + public/templates/overview/overview-vuls.html | 4 + public/templates/overview/overview.head | 2 +- 24 files changed, 559 insertions(+), 200 deletions(-) diff --git a/public/controllers/agents.js b/public/controllers/agents.js index 4ebffdb86..dc667f22f 100644 --- a/public/controllers/agents.js +++ b/public/controllers/agents.js @@ -26,6 +26,80 @@ function ($scope, $location, $q, $rootScope, appState, genericReq, apiReq, Agent $rootScope.currentImplicitFilter = ""; } + + // Metrics Audit + let watcher8, watcher9, watcher10, watcher11; + + $scope.auditNewFiles = ''; + $scope.auditReadFiles = ''; + $scope.auditModifiedFiles = ''; + $scope.auditRemovedFiles = ''; + + const assignWatcher8 = () => { + watcher8 = $scope.$watch(() => { + return $('#Wazuh-App-Agents-Audit-New-files-metric > visualize > visualization > div > div > div > div > div.metric-value.ng-binding > span').text(); + }, (newVal, oldVal) => { + if (newVal !== oldVal) { + $scope.auditNewFiles = newVal; + if (!$scope.$$phase) $scope.$digest(); + } + }); + } + const assignWatcher9 = () => { + watcher9 = $scope.$watch(() => { + return $('#Wazuh-App-Agents-Audit-Read-files-metric > visualize > visualization > div > div > div > div > div.metric-value.ng-binding > span').text(); + }, (newVal, oldVal) => { + if (newVal !== oldVal) { + $scope.auditReadFiles = newVal; + if (!$scope.$$phase) $scope.$digest(); + } + }); + } + + const assignWatcher10 = () => { + watcher10 = $scope.$watch(() => { + return $('#Wazuh-App-Agents-Audit-Modified-files-metric > visualize > visualization > div > div > div > div > div.metric-value.ng-binding > span').text(); + }, (newVal, oldVal) => { + if (newVal !== oldVal) { + $scope.auditModifiedFiles = newVal; + if (!$scope.$$phase) $scope.$digest(); + } + }); + } + + const assignWatcher11 = () => { + watcher11 = $scope.$watch(() => { + return $('#Wazuh-App-Agents-Audit-Removed-files-metric > visualize > visualization > div > div > div > div > div.metric-value.ng-binding > span').text(); + }, (newVal, oldVal) => { + if (newVal !== oldVal) { + $scope.auditRemovedFiles = newVal; + if (!$scope.$$phase) $scope.$digest(); + } + }); + } + + const assignAuditMetrics = () => { + assignWatcher8(); + assignWatcher9(); + assignWatcher10(); + assignWatcher11(); + } + + const destroyAuditMetrics = () => { + watcher8(); + watcher9(); + watcher10(); + watcher11(); + watcher8 = null; + watcher9 = null; + watcher10 = null; + watcher11 = null; + } + + if ($scope.tab === 'audit' && $scope.tabView === 'panels' && !watcher8) { + assignAuditMetrics(); + } + $rootScope.tabVisualizations = { general : 7, fim : 8, @@ -51,11 +125,24 @@ function ($scope, $location, $q, $rootScope, appState, genericReq, apiReq, Agent }; // Switch subtab - $scope.switchSubtab = subtab => $scope.tabView = subtab; - + $scope.switchSubtab = subtab => { + $scope.tabView = subtab; + if($scope.tab === 'audit' && subtab === 'panels' && !watcher8){ + assignAuditMetrics(); + } else if(watcher8) { + destroyAuditMetrics(); + } + } $scope.switchTab = tab => { if($scope.tab === tab) return; + + if(tab === 'audit' && $scope.tabView === 'panels' && !watcher8){ + assignAuditMetrics(); + } else if(watcher8) { + destroyAuditMetrics(); + } + if($rootScope.ownHandlers){ for(let h of $rootScope.ownHandlers){ h._scope.$destroy(); @@ -233,6 +320,7 @@ function ($scope, $location, $q, $rootScope, appState, genericReq, apiReq, Agent h._scope.$destroy(); } } + if(watcher8) destroyAuditMetrics(); $rootScope.ownHandlers = []; }); diff --git a/public/controllers/overview.js b/public/controllers/overview.js index 90c6d6d78..ce0e8a80c 100644 --- a/public/controllers/overview.js +++ b/public/controllers/overview.js @@ -1,9 +1,152 @@ -let app = require('ui/modules').get('app/wazuh', []); +const app = require('ui/modules').get('app/wazuh', []); +import $ from 'jquery'; +// app.controller('overviewController', function ($scope, $location, $rootScope, appState, genericReq, errorHandler) { $rootScope.page = 'overview'; $scope.extensions = appState.getExtensions().extensions; + // Metrics General + let watcher1, watcher2, watcher3, watcher4; + + $scope.totalAlerts = ''; + $scope.level12 = ''; + $scope.authFailure = ''; + $scope.authSuccess = ''; + const assignWatcher1 = () => { + watcher1 = $scope.$watch(() => { + return $('#Wazuh-App-Overview-General-Metric-alerts > visualize > visualization > div > div > div > div > div.metric-value.ng-binding > span').text(); + }, (newVal, oldVal) => { + if (newVal !== oldVal) { + $scope.totalAlerts = newVal; + if (!$scope.$$phase) $scope.$digest(); + } + }); + } + const assignWatcher2 = () => { + watcher2 = $scope.$watch(() => { + return $('#Wazuh-App-Overview-General-Level-12-alerts > visualize > visualization > div > div > div > div > div.metric-value.ng-binding > span').text(); + }, (newVal, oldVal) => { + if (newVal !== oldVal) { + $scope.level12 = newVal; + if (!$scope.$$phase) $scope.$digest(); + } + }); + } + + const assignWatcher3 = () => { + watcher3 = $scope.$watch(() => { + return $('#Wazuh-App-Overview-General-Authentication-failure > visualize > visualization > div > div > div > div > div.metric-value.ng-binding > span').text(); + }, (newVal, oldVal) => { + if (newVal !== oldVal) { + $scope.authFailure = newVal; + if (!$scope.$$phase) $scope.$digest(); + } + }); + } + + const assignWatcher4 = () => { + watcher4 = $scope.$watch(() => { + return $('#Wazuh-App-Overview-General-Authentication-success > visualize > visualization > div > div > div > div > div.metric-value.ng-binding > span').text(); + }, (newVal, oldVal) => { + if (newVal !== oldVal) { + $scope.authSuccess = newVal; + if (!$scope.$$phase) $scope.$digest(); + } + }); + } + + // Metrics FIM + let watcher5, watcher6, watcher7; + + $scope.fimAdded = ''; + $scope.fimModified = ''; + $scope.fimDeleted = ''; + + const assignWatcher5 = () => { + watcher5 = $scope.$watch(() => { + return $('#Wazuh-App-Overview-FIM-Added > visualize > visualization > div > div > div > div > div.metric-value.ng-binding > span').text(); + }, (newVal, oldVal) => { + if (newVal !== oldVal) { + $scope.fimAdded = newVal; + if (!$scope.$$phase) $scope.$digest(); + } + }); + } + const assignWatcher6 = () => { + watcher6 = $scope.$watch(() => { + return $('#Wazuh-App-Overview-FIM-Modified > visualize > visualization > div > div > div > div > div.metric-value.ng-binding > span').text(); + }, (newVal, oldVal) => { + if (newVal !== oldVal) { + $scope.fimModified = newVal; + if (!$scope.$$phase) $scope.$digest(); + } + }); + } + + const assignWatcher7 = () => { + watcher7 = $scope.$watch(() => { + return $('#Wazuh-App-Overview-FIM-Deleted > visualize > visualization > div > div > div > div > div.metric-value.ng-binding > span').text(); + }, (newVal, oldVal) => { + if (newVal !== oldVal) { + $scope.fimDeleted = newVal; + if (!$scope.$$phase) $scope.$digest(); + } + }); + } + + // Metrics Audit + let watcher8, watcher9, watcher10, watcher11; + + $scope.auditNewFiles = ''; + $scope.auditReadFiles = ''; + $scope.auditModifiedFiles = ''; + $scope.auditRemovedFiles = ''; + + const assignWatcher8 = () => { + watcher8 = $scope.$watch(() => { + return $('#Wazuh-App-Overview-Audit-New-files > visualize > visualization > div > div > div > div > div.metric-value.ng-binding > span').text(); + }, (newVal, oldVal) => { + if (newVal !== oldVal) { + $scope.auditNewFiles = newVal; + if (!$scope.$$phase) $scope.$digest(); + } + }); + } + const assignWatcher9 = () => { + watcher9 = $scope.$watch(() => { + return $('#Wazuh-App-Overview-Audit-Read-files > visualize > visualization > div > div > div > div > div.metric-value.ng-binding > span').text(); + }, (newVal, oldVal) => { + if (newVal !== oldVal) { + $scope.auditReadFiles = newVal; + if (!$scope.$$phase) $scope.$digest(); + } + }); + } + + const assignWatcher10 = () => { + watcher10 = $scope.$watch(() => { + return $('#Wazuh-App-Overview-Audit-Modified-files > visualize > visualization > div > div > div > div > div.metric-value.ng-binding > span').text(); + }, (newVal, oldVal) => { + if (newVal !== oldVal) { + $scope.auditModifiedFiles = newVal; + if (!$scope.$$phase) $scope.$digest(); + } + }); + } + + const assignWatcher11 = () => { + watcher11 = $scope.$watch(() => { + return $('#Wazuh-App-Overview-Audit-Removed-files > visualize > visualization > div > div > div > div > div.metric-value.ng-binding > span').text(); + }, (newVal, oldVal) => { + if (newVal !== oldVal) { + $scope.auditRemovedFiles = newVal; + if (!$scope.$$phase) $scope.$digest(); + } + }); + } + + // Check the url hash and retrieve the tabView information if ($location.search().tabView) { $scope.tabView = $location.search().tabView; @@ -25,12 +168,12 @@ app.controller('overviewController', function ($scope, $location, $rootScope, ap // This object represents the number of visualizations per tab; used to show a progress bar $rootScope.tabVisualizations = { - general : 15, - fim : 17, + general : 11, + fim : 10, pm : 5, vuls : 8, oscap : 14, - audit : 16, + audit : 15, pci : 6, aws : 10, virustotal: 7 @@ -49,15 +192,117 @@ app.controller('overviewController', function ($scope, $location, $rootScope, ap virustotal: { group: 'virustotal' } }; - // Switch subtab - $scope.switchSubtab = subtab => $scope.tabView = subtab; + const assignOverviewMetrics = () => { + assignWatcher1(); + assignWatcher2(); + assignWatcher3(); + assignWatcher4(); + } + const destroyOverviewMetrics = () => { + watcher1(); + watcher2(); + watcher3(); + watcher4(); + watcher1 = null; + watcher2 = null; + watcher3 = null; + watcher4 = null; + } + const assignFimMetrics = () => { + assignWatcher5(); + assignWatcher6(); + assignWatcher7(); + } + + const destroyFimMetrics = () => { + watcher5(); + watcher6(); + watcher7(); + watcher5 = null; + watcher6 = null; + watcher7 = null; + } + + const assignAuditMetrics = () => { + assignWatcher8(); + assignWatcher9(); + assignWatcher10(); + assignWatcher11(); + } + + const destroyAuditMetrics = () => { + watcher8(); + watcher9(); + watcher10(); + watcher11(); + watcher8 = null; + watcher9 = null; + watcher10 = null; + watcher11 = null; + } + + if ($scope.tab === 'general' && $scope.tabView === 'panels' && !watcher1) { + assignOverviewMetrics(); + } + + if ($scope.tab === 'fim' && $scope.tabView === 'panels' && !watcher5) { + assignOverviewMetrics(); + } + + if ($scope.tab === 'audit' && $scope.tabView === 'panels' && !watcher8) { + assignAuditMetrics(); + } + + // Switch subtab + $scope.switchSubtab = subtab => { + $scope.tabView = subtab; + + if($scope.tab === 'general' && subtab === 'panels' && !watcher1){ + assignOverviewMetrics(); + } else if(watcher1) { + destroyOverviewMetrics(); + } + + if($scope.tab === 'fim' && subtab === 'panels' && !watcher5){ + assignFimMetrics(); + } else if(watcher5) { + destroyFimMetrics(); + } + + if($scope.tab === 'audit' && subtab === 'panels' && !watcher8){ + assignAuditMetrics(); + } else if(watcher8) { + destroyAuditMetrics(); + } + + } // Switch tab $scope.switchTab = tab => { - if($scope.tab === tab) return; + if ($scope.tab === tab) return; - for(let h of $rootScope.ownHandlers){ - h._scope.$destroy(); + if(tab === 'general' && $scope.tabView === 'panels' && !watcher1){ + assignOverviewMetrics(); + } else if(watcher1) { + destroyOverviewMetrics(); + } + + if(tab === 'fim' && $scope.tabView === 'panels' && !watcher5){ + assignFimMetrics(); + } else if(watcher1) { + destroyFimMetrics(); + } + + if(tab === 'audit' && $scope.tabView === 'panels' && !watcher8){ + assignAuditMetrics(); + } else if(watcher8) { + destroyAuditMetrics(); + } + + if ($rootScope.ownHandlers) { + for (let h of $rootScope.ownHandlers) { + h._scope.$destroy(); + } } $rootScope.ownHandlers = []; @@ -79,12 +324,15 @@ app.controller('overviewController', function ($scope, $location, $rootScope, ap else $rootScope.currentImplicitFilter = tabFilters[$scope.tab].group; }); - $scope.$on('$destroy',() => { - if($rootScope.ownHandlers){ - for(let h of $rootScope.ownHandlers){ + $scope.$on('$destroy', () => { + if ($rootScope.ownHandlers) { + for (let h of $rootScope.ownHandlers) { h._scope.$destroy(); } } + if(watcher1) destroyOverviewMetrics(); + if(watcher5) destroyFimMetrics(); + if(watcher8) destroyAuditMetrics(); $rootScope.ownHandlers = []; }); @@ -93,18 +341,20 @@ app.controller('overviewController', function ($scope, $location, $rootScope, ap genericReq .request('GET', '/api/wazuh-api/pci/all') .then(data => { - for(let key in data.data){ + for (let key in data.data) { tabs.push({ - "title": key, + "title": key, "content": data.data[key] }); } }) .catch(error => { - errorHandler.handle(error,'Overview'); - if(!$rootScope.$$phase) $rootScope.$digest(); + errorHandler.handle(error, 'Overview'); + if (!$rootScope.$$phase) $rootScope.$digest(); }); $scope.tabs = tabs; $scope.selectedIndex = 0; + + }); diff --git a/public/less/angular-md.less b/public/less/angular-md.less index d06562b1f..a45f31f92 100644 --- a/public/less/angular-md.less +++ b/public/less/angular-md.less @@ -43,7 +43,7 @@ md-input-container>md-select { } span.md-headline { - color: black !important; + color:#0079a5 !important; font-size: 17px; } @@ -112,7 +112,7 @@ md-input-container ._md-placeholder { /* Overriding the colour for the navbar */ .md-button.md-accent { - color: rgb(0,121,165); + color: black; } md-nav-bar md-nav-ink-bar { diff --git a/public/templates/agents/agents-audit.html b/public/templates/agents/agents-audit.html index c7a903c8d..37f3b5afe 100644 --- a/public/templates/agents/agents-audit.html +++ b/public/templates/agents/agents-audit.html @@ -2,7 +2,17 @@
-
+
+ + + New files: {{auditNewFiles}} + Read files: {{auditReadFiles}} + Modified files: {{auditModifiedFiles}} + Removed files: {{auditRemovedFiles}} + + +
+