Failed to create firewall rules

9 posts / 0 new
Last post
#1 Sat, 02/07/2009 - 21:21
dac

Failed to create firewall rules

I pressed Reset Firewall, there were no rules... then pressed "Block all except ports used for virtual hosting, on interface": selected the interface eth0 and "Setup firewall" .. now I see a list of rules.. ok... then press "Apply configuration" and this is the output: Failed to apply configuration :

iptables-restore v1.3.6: invalid port/service 25,587' specified Error occurred at line: 63 Tryiptables-restore -h' or 'iptables-restore --help' for more information.

what's wrong ? Thank you!

Sat, 02/07/2009 - 21:32
dac

oh sorry... I think this is a webmin question. not virtualmin....

Sun, 02/08/2009 - 11:51 (Reply to #2)
Joe
Joe's picture

<div class='quote'>I think this is a webmin question. not virtualmin</div>

That's OK. It's well-placed in the &quot;Help!&quot; forum.

You can't use a comma in the port field. You need two rules for two services.

--

Check out the forum guidelines!

Sun, 02/08/2009 - 22:34 (Reply to #3)
dac

thank you
I didn't put the comma... just pressed the option for &quot;Block all except ports used for virtual hosting, on interface&quot; and dii all those rules for me....
anyway... I tried the other option... &quot;Block all except SSH and IDENT on external interface&quot; and it works... and added some other ports using comma in one of the rules.... and didn't complain about the comma and it is working.

Mon, 02/09/2009 - 14:11 (Reply to #4)
Joe
Joe's picture

Funny. I've never used a comma before in a rule...and iptables on my system isn't liking it. Sounds like maybe there's a bug in that particular option.

Might be worth filing a ticket, if the problem is reproduce-able.

--

Check out the forum guidelines!

Mon, 03/02/2009 - 11:19 (Reply to #5)
rapidleech

it is reproducable, i get the exact same error doing the exact same thing on Debian, and I can clearly see comma separated values in the iptables rules. if i remove the offending ports with the commas, then all works ok. :)

Tue, 03/10/2009 - 19:30 (Reply to #6)
Joe
Joe's picture

Yes, this is a bug .. the upcoming 1.460 release of Webmin will fix it though.

--

Check out the forum guidelines!

Tue, 03/10/2009 - 15:29
sschueller

I can also reproduce this on both clean install of Debian 5 and CentOS 5.2.

Steps to reproduce:

1. Webmin / Networking / Linux Firewall
2. Reset Firewall
3. Block all except ports used for virtual hosting, on interface: eth0
4. Apply Configuration
5. Following error appears:

Failed to apply configuration :

iptables-restore v1.4.2: invalid port/service `25,587' specified
Error occurred at line: 63
Try `iptables-restore -h' or 'iptables-restore --help' for more information.

Tue, 03/10/2009 - 15:31 (Reply to #8)
Joe
Joe's picture

So...file a bug and Jamie will fix it. Better hurry, as the next version of Webmin is only a day or two away. ;-)

--

Check out the forum guidelines!

Topic locked