From 5e230e48be5309b3fb0cf69760600aa3d16e4abe Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 11 Jul 2022 15:48:41 +0200 Subject: [PATCH] [Backport 4.4-1.2-wzd] Added new key request block in Registration service config (#4322) Added new key request block in Registration service config (#3956) * Added new key request block * Removed failed snapshots * Updated some test snapshots * Updated descriptions registration-service (cherry picked from commit 2b6ecf3bb1323fba9845bc7413f3114711cccf42) Co-authored-by: Maximiliano Ibarra --- .../registration-service.js | 69 ++++++++++++++----- 1 file changed, 52 insertions(+), 17 deletions(-) diff --git a/public/controllers/management/components/management/configuration/registration-service/registration-service.js b/public/controllers/management/components/management/configuration/registration-service/registration-service.js index 60ce62db20..dfe3fec659 100644 --- a/public/controllers/management/components/management/configuration/registration-service/registration-service.js +++ b/public/controllers/management/components/management/configuration/registration-service/registration-service.js @@ -17,24 +17,24 @@ import WzConfigurationSettingsTabSelector from '../util-components/configuration import withWzConfig from '../util-hocs/wz-config'; import WzNoConfig from '../util-components/no-config'; import { isString, renderValueNoThenEnabled } from '../utils/utils'; -import { webDocumentationLink } from '../../../../../../../common/services/web_documentation'; const helpLinks = [ { - text: 'Wazuh agent enrollment', - href: webDocumentationLink('user-manual/agent-enrollment/index.html') + text: 'How to use the registration service', + href: + 'https://documentation.wazuh.com/current/user-manual/registering/simple-registration-method.html', }, { text: 'Registration service reference', - href: webDocumentationLink('user-manual/reference/ossec-conf/auth.html') - } + href: 'https://documentation.wazuh.com/current/user-manual/reference/ossec-conf/auth.html', + }, ]; const mainSettings = [ { field: 'disabled', label: 'Service status', - render: renderValueNoThenEnabled + render: renderValueNoThenEnabled, }, { field: 'port', label: 'Listen to connections at port' }, { field: 'use_source_ip', label: "Use client's source IP address" }, @@ -42,39 +42,70 @@ const mainSettings = [ { field: 'purge', label: 'Purge agents list when removing agents' }, { field: 'limit_maxagents', - label: 'Limit registration to maximum number of agents' + label: 'Limit registration to maximum number of agents', }, { field: 'force.enabled', - label: 'Force registration when using an existing IP address' + label: 'Force registration when using an existing IP address', }, { field: 'force.after_registration_time', - label: 'Specifies that the agent replacement will be performed only when the time (seconds) passed since the agent registration is greater than the value configured in the setting' + label: + 'Specifies that the agent replacement will be performed only when the time (seconds) passed since the agent registration is greater than the value configured in the setting', }, { field: 'force.key_mismatch', - label: 'Avoid re-registering agents that already have valid keys' + label: 'Avoid re-registering agents that already have valid keys', }, { field: 'force.disconnected_time.enabled', - label: 'Specifies that the replacement will be performed only for agents that have been disconnected longer than a certain time' + label: + 'Specifies that the replacement will be performed only for agents that have been disconnected longer than a certain time', }, { field: 'force.disconnected_time.value', - label: 'Seconds since an agent is in a disconnected state' + label: 'Seconds since an agent is in a disconnected state', + }, +]; + +const keyRequestSettings = [ + { + field: 'key_request.enabled', + label: 'Key request status', + render: renderValueYesThenEnabled, + }, + { + field: 'key_request.exec_path', + label: 'Full path to the executable', + }, + { + field: 'key_request.socket', + label: 'Full path to the Unix domain socket', + }, + { + field: 'key_request.timeout', + label: 'Maximum time for waiting a response from the executable', + }, + { + field: 'key_request.threads', + label: 'Number of threads for dispatching the external keys requests', + }, + { + field: 'key_request.queue_size', + label: 'Indicates the maximum size of the queue for fetching external keys', }, ]; + const sslSettings = [ { field: 'ssl_verify_host', label: 'Verify agents using a CA certificate' }, { field: 'ssl_auto_negotiate', - label: 'Auto-select the SSL negotiation method' + label: 'Auto-select the SSL negotiation method', }, { field: 'ssl_manager_ca', label: 'CA certificate location' }, { field: 'ssl_manager_cert', label: 'Server SSL certificate location' }, { field: 'ssl_manager_key', label: 'Server SSL key location' }, - { field: 'ciphers', label: 'Use the following SSL ciphers' } + { field: 'ciphers', label: 'Use the following SSL ciphers' }, ]; class WzRegistrationService extends Component { @@ -112,6 +143,12 @@ class WzRegistrationService extends Component { config={currentConfig['auth-auth'].auth} items={mainSettings} /> +