From: Munteanu Eduard Gabriel <maxdamage@aladin.ro>
To: netfilter-devel@lists.netfilter.org
Subject: Multiple targets for REDIRECT & friends
Date: Sun, 21 Aug 2005 13:40:22 +0000 [thread overview]
Message-ID: <43088446.6000303@aladin.ro> (raw)
I'm looking to contribute this to netfilter.
Right now, ip_nat_multi_range is typedeffed (as a macro, though) to
ip_nat_multi_range_compat. I think it will be okay to make
ip_nat_multi_range be a linked list, but eliminate rangesize member.
Older targets will preserve ip_nat_multi_range_compat, while those which
support multiple targets will use this new structure.
However, there is a problem and I need your help. Linked lists need
linux/list.h, but that one checks for __KERNEL__ and backfires when you
need to compile iptables. As I see it, there are two solutions for that:
1) Using a "ip_nat_multi_range *next" pointer instead of using kernel's
list_head. This fulfills all requirements for my patch, but I don't know
if it's okay for kernel devels to use nonstandard lists (though there is
no single-linked list implementation in kernel AFAIK).
2) Providing different linux/list.h in iptables package. This will bring
up future API compatibility issues, so we need to maintain that header
and insert checks for kernel version.
3) Modify linux/list.h so that it doesn't check anymore for __KERNEL__.
Kernel devels won't be happy about this AFAICS.
If you have any other advice regarding my ideas on how to implement
this, feel free to ask. I already came up with a patch for iptables'
REDIRECT target, it just needs to have that linked list thingy filled up.
next reply other threads:[~2005-08-21 13:40 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-08-21 13:40 Munteanu Eduard Gabriel [this message]
2005-08-23 2:41 ` Multiple targets for REDIRECT & friends Munteanu Eduard Gabriel
-- strict thread matches above, loose matches on Subject: below --
2005-08-21 20:23 Munteanu Eduard Gabriel
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=43088446.6000303@aladin.ro \
--to=maxdamage@aladin.ro \
--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.