You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Affected Puppet, Ruby, OS and module versions/distributions
Puppet: 7
Ruby:
Distribution:
Module version: 4.0.0
How to reproduce (e.g Puppet code you use)
windows_firewall::exception { "trusted $description":
ensure => $rulestate,
direction => 'in',
action => 'allow',
enabled => true,
protocol => 'any',
remote_ip => $hostip,
description => "allow all for $description",
}
What are you seeing
Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Resource Statement, Windows_firewall::Exception[trusted bg-01]: parameter 'protocol' expects an undef value or a match for Enum['ICMPv4', 'ICMPv6', 'TCP', 'UDP'], got 'any'
The abilities of exception.pp could be expanded if the value 'any' will be added in Enum in line 84
Optional[Enum['any', 'TCP', 'UDP', 'ICMPv4', 'ICMPv6']] $protocol = undef,
This modification allows creating a generic allow rule for fully trusted host without needing to specify several rules with different protocols and ports.
The text was updated successfully, but these errors were encountered:
I am looking for the same resolution so we can use this module in our environment.
Change:
Optional[Enum['TCP', 'UDP', 'ICMPv4', 'ICMPv6']] $protocol = undef,
To:
Optional[Enum['Any', 'TCP', 'UDP', 'ICMPv4', 'ICMPv6']] $protocol = undef,
The command supports Any from what I see and tested.
Thank you,
Jeff
ola-pt
added a commit
to ola-pt/puppet-windows_firewall
that referenced
this issue
Sep 10, 2022
Affected Puppet, Ruby, OS and module versions/distributions
How to reproduce (e.g Puppet code you use)
windows_firewall::exception { "trusted $description":
ensure => $rulestate,
direction => 'in',
action => 'allow',
enabled => true,
protocol => 'any',
remote_ip => $hostip,
description => "allow all for $description",
}
What are you seeing
Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Resource Statement, Windows_firewall::Exception[trusted bg-01]: parameter 'protocol' expects an undef value or a match for Enum['ICMPv4', 'ICMPv6', 'TCP', 'UDP'], got 'any'
What behaviour did you expect instead
Notice: /Stage[main]/Fw_trusted/Windows_firewall::Exception[trusted bg-01]/Exec[set rule trusted bg-01]/returns: executed successfully
Output log
Any additional information you'd like to impart
The abilities of exception.pp could be expanded if the value 'any' will be added in Enum in line 84
Optional[Enum['any', 'TCP', 'UDP', 'ICMPv4', 'ICMPv6']] $protocol = undef,
This modification allows creating a generic allow rule for fully trusted host without needing to specify several rules with different protocols and ports.
The text was updated successfully, but these errors were encountered: