-
Notifications
You must be signed in to change notification settings - Fork 455
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Module does not parse negated rules correctly #141
Comments
Yeah, I've been working on a new parser that should help with this: https://github.com/kbarber/ruby-iptables and https://rubygems.org/gems/iptables. It is, at least according to a lot of my tests - fairly much feature complete which is nice, as apposed to our current parser which is not. This is because I spent the extra effort analyzing the model that iptables uses and making the iptables.rb code as generic as possible to fit that model. The idea is that the gem 'iptables' is a closer model to iptables and the iptables provider can then just act as a bridge. I haven't yet done this work though ... its in my grand plan, just wanted to get the iptables library stable first. |
is there a version I can safely revert to? |
This is a really critical bug. It is impossible to use firewall module if rules with "!" get inserted. Is it possible to workaround this bug or revert to some stable version of firewall module ? |
We (DTG) are staying on v0.0.4 rather than upgrading to 0.3.0 (there is probably a working version higher than our current one but I am not going looking for it). |
How's progress on this going kbarber? This is a big stinky problem for us too. |
Yep, hard to do the rules that IPTables automatically sets up for bridging interfaces which is needed for KVM without this feature. |
It seems this bugs has not been resolved. I have try the latest version but it failed. |
I'll just add my +1 here: this is messing me up. I can't even create the rule outside of puppet, because the provider blows up badly if I've got that rule with a negation in there. |
Since this bug, which is really quite major, has been here for 7 months, I wasn't inclined to wait for a new parser. This will solve the problem enough to allow you to add other rules. It does NOT allow you to add your own negated rules, but it does not appear to munge or break any that are already there:
|
Having done so, on some hosts I got this:
Apparently caused by:
And, in fact, it's the --random that causes the problem, despite the message. I fixed this with a hack just as nasty as the last, but again, it doesn't seem to break any of the currently extant rules, which is all I care about. The new diff:
|
+1 on KVM |
Hello, |
I don't know that I would consider my updates a patch. They don't improve the capability of the module, they simply throw out the things that confuse it. Having said that, umm, it works fine for me! :D |
This bug would be fixed by PR #267 which both handles existing rules and lets you add them. |
This adds tests mentioned in puppetlabs#141 and MODULES-48 to make sure that they are covered by puppetlabs#267 Closes puppetlabs#141
Add --random support as per #141 comment
This adds tests mentioned in puppetlabs#141 and MODULES-48 to make sure that they are covered by puppetlabs#267 Closes puppetlabs#141
I have an iptables configuration that contains a few rules in the
nat
table similar to the following:The parsing code appears to be choking on the exclamation point in the rule:
I would maybe like it not to do that or at least fail in a way that still allows it to apply the rules I've specified in my manifests.
The text was updated successfully, but these errors were encountered: