diff --git a/roles/wazuh/ansible-wazuh-agent/templates/var-ossec-etc-ossec-agent.conf.j2 b/roles/wazuh/ansible-wazuh-agent/templates/var-ossec-etc-ossec-agent.conf.j2
index 4d43bc94..61c28012 100644
--- a/roles/wazuh/ansible-wazuh-agent/templates/var-ossec-etc-ossec-agent.conf.j2
+++ b/roles/wazuh/ansible-wazuh-agent/templates/var-ossec-etc-ossec-agent.conf.j2
@@ -1,4 +1,4 @@
-#jinja2: trim_blocks: False
+#jinja2: lstrip_blocks: True
{{ wazuh_agent_config.client_buffer.disable }}
{{ wazuh_agent_config.client_buffer.queue_size }}
{{ wazuh_agent_config.client_buffer.events_per_sec }}
+
{{ wazuh_agent_config.log_format }}
@@ -72,7 +72,6 @@
{% endif %}
yes
{% endif %}
-
{% if ansible_os_family == "Windows" %}
./shared/win_audit_rcl.txt
./shared/win_applications_rcl.txt
@@ -86,11 +85,11 @@
{% if wazuh_agent_config.syscheck is defined %}
no
-
+
{{ wazuh_agent_config.syscheck.frequency }}
{% if ansible_system == "Linux" %}
-
+
/etc,/usr/bin,/usr/sbin
/bin,/sbin,/boot
@@ -130,7 +129,7 @@
{% for no_diff in wazuh_agent_config.syscheck.no_diff %}
{{ no_diff }}
{% endfor %}
-
+
{{ wazuh_agent_config.syscheck.skip_nfs }}
{% endif %}
@@ -270,29 +269,29 @@
{{ wazuh_agent_config.syscollector.processes }}
-
- {% if wazuh_agent_config.sca.enabled | length > 0 %}
- {{ wazuh_agent_config.sca.enabled }}
- {% endif %}
- {% if wazuh_agent_config.sca.scan_on_start | length > 0 %}
- {{ wazuh_agent_config.sca.scan_on_start }}
- {% endif %}
- {% if wazuh_agent_config.sca.interval | length > 0 %}
- {{ wazuh_agent_config.sca.interval }}
- {% endif %}
- {% if wazuh_agent_config.sca.skip_nfs | length > 0 %}
- yes
- {% endif %}
- {% if wazuh_agent_config.sca.day | length > 0 %}
- yes
- {% endif %}
- {% if wazuh_agent_config.sca.wday | length > 0 %}
- yes
- {% endif %}
- {% if wazuh_agent_config.sca.time | length > 0 %}
-
- {% endif %}
-
+
+ {% if wazuh_agent_config.sca.enabled | length > 0 %}
+ {{ wazuh_agent_config.sca.enabled }}
+ {% endif %}
+ {% if wazuh_agent_config.sca.scan_on_start | length > 0 %}
+ {{ wazuh_agent_config.sca.scan_on_start }}
+ {% endif %}
+ {% if wazuh_agent_config.sca.interval | length > 0 %}
+ {{ wazuh_agent_config.sca.interval }}
+ {% endif %}
+ {% if wazuh_agent_config.sca.skip_nfs | length > 0 %}
+ yes
+ {% endif %}
+ {% if wazuh_agent_config.sca.day | length > 0 %}
+ yes
+ {% endif %}
+ {% if wazuh_agent_config.sca.wday | length > 0 %}
+ yes
+ {% endif %}
+ {% if wazuh_agent_config.sca.time | length > 0 %}
+
+ {% endif %}
+
{% if ansible_system == "Linux" and wazuh_agent_config.vuls.disable == 'no' %}
@@ -306,68 +305,72 @@
{% endif %}
- {% if ansible_system == "Linux" %}
- {% for localfile in wazuh_agent_config.localfiles.linux %}
-
- {{ localfile.format }}
+ {% if ansible_system == "Linux" %}
+ {% for localfile in wazuh_agent_config.localfiles.linux %}
+
+
+ {{ localfile.format }}
{% if localfile.format == 'command' or localfile.format == 'full_command' %}
- {{ localfile.command }}
- {{ localfile.frequency }}
- {% if localfile.alias is defined %}
- {{ localfile.alias }}
- {% endif %}
- {% else %}
- {{ localfile.location }}
+ {{ localfile.command }}
+ {{ localfile.frequency }}
+ {% if localfile.alias is defined %}
+ {{ localfile.alias }}
{% endif %}
-
+ {% else %}
+ {{ localfile.location }}
+ {% endif %}
+
{% endfor %}
{% endif %}
- {% if ansible_os_family == "Debian" %}
- {% for localfile in wazuh_agent_config.localfiles.debian %}
-
- {{ localfile.format }}
+ {% if ansible_os_family == "Debian" %}
+ {% for localfile in wazuh_agent_config.localfiles.debian %}
+
+
+ {{ localfile.format }}
{% if localfile.format == 'command' or localfile.format == 'full_command' %}
- {{ localfile.command }}
- {{ localfile.frequency }}
- {% if localfile.alias is defined %}
- {{ localfile.alias }}
- {% endif %}
- {% else %}
- {{ localfile.location }}
- {% endif %}
-
+ {{ localfile.command }}
+ {{ localfile.frequency }}
+ {% if localfile.alias is defined %}
+ {{ localfile.alias }}
+ {% endif %}
+ {% else %}
+ {{ localfile.location }}
+ {% endif %}
+
{% endfor %}
{% endif %}
- {% if ansible_os_family == "RedHat" %}
- {% for localfile in wazuh_agent_config.localfiles.centos %}
-
- {{ localfile.format }}
+ {% if ansible_os_family == "RedHat" %}
+ {% for localfile in wazuh_agent_config.localfiles.centos %}
+
+
+ {{ localfile.format }}
{% if localfile.format == 'command' or localfile.format == 'full_command' %}
- {{ localfile.command }}
- {{ localfile.frequency }}
- {% if localfile.alias is defined %}
- {{ localfile.alias }}
- {% endif %}
+ {{ localfile.command }}
+ {{ localfile.frequency }}
+ {% if localfile.alias is defined %}
+ {{ localfile.alias }}
+ {% endif %}
{% else %}
- {{ localfile.location }}
- {% endif %}
-
+ {{ localfile.location }}
+ {% endif %}
+
{% endfor %}
{% endif %}
- {% if ansible_os_family == "Windows" %}
- {% for localfile in wazuh_agent_config.localfiles.windows %}
-
- {{ localfile.format }}
- {% if localfile.format == 'eventchannel' %}
- {{ localfile.location }}
- {{ localfile.query}}
- {% else %}
- {{ localfile.location }}
- {% endif %}
-
+ {% if ansible_os_family == "Windows" %}
+ {% for localfile in wazuh_agent_config.localfiles.windows %}
+
+
+ {{ localfile.format }}
+ {% if localfile.format == 'eventchannel' %}
+ {{ localfile.location }}
+ {{ localfile.query}}
+ {% else %}
+ {{ localfile.location }}
+ {% endif %}
+
{% endfor %}
{% endif %}