Merge pull request #12577 from Security-Onion-Solutions/jppsocerino

remove modules if detections disabled
This commit is contained in:
Josh Patterson
2024-03-13 10:30:00 -04:00
committed by GitHub
2 changed files with 8 additions and 1 deletions

View File

@@ -1081,7 +1081,7 @@ soc:
allowRegex: '' allowRegex: ''
autoUpdateEnabled: false autoUpdateEnabled: false
communityRulesImportFrequencySeconds: 86400 communityRulesImportFrequencySeconds: 86400
denyRegex: '.*' denyRegex: ''
elastAlertRulesFolder: /opt/sensoroni/elastalert elastAlertRulesFolder: /opt/sensoroni/elastalert
rulesFingerprintFile: /opt/sensoroni/fingerprints/sigma.fingerprint rulesFingerprintFile: /opt/sensoroni/fingerprints/sigma.fingerprint
sigmaRulePackages: sigmaRulePackages:

View File

@@ -30,6 +30,13 @@
{# since cases is not a valid soc config item and only used for the map files, remove it from being placed in the config #} {# since cases is not a valid soc config item and only used for the map files, remove it from being placed in the config #}
{% do SOCMERGED.config.server.modules.pop('cases') %} {% do SOCMERGED.config.server.modules.pop('cases') %}
{# remove these modules if detections is disabled #}
{% if not SOCMERGED.config.server.client.detectionsEnabled %}
{% do SOCMERGED.config.server.modules.pop('elastalertengine') %}
{% do SOCMERGED.config.server.modules.pop('strelkaengine') %}
{% do SOCMERGED.config.server.modules.pop('suricataengine') %}
{% endif %}
{% if pillar.manager.playbook == 0 %} {% if pillar.manager.playbook == 0 %}
{% do SOCMERGED.config.server.client.inactiveTools.append('toolPlaybook') %} {% do SOCMERGED.config.server.client.inactiveTools.append('toolPlaybook') %}
{% endif %} {% endif %}