Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Global queries FIM - Make the necessary changes in wazuh-virtual-machines #222

Open
3 tasks
c-bordon opened this issue Feb 26, 2025 · 0 comments
Open
3 tasks
Assignees
Labels
level/task Task issue type/change Change performed in a resource or Wazuh Cloud environment

Comments

@c-bordon
Copy link
Member

Description

After analyzing the code of the AMI and the OVA, no changes were detected in general. This is because the installation is done in a standard way through packages.
What is detected is that a cleaning of the indexes is done in both cases.

OVA:

The provisioner has the following:

INDEXES=("wazuh-alerts-*" "wazuh-archives-*" "wazuh-states-vulnerabilities-*" "wazuh-statistics-*" "wazuh-monitoring-*")

.....

# Delete indexes
echo "Deleting indexes"
for index in "${INDEXES[@]}"; do
curl -u admin:admin -XDELETE "https://127.0.0.1:9200/$index" -k
done

In this case, it may be necessary to perform a regex on the new indexes to clean them up.

AMI:

In the AMI playbook, the following steps were detected:

- name: Define list of Indexer indices
set_fact:
indexer_indices:
- wazuh-alerts
- wazuh-archives
- wazuh-states-vulnerabilities
- wazuh-statistics
- wazuh-monitoring

- name: Delete Indexer indices
uri:
url: "https://localhost:9200/{{ item }}-*"
method: DELETE
user: admin
password: "{{ old_password }}"
validate_certs: no
status_code: 200
loop: "{{ indexer_indices }}"
register: delete_response

This is a similar case to the OVA, it may be necessary to add the new states indexes.
Both modifications, if necessary, are very simple changes with a low impact. Otherwise, there are no further modifications or references to the states.
Once the changes, packages and branches are ready, it would be important to perform some tests to validate that everything is generated correctly. The issue is moved to pending review, and the tests can be performed in a new one.

Tasks

  • Add cleanup the new indices
  • Test after builds the OVA and AMI

DRI

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
level/task Task issue type/change Change performed in a resource or Wazuh Cloud environment
Projects
Status: Backlog
Development

No branches or pull requests

2 participants