Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
…o feat/4312-replace-search-bar-agent-inventory
  • Loading branch information
Desvelao committed Aug 11, 2023
2 parents 5a894a5 + f987351 commit a9a6564
Show file tree
Hide file tree
Showing 28 changed files with 640 additions and 463 deletions.
7 changes: 5 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,7 @@ All notable changes to the Wazuh app project will be documented in this file.
- Changed the query to search for an agent in `management/configuration`. [#5485](https://github.com/wazuh/wazuh-kibana-app/pull/5485)
- Changed the search bar in management/log to the one used in the rest of the app. [#5476](https://github.com/wazuh/wazuh-kibana-app/pull/5476)
- Changed the design of the wizard to add agents. [#5457](https://github.com/wazuh/wazuh-kibana-app/pull/5457)
- Changed the search bar in Management (Rules, Decoders, CDB List) and Modules (Vulnerabilities > Inventory, Security Configuration Assessment > Inventory > {Policy ID} > Checks, MITRE ATT&CK > Intelligence > {Resource}), Agent Inventory data [#5363](https://github.com/wazuh/wazuh-kibana-app/pull/5363) [#5442](https://github.com/wazuh/wazuh-kibana-app/pull/5442)
- Changed the search bar and Agents > Inventory data [#5443](https://github.com/wazuh/wazuh-kibana-app/pull/5443)
- Changed the search bar in Management (Rules, Decoders, CDB List) and Modules (Vulnerabilities > Inventory, Security Configuration Assessment > Inventory > {Policy ID} > Checks, MITRE ATT&CK > Intelligence > {Resource}), Agent Inventory data [#5363](https://github.com/wazuh/wazuh-kibana-app/pull/5363) [#5442](https://github.com/wazuh/wazuh-kibana-app/pull/5442) [#5443](https://github.com/wazuh/wazuh-kibana-app/pull/5443)

### Fixed

Expand Down Expand Up @@ -67,6 +66,9 @@ All notable changes to the Wazuh app project will be documented in this file.

- Fixed the rendering of tables that contains IPs and agent overview [#5471](https://github.com/wazuh/wazuh-kibana-app/pull/5471)
- Fixed the agents active coverage stat as NaN in Details panel of Agents section [#5490](https://github.com/wazuh/wazuh-kibana-app/pull/5490)
- Fixed a broken documentation link to agent labels [#5687](https://github.com/wazuh/wazuh-kibana-app/pull/5687)
- Fixed the PDF report filters applied to tables [#5714](https://github.com/wazuh/wazuh-kibana-app/pull/5714)
- Fixed outdated year in the PDF report footer [#5766](https://github.com/wazuh/wazuh-kibana-app/pull/5766)

### Removed

Expand All @@ -76,6 +78,7 @@ All notable changes to the Wazuh app project will be documented in this file.

- Changed method to perform redirection on agent table buttons [#5539](https://github.com/wazuh/wazuh-kibana-app/pull/5539)
- Changed windows agent service name in the deploy agent wizard [#5538](https://github.com/wazuh/wazuh-kibana-app/pull/5538)
- Changed the requests to get the agent labels for the managers [#5687](https://github.com/wazuh/wazuh-kibana-app/pull/5687)

## Wazuh v4.5.0 - OpenSearch Dashboards 2.6.0 - Revision 01

Expand Down
15 changes: 15 additions & 0 deletions docker/imposter/agents/configuration.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
var path = context.request.path;
var pathConfiguration = path.split('/');
pathConfiguration.splice(0, 5);
console.log(pathConfiguration);
switch (pathConfiguration[0]) {
case 'labels':
respond()
.withStatusCode(200)
.withFile('agents/configuration/agent_labels.json');

break;
default:
respond().withStatusCode(200).withFile('agents/configuration/default.json');
break;
}
12 changes: 12 additions & 0 deletions docker/imposter/agents/configuration/agent_labels.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"data": {
"labels": [
{
"value": "customLabel",
"key": "custom",
"hidden": "no"
}
]
},
"error": 0
}
33 changes: 33 additions & 0 deletions docker/imposter/agents/configuration/default.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
{
"data": {
"client": {
"config-profile": "ubuntu, ubuntu20, ubuntu20.04",
"notify_time": 10,
"time-reconnect": 60,
"force_reconnect_interval": 0,
"ip_update_interval": 0,
"auto_restart": "yes",
"remote_conf": "yes",
"crypto_method": "aes",
"server": [
{
"address": "nginx-lb/172.25.0.4",
"port": 1514,
"max_retries": 5,
"retry_interval": 10,
"protocol": "tcp"
}
],
"enrollment": [
{
"enabled": "yes",
"delay_after_enrollment": 20,
"port": 1515,
"ssl_cipher": "HIGH:!ADH:!EXP:!MD5:!RC4:!3DES:!CAMELLIA:@STRENGTH",
"auto_method": "no"
}
]
}
},
"error": 0
}
20 changes: 20 additions & 0 deletions docker/imposter/cluster/configuration/agent_labels.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"data": {
"affected_items": [
{
"labels": [
{
"value": "customLabel",
"key": "custom",
"hidden": "no"
}
]
}
],
"total_affected_items": 1,
"total_failed_items": 0,
"failed_items": []
},
"message": "Active configuration was successfully read in specified node.",
"error": 0
}
22 changes: 22 additions & 0 deletions docker/imposter/manager/configuration.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
var path = context.request.path;
var pathConfiguration = path.split('/');
pathConfiguration.splice(0, 4);
switch (pathConfiguration[0]) {
case 'labels':
respond()
.withStatusCode(200)
.withFile('manager/configuration/agent_labels.json');

break;
case 'reports':
respond()
.withStatusCode(200)
.withFile('manager/configuration/monitor_reports.json');

break;
default:
respond()
.withStatusCode(200)
.withFile('manager/configuration/default.json');
break;
}
20 changes: 20 additions & 0 deletions docker/imposter/manager/configuration/agent_labels.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"data": {
"affected_items": [
{
"labels": [
{
"value": "customLabel",
"key": "custom",
"hidden": "no"
}
]
}
],
"total_affected_items": 1,
"total_failed_items": 0,
"failed_items": []
},
"message": "Active configuration was successfully read in specified node.",
"error": 0
}
35 changes: 35 additions & 0 deletions docker/imposter/manager/configuration/default.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"data": {
"affected_items": [
{
"global": {
"email_notification": "no",
"logall": "no",
"logall_json": "no",
"integrity_checking": 8,
"rootkit_detection": 8,
"host_information": 8,
"prelude_output": "no",
"zeromq_output": "no",
"jsonout_output": "yes",
"alerts_log": "yes",
"stats": 4,
"memory_size": 8192,
"white_list": [
"127.0.0.1",
"80.58.61.250",
"80.58.61.254",
"localhost.localdomain"
],
"rotate_interval": 0,
"max_output_size": 0
}
}
],
"total_affected_items": 1,
"total_failed_items": 0,
"failed_items": []
},
"message": "Active configuration was successfully read in specified node",
"error": 0
}
16 changes: 16 additions & 0 deletions docker/imposter/manager/configuration/monitor_reports.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"data": {
"affected_items": [{
"reports": [{
"category": "syscheck",
"title": "Daily report: File changes",
"email_to": "example@test.com"
}]
}],
"total_affected_items": 1,
"total_failed_items": 0,
"failed_items": []
},
"message": "Could not read active configuration in specified node",
"error": 0
}
3 changes: 3 additions & 0 deletions docker/imposter/wazuh-config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -507,6 +507,9 @@ resources:
# Get active configuration
- method: GET
path: /manager/configuration/{component}/{configuration}
response:
statusCode: 200
scriptFile: manager/configuration.js

# ===================================================== #
# MITRE
Expand Down
Loading

0 comments on commit a9a6564

Please sign in to comment.