Skip to content

Commit

Permalink
Don't arbitrarily limit set_mark to certain chains
Browse files Browse the repository at this point in the history
set_mark is not only allowed in PREROUTING or OUTPUT chain,
but also in custom chains, which are called from these.
  • Loading branch information
stesie committed Oct 27, 2014
1 parent db96537 commit edcc4ba
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions lib/puppet/type/firewall.rb
Original file line number Diff line number Diff line change
Expand Up @@ -1066,10 +1066,9 @@ def should_to_s(value)

if value(:set_mark)
unless value(:jump).to_s =~ /MARK/ &&
value(:chain).to_s =~ /PREROUTING|OUTPUT/ &&
value(:table).to_s =~ /mangle/
self.fail "Parameter set_mark only applies to " \
"the PREROUTING or OUTPUT chain of the mangle table and when jump => MARK"
"the mangle table and when jump => MARK"
end
end

Expand Down

0 comments on commit edcc4ba

Please sign in to comment.