Create ICMP Firewall rule
This commit is contained in:
parent
fe35b6d512
commit
92d485bea5
3 changed files with 30 additions and 0 deletions
5
defaults/main.yml
Normal file
5
defaults/main.yml
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
---
|
||||||
|
# set ICMP Profiles on private and public networks on default
|
||||||
|
win_firewall_icmp_profiles:
|
||||||
|
- private
|
||||||
|
- public
|
22
tasks/firewall.yml
Normal file
22
tasks/firewall.yml
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
---
|
||||||
|
- name: Firewall rule to alloc ICMP v4 on all type codes
|
||||||
|
community.windows.win_firewall_rule:
|
||||||
|
name: ICMP Allow incoming V4 echo request
|
||||||
|
enabled: yes
|
||||||
|
state: present
|
||||||
|
profiles: "{{ win_firewall_icmp_profiles }}"
|
||||||
|
action: allow
|
||||||
|
direction: in
|
||||||
|
protocol: icmpv4
|
||||||
|
icmp_type_code: '*'
|
||||||
|
|
||||||
|
- name: Firewall rule to alloc ICMP v6 on all type codes
|
||||||
|
community.windows.win_firewall_rule:
|
||||||
|
name: ICMP Allow incoming V6 echo request
|
||||||
|
enabled: yes
|
||||||
|
state: present
|
||||||
|
profiles: "{{ win_firewall_icmp_profiles }}"
|
||||||
|
action: allow
|
||||||
|
direction: in
|
||||||
|
protocol: icmpv6
|
||||||
|
icmp_type_code: '*'
|
3
tasks/main.yml
Normal file
3
tasks/main.yml
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
---
|
||||||
|
- name: Cofigure ICMP on Windows Firewall
|
||||||
|
ansible.builtin.include_tasks: firewall.yml
|
Loading…
Reference in a new issue