From 5360fa7e20d5bf71aaa813307cc3bb89c1e84bce Mon Sep 17 00:00:00 2001 From: JuanGarriuz Date: Mon, 12 Aug 2024 13:22:06 +0200 Subject: [PATCH] Fixed always disabled property from Active response (#6901) * Render from disabled response was deleted and description changes * Changes title and add changelog --- CHANGELOG.md | 4 + .../active-response-active-response.js | 7 +- .../configuration/configuration-settings.js | 90 +++++++++---------- 3 files changed, 49 insertions(+), 52 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0af5c4ff81..93c9ca9767 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,10 @@ All notable changes to the Wazuh app project will be documented in this file. - Support for Wazuh 4.9.1 +### Fixed + +- Fixed rendering an active response as disabled when is active [#6901](https://github.com/wazuh/wazuh-dashboard-plugins/pull/6901) + ## Wazuh v4.9.0 - OpenSearch Dashboards 2.13.0 - Revision 03 ### Added diff --git a/plugins/main/public/controllers/management/components/management/configuration/active-response/active-response-active-response.js b/plugins/main/public/controllers/management/components/management/configuration/active-response/active-response-active-response.js index 7d5f26790e..eff4d0a323 100644 --- a/plugins/main/public/controllers/management/components/management/configuration/active-response/active-response-active-response.js +++ b/plugins/main/public/controllers/management/components/management/configuration/active-response/active-response-active-response.js @@ -26,11 +26,6 @@ import withWzConfig from '../util-hocs/wz-config'; import { webDocumentationLink } from '../../../../../../../common/services/web_documentation'; const mainSettings = [ - { - field: 'disabled', - label: 'Status of this active response', - render: renderValueNoThenEnabled, - }, { field: 'command', label: 'Command to execute' }, { field: 'location', label: 'Execute the command on this location' }, { field: 'agent_id', label: 'Agent ID on which execute the command' }, @@ -93,7 +88,7 @@ class WzConfigurationActiveResponseActiveResponse extends Component { currentConfig['analysis-active_response']['active-response'].length ? ( hasAgentSupportModule(agent, WAZUH_MODULES_ID.OPEN_SCAP) + when: agent => hasAgentSupportModule(agent, WAZUH_MODULES_ID.OPEN_SCAP), }, { name: 'CIS-CAT', description: 'Configuration assessment using CIS scanner and SCAP checks', - goto: 'cis-cat' - } - ] + goto: 'cis-cat', + }, + ], }, { title: 'System threats and incident response', @@ -122,45 +122,45 @@ export default [ description: 'Discover what applications are affected by well-known vulnerabilities', goto: 'vulnerabilities', - when: 'manager' + when: 'manager', }, { name: 'Osquery', description: 'Expose an operating system as a high-performance relational database', - goto: 'osquery' + goto: 'osquery', }, { name: 'Inventory data', description: 'Gather relevant information about system operating system, hardware, networking and packages', - goto: 'inventory' + goto: 'inventory', }, { - name: 'Active Response', + name: 'Active response', description: 'Active threat addressing by immediate response', goto: 'active-response', - when: 'manager' + when: 'manager', }, { name: 'Active response', description: 'Active threat addressing by immediate response', goto: 'active-response-agent', - when: 'agent' + when: 'agent', }, { name: 'Commands', description: 'Configuration options of the Command wodle', - goto: 'commands' + goto: 'commands', }, { name: 'Docker listener', description: 'Monitor and collect the activity from Docker containers such as creation, running, starting, stopping or pausing events', goto: 'docker-listener', - when: agent => hasAgentSupportModule(agent, WAZUH_MODULES_ID.DOCKER) - } - ] + when: agent => hasAgentSupportModule(agent, WAZUH_MODULES_ID.DOCKER), + }, + ], }, { title: 'Log data analysis', @@ -170,22 +170,22 @@ export default [ name: 'Log collection', description: 'Log analysis from text files, Windows events or syslog outputs', - goto: 'log-collection' + goto: 'log-collection', }, { name: 'Integrity monitoring', description: 'Identify changes in content, permissions, ownership, and attributes of files', - goto: 'integrity-monitoring' + goto: 'integrity-monitoring', }, { name: 'Agentless', description: 'Run integrity checks on devices such as routers, firewalls and switches', goto: 'agentless', - when: 'manager' - } - ] + when: 'manager', + }, + ], }, { title: 'Cloud security monitoring', @@ -195,32 +195,30 @@ export default [ name: 'Amazon S3', description: 'Security events related to Amazon AWS services, collected directly via AWS API', - goto: 'aws-s3' + goto: 'aws-s3', }, { name: 'Azure Logs', description: 'Configuration options of the Azure Logs wodle', goto: 'azure-logs', - when: 'manager' + when: 'manager', }, { name: 'Google Cloud Pub/Sub', description: 'Configuration options of the Google Cloud Pub/Sub module', - goto: 'gcp-pubsub' + goto: 'gcp-pubsub', }, { name: 'GitHub', - description: - 'Detect threats targeting GitHub organizations', - goto: 'github' + description: 'Detect threats targeting GitHub organizations', + goto: 'github', }, { name: 'Office 365', - description: - 'Configuration options of the Office 365 module', + description: 'Configuration options of the Office 365 module', goto: 'office365', - when: 'manager' - } - ] - } + when: 'manager', + }, + ], + }, ];