From: Mart Frauenlob <mart.frauenlob@chello.at>
To: netfilter@vger.kernel.org
Subject: Bug in limit match?
Date: Wed, 17 Dec 2008 10:44:25 +0100 [thread overview]
Message-ID: <4948C9F9.5010803@chello.at> (raw)
Hello netfilter user mailing list!
I think i discovered a small problem with the limit match of iptables:
eris:~# iptables -A INPUT -i eth2 -s 123.123.123.123 -m limit --limit
1/day -j LOG
iptables: Invalid argument
eris:~#
eris:~# iptables -A INPUT -i eth2 -s 123.123.123.123 -m limit --limit
2/day -j LOG
eris:~# echo $?
0
eris:~#
eris:~# iptables -A INPUT -i eth2 -s 123.123.123.123 -m limit --limit
3/day -j LOG
iptables: Invalid argument
eris:~#
eris:~# iptables -A INPUT -i eth2 -s 123.123.123.123 -m limit --limit
4/day -j LOG
eris:~# echo $?
0
eris:~#
the invalid argument error, happens with 1/d(ay) or 3/d(ay) limt rate value.
not that i really want to log 1 or 3 packets a day, but... looks like a
bug to me.
eris:~# iptables -V
iptables v1.3.6
debian etch:
eris:~# uname -a
Linux eris 2.6.18-6-686 #1 SMP Mon Oct 13 16:13:09 UTC 2008 i686 GNU/Linux
Also the man page says:
A rule using this extension will match until this limit is reached
(unless the `!' flag is used).
well...:
eris:~# iptables -A INPUT -i eth2 -s 123.123.123.123 -m limit ! --limit
3/s -j LOG
iptables v1.3.6: limit does not support invert
Try `iptables -h' or 'iptables --help' for more information.
eris:~#
eris:~# iptables -A INPUT -i eth2 -s 123.123.123.123 -m limit --limit !
3/s -j LOG
iptables v1.3.6: limit does not support invert
Try `iptables -h' or 'iptables --help' for more information.
eris:~#
Either the man page, or the program is wrong. Or does the man page refer
to negating any other value in the rule? I could not think about
anything reverting the limit match.
Please correct me if i'm wrong!
If this should be bug reported, what would I need to do?
Maybe this is fixed in newer releases of iptables. I don't know.
Good day
Mart
next reply other threads:[~2008-12-17 9:44 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-17 9:44 Mart Frauenlob [this message]
2008-12-17 15:02 ` Bug in limit match? Payam Chychi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4948C9F9.5010803@chello.at \
--to=mart.frauenlob@chello.at \
--cc=netfilter@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox