Bug in iptables-save
I have a little firewall-script which uses the mac-module.
I made this rule:
iptables -A INPUT -m mac --mac ! my:mac:ad:dr:ess -p tcp --dport 3306 -j DROP
(I have substituted my real mac-addres with "my:mac:ad:dr:ess")
to block acces to my mysql-server from anywhere else than my machine.
It works. But when I try to use the iptables-save function that line turns into
-A INPUT -m mac --mac !my:mac:ad:dr:ess -p -tcp --dport 3306 -j DROP
Note that the <space> between "!" and the mac-address is gone. The result is that the reload of my iptables-ruleset stops with the error
message: "Bad mac address "!my:mac:ad:dr:ess"
I've experienced this with version 1.2.6a with a Mandrake 8.2 machine and version 1.2.6a + 1.2.7a with Debian sarge/testing. (Haven't tried version 1.2.7 with mandrake)
/Kristian Grønfeldt Sørensen