Add Firewall Logic

This commit is contained in:
Mike Reeves
2020-09-09 21:16:40 -04:00
parent 45b11b2321
commit 5d4e8925a3
6 changed files with 35 additions and 8 deletions
+7 -6
View File
@@ -2,10 +2,11 @@
{%- set RULESET = salt['pillar.get']('idstools:config:ruleset') -%}
{%- set OINKCODE = salt['pillar.get']('idstools:config:oinkcode', '' ) -%}
{%- set ISAIRGAP = salt['pillar.get']('global:airgap', 'False') -%}
{% if ISAIRGAP is sameas true %}
{%- set MANAGERIP = salt['pillar.get']('global:managerip', '') -%}
{%- if ISAIRGAP is sameas true -%}
--merged=/opt/so/rules/nids/all.rules
--local=/opt/so/rules/nids/local.rules
--local=/opt/so/rules/nids/emerging-all.rules
--url=http://{{ MANAGERIP }}/repo/rules/emerging-all.rules
--disable=/opt/so/idstools/etc/disable.conf
--enable=/opt/so/idstools/etc/enable.conf
--modify=/opt/so/idstools/etc/modify.conf
@@ -24,8 +25,8 @@
--url=https://www.snort.org/rules/snortrules-snapshot-2983.tar.gz?oinkcode={{ OINKCODE }}
{%- endif -%}
{%- endif -%}
{%- if URLS != None %}
{%- for URL in URLS %}
{%- if URLS != None -%}
{%- for URL in URLS -%}
--url={{ URL }}
{%- endfor %}
{%- endif %}
{%- endfor -%}
{%- endif -%}