All of lore.kernel.org
 help / color / mirror / Atom feed
From: Patrick McHardy <kaber@trash.net>
To: "Björn Lindström" <bjorn.mailinglist@gmail.com>
Cc: netfilter-devel@lists.netfilter.org
Subject: Re: checking rule specifications in a match
Date: Tue, 20 Jun 2006 15:23:23 +0200	[thread overview]
Message-ID: <4497F6CB.4030600@trash.net> (raw)
In-Reply-To: <44966994.6020402@gmail.com>

Björn Lindström wrote:
> Hi.
> I am writing an iptables match to match the IEC-60870-5-104 protocol.
> I only want this match to be used on tcp packets and therefore I want
> iptables to reject rules if does not specify tcp as the protocol (-p
> tcp). I am currently doing this check in the checkentry function in the
> kernel module. This works but the error message only say "iptables:
> Unknown error 4294967295" if -p tcp is left out. Is it possible to do
> this check any other way to get a more comprehensible error message?

This is probably because you're using a broken version of iptables
userspace. Current kernels allow you to enforce a specific protocol
by setting the .proto field in struct xt_match, which will also handle
inversion correctly and logs a message to the ringbuffer on error.

      reply	other threads:[~2006-06-20 13:23 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-06-19  9:08 checking rule specifications in a match Björn Lindström
2006-06-20 13:23 ` Patrick McHardy [this message]

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=4497F6CB.4030600@trash.net \
    --to=kaber@trash.net \
    --cc=bjorn.mailinglist@gmail.com \
    --cc=netfilter-devel@lists.netfilter.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.