diff --git a/public/kibana-integrations/kibana-visualization.js b/public/kibana-integrations/kibana-visualization.js index 60c3ee2bc..44e7834ac 100644 --- a/public/kibana-integrations/kibana-visualization.js +++ b/public/kibana-integrations/kibana-visualization.js @@ -221,7 +221,9 @@ app.directive('kbnVis', function() { }); const renderComplete = () => { + console.log(typeof $scope.visID) if(!$scope.visID.toLowerCase().includes(tabVisualizations.getTab())){ + console.log(`Destroying ${$scope.visID.toLowerCase()}, tab: ${tabVisualizations.getTab()}`) destroyAll(); return; } diff --git a/public/templates/agents/agents-general.html b/public/templates/agents/agents-general.html index e342fc9d2..de54c7ddd 100644 --- a/public/templates/agents/agents-general.html +++ b/public/templates/agents/agents-general.html @@ -29,7 +29,7 @@ - + @@ -41,7 +41,7 @@ - + @@ -57,7 +57,7 @@ - + @@ -70,7 +70,7 @@ - + @@ -83,7 +83,7 @@ - + @@ -98,7 +98,7 @@ - + @@ -110,7 +110,7 @@ - + diff --git a/public/templates/agents/agents-vuls.html b/public/templates/agents/agents-vuls.html index ab4562c04..63d97830e 100644 --- a/public/templates/agents/agents-vuls.html +++ b/public/templates/agents/agents-vuls.html @@ -13,10 +13,10 @@
- - - - + + + +
@@ -29,7 +29,7 @@ - + @@ -41,7 +41,7 @@ - +
@@ -55,7 +55,7 @@ - + @@ -67,7 +67,7 @@ - + @@ -79,7 +79,7 @@ - + @@ -94,7 +94,7 @@ - + diff --git a/public/templates/overview/overview-vuls.html b/public/templates/overview/overview-vuls.html index e788b33df..79427f7c1 100644 --- a/public/templates/overview/overview-vuls.html +++ b/public/templates/overview/overview-vuls.html @@ -13,10 +13,10 @@
- - - - + + + +
@@ -29,7 +29,7 @@ - + @@ -41,7 +41,7 @@ - +
@@ -56,7 +56,7 @@ - + @@ -68,7 +68,7 @@ - + @@ -80,7 +80,7 @@ - + @@ -92,7 +92,7 @@ - + @@ -106,7 +106,7 @@ - + diff --git a/public/utils/agents-metrics.js b/public/utils/agents-metrics.js index 289e0a6b7..10228c97f 100644 --- a/public/utils/agents-metrics.js +++ b/public/utils/agents-metrics.js @@ -31,12 +31,12 @@ const metricsAudit = { // Metrics Vulnerability Detector const metricsVulnerability = { vulnCritical: - '[vis-id="\'Wazuh-App-Agents-vulnerability-Metric-Critical-severity\'"]', + '[vis-id="\'Wazuh-App-Agents-vuls-Metric-Critical-severity\'"]', vulnHigh: - '[vis-id="\'Wazuh-App-Agents-vulnerability-Metric-High-severity\'"]', + '[vis-id="\'Wazuh-App-Agents-vuls-Metric-High-severity\'"]', vulnMedium: - '[vis-id="\'Wazuh-App-Agents-vulnerability-Metric-Medium-severity\'"]', - vulnLow: '[vis-id="\'Wazuh-App-Agents-vulnerability-Metric-Low-severity\'"]' + '[vis-id="\'Wazuh-App-Agents-vuls-Metric-Medium-severity\'"]', + vulnLow: '[vis-id="\'Wazuh-App-Agents-vuls-Metric-Low-severity\'"]' }; // Metrics Scap diff --git a/public/utils/overview-metrics.js b/public/utils/overview-metrics.js index 06aacb4dc..1a8810bd6 100644 --- a/public/utils/overview-metrics.js +++ b/public/utils/overview-metrics.js @@ -23,12 +23,12 @@ const metricsGeneral = { // Metrics Vulnerability Detector const metricsVulnerability = { vulnCritical: - '[vis-id="\'Wazuh-App-Overview-vulnerability-Metric-Critical-severity\'"]', + '[vis-id="\'Wazuh-App-Overview-vuls-Metric-Critical-severity\'"]', vulnHigh: - '[vis-id="\'Wazuh-App-Overview-vulnerability-Metric-High-severity\'"]', + '[vis-id="\'Wazuh-App-Overview-vuls-Metric-High-severity\'"]', vulnMedium: - '[vis-id="\'Wazuh-App-Overview-vulnerability-Metric-Medium-severity\'"]', - vulnLow: '[vis-id="\'Wazuh-App-Overview-vulnerability-Metric-Low-severity\'"]' + '[vis-id="\'Wazuh-App-Overview-vuls-Metric-Medium-severity\'"]', + vulnLow: '[vis-id="\'Wazuh-App-Overview-vuls-Metric-Low-severity\'"]' }; // Metrics Scap diff --git a/server/initialize.js b/server/initialize.js index 6710d7d6f..e9ee84e5e 100644 --- a/server/initialize.js +++ b/server/initialize.js @@ -261,7 +261,7 @@ export function Initialize(server) { source.lastRestart = currentDate; // If this function fails, it throws an exception - fs.writeFileSync(wazuhVersion, JSON.stringify(source), 'utf-8'); + //fs.writeFileSync(wazuhVersion, JSON.stringify(source), 'utf-8'); } } catch (error) { return Promise.reject(error); diff --git a/server/integration-files/visualizations/agents/agents-general.js b/server/integration-files/visualizations/agents/agents-general.js index 6935f1c22..16c9e74fa 100644 --- a/server/integration-files/visualizations/agents/agents-general.js +++ b/server/integration-files/visualizations/agents/agents-general.js @@ -11,7 +11,7 @@ */ export default [ { - _id: 'Wazuh-App-Agents-Overview-Top-5-alerts', + _id: 'Wazuh-App-Agents-General-Top-5-alerts', _source: { title: 'Top 5 alerts', visState: @@ -188,7 +188,7 @@ export default [ _type: 'visualization' }, { - _id: 'Wazuh-App-Agents-Overview-Top-10-groups', + _id: 'Wazuh-App-Agents-General-Top-10-groups', _source: { title: 'Top 5 rule groups', visState: @@ -204,7 +204,7 @@ export default [ _type: 'visualization' }, { - _id: 'Wazuh-App-Agents-Overview-Top-5-PCI-DSS-Requirements', + _id: 'Wazuh-App-Agents-General-Top-5-PCI-DSS-Requirements', _source: { title: 'Top 5 PCI DSS requirements', visState: @@ -220,7 +220,7 @@ export default [ _type: 'visualization' }, { - _id: 'Wazuh-App-Agents-Overview-Alert-groups-evolution', + _id: 'Wazuh-App-Agents-General-Alert-groups-evolution', _source: { title: 'Alert groups evolution', visState: @@ -236,7 +236,7 @@ export default [ _type: 'visualization' }, { - _id: 'Wazuh-App-Agents-Overview-Alerts', + _id: 'Wazuh-App-Agents-General-Alerts', _source: { title: 'Alerts', visState: @@ -252,7 +252,7 @@ export default [ _type: 'visualization' }, { - _id: 'Wazuh-App-Agents-Overview-Alerts-summary', + _id: 'Wazuh-App-Agents-General-Alerts-summary', _type: 'visualization', _source: { title: 'Alerts summary', @@ -269,7 +269,7 @@ export default [ } }, { - _id: 'Wazuh-App-Agents-Overview-Groups-summary', + _id: 'Wazuh-App-Agents-General-Groups-summary', _type: 'visualization', _source: { title: 'Groups summary', diff --git a/server/integration-files/visualizations/agents/agents-vuls.js b/server/integration-files/visualizations/agents/agents-vuls.js index cea4bd737..3cf722b6b 100644 --- a/server/integration-files/visualizations/agents/agents-vuls.js +++ b/server/integration-files/visualizations/agents/agents-vuls.js @@ -11,7 +11,7 @@ */ export default [ { - _id: 'Wazuh-App-Agents-vulnerability-Alerts-severity-over-time', + _id: 'Wazuh-App-Agents-vuls-Alerts-severity-over-time', _type: 'visualization', _source: { title: 'Alerts severity over time', @@ -27,7 +27,7 @@ export default [ } }, { - _id: 'Wazuh-App-Agents-vulnerability-Alert-summary', + _id: 'Wazuh-App-Agents-vuls-Alert-summary', _type: 'visualization', _source: { title: 'Alerts summary', @@ -44,7 +44,7 @@ export default [ } }, { - _id: 'Wazuh-App-Agents-vulnerability-Commonly-affected-packages', + _id: 'Wazuh-App-Agents-vuls-Commonly-affected-packages', _type: 'visualization', _source: { title: 'Top 5 affected packages', @@ -60,7 +60,7 @@ export default [ } }, { - _id: 'Wazuh-App-Agents-vulnerability-Metric-Critical-severity', + _id: 'Wazuh-App-Agents-vuls-Metric-Critical-severity', _type: 'visualization', _source: { title: 'Metric Critical severity', @@ -106,7 +106,7 @@ export default [ } }, { - _id: 'Wazuh-App-Agents-vulnerability-Metric-High-severity', + _id: 'Wazuh-App-Agents-vuls-Metric-High-severity', _type: 'visualization', _source: { title: 'Metric High severity', @@ -152,7 +152,7 @@ export default [ } }, { - _id: 'Wazuh-App-Agents-vulnerability-Metric-Medium-severity', + _id: 'Wazuh-App-Agents-vuls-Metric-Medium-severity', _type: 'visualization', _source: { title: 'Metric Medium severity', @@ -198,7 +198,7 @@ export default [ } }, { - _id: 'Wazuh-App-Agents-vulnerability-Metric-Low-severity', + _id: 'Wazuh-App-Agents-vuls-Metric-Low-severity', _type: 'visualization', _source: { title: 'Metric Low severity', @@ -244,7 +244,7 @@ export default [ } }, { - _id: 'Wazuh-App-Agents-vulnerability-Top-Agents-severity', + _id: 'Wazuh-App-Agents-vuls-Top-Agents-severity', _type: 'visualization', _source: { title: 'Top Agents severity', @@ -260,7 +260,7 @@ export default [ } }, { - _id: 'Wazuh-App-Agents-vulnerability-Most-common-rules', + _id: 'Wazuh-App-Agents-vuls-Most-common-rules', _type: 'visualization', _source: { title: 'Most common rules', @@ -277,7 +277,7 @@ export default [ } }, { - _id: 'Wazuh-App-Agents-vulnerability-Vulnerability-severity-distribution', + _id: 'Wazuh-App-Agents-vuls-Vulnerability-severity-distribution', _type: 'visualization', _source: { title: 'Severity distribution', @@ -293,7 +293,7 @@ export default [ } }, { - _id: 'Wazuh-App-Agents-vulnerability-Vulnerability-Most-common-CVEs', + _id: 'Wazuh-App-Agents-vuls-Vulnerability-Most-common-CVEs', _type: 'visualization', _source: { title: 'Most common CVEs', diff --git a/server/integration-files/visualizations/overview/overview-vuls.js b/server/integration-files/visualizations/overview/overview-vuls.js index da5ad60b0..c91cabd71 100644 --- a/server/integration-files/visualizations/overview/overview-vuls.js +++ b/server/integration-files/visualizations/overview/overview-vuls.js @@ -11,7 +11,7 @@ */ export default [ { - _id: 'Wazuh-App-Overview-vulnerability-Alerts-severity', + _id: 'Wazuh-App-Overview-vuls-Alerts-severity', _type: 'visualization', _source: { title: 'Severity count', @@ -27,7 +27,7 @@ export default [ } }, { - _id: 'Wazuh-App-Overview-vulnerability-Alert-summary', + _id: 'Wazuh-App-Overview-vuls-Alert-summary', _type: 'visualization', _source: { title: 'Alert summary', @@ -44,7 +44,7 @@ export default [ } }, { - _id: 'Wazuh-App-Overview-vulnerability-Commonly-affected-packages', + _id: 'Wazuh-App-Overview-vuls-Commonly-affected-packages', _type: 'visualization', _source: { title: 'Commonly affected packages', @@ -60,7 +60,7 @@ export default [ } }, { - _id: 'Wazuh-App-Overview-vulnerability-Most-common-CVEs', + _id: 'Wazuh-App-Overview-vuls-Most-common-CVEs', _type: 'visualization', _source: { title: 'Most common CVEs', @@ -76,7 +76,7 @@ export default [ } }, { - _id: 'Wazuh-App-Overview-vulnerability-Most-common-CWEs', + _id: 'Wazuh-App-Overview-vuls-Most-common-CWEs', _type: 'visualization', _source: { title: 'Most common CWEs', @@ -92,7 +92,7 @@ export default [ } }, { - _id: 'Wazuh-App-Overview-vulnerability-Metric-Critical-severity', + _id: 'Wazuh-App-Overview-vuls-Metric-Critical-severity', _type: 'visualization', _source: { title: 'Metric Critical severity', @@ -138,7 +138,7 @@ export default [ } }, { - _id: 'Wazuh-App-Overview-vulnerability-Metric-High-severity', + _id: 'Wazuh-App-Overview-vuls-Metric-High-severity', _type: 'visualization', _source: { title: 'Metric High severity', @@ -184,7 +184,7 @@ export default [ } }, { - _id: 'Wazuh-App-Overview-vulnerability-Metric-Medium-severity', + _id: 'Wazuh-App-Overview-vuls-Metric-Medium-severity', _type: 'visualization', _source: { title: 'Metric Medium severity', @@ -230,7 +230,7 @@ export default [ } }, { - _id: 'Wazuh-App-Overview-vulnerability-Metric-Low-severity', + _id: 'Wazuh-App-Overview-vuls-Metric-Low-severity', _type: 'visualization', _source: { title: 'Metric Low severity', @@ -276,7 +276,7 @@ export default [ } }, { - _id: 'Wazuh-App-Overview-vulnerability-Most-affected-agents', + _id: 'Wazuh-App-Overview-vuls-Most-affected-agents', _type: 'visualization', _source: { title: 'Most affected agents', @@ -292,7 +292,7 @@ export default [ } }, { - _id: 'Wazuh-App-Overview-vulnerability-Vulnerability-severity-distribution', + _id: 'Wazuh-App-Overview-vuls-Vulnerability-severity-distribution', _type: 'visualization', _source: { title: 'Severity distribution',