Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

(#10322) Insert order hash included chains from different tables

This fix corrects the insert_order handling to make sure that not only are
rules from the same chain evaulated, but we also check that the table
matches as well.
  • Loading branch information...
commit 47318a009c50f2625bd3df8a1de78d5477d35b57 1 parent e9fd6d1
Ken Barber kbarber authored

Showing 1 changed file with 4 additions and 2 deletions. Show diff stats Hide diff stats

  1. +4 2 lib/puppet/provider/firewall/iptables.rb
6 lib/puppet/provider/firewall/iptables.rb
@@ -288,9 +288,11 @@ def insert_order
288 288 debug("[insert_order]")
289 289 rules = []
290 290
291   - # Find list of current rules based on chain
  291 + # Find list of current rules based on chain and table
292 292 self.class.instances.each do |rule|
293   - rules << rule.name if rule.chain == resource[:chain].to_s
  293 + if rule.chain == resource[:chain].to_s and rule.table == resource[:table].to_s
  294 + rules << rule.name
  295 + end
294 296 end
295 297
296 298 # No rules at all? Just bail now.

0 comments on commit 47318a0

Please sign in to comment.
Something went wrong with that request. Please try again.