All of lore.kernel.org
 help / color / mirror / Atom feed
From: Patrick McHardy <kaber@trash.net>
To: Pablo Neira Ayuso <pablo@netfilter.org>
Cc: Netfilter Development Mailinglist <netfilter-devel@lists.netfilter.org>
Subject: Re: NFNL_NFA_NEST
Date: Thu, 22 Mar 2007 14:29:56 +0100	[thread overview]
Message-ID: <460284D4.30709@trash.net> (raw)
In-Reply-To: <46028242.4090609@netfilter.org>

Pablo Neira Ayuso wrote:
>>>I'm using this bit to convert attribute headers from host byte order to
>>>network byte order in conntrackd. I'm unsure about how I would do the
>>>conversion if we remove such bit.
>>
>>That was the original idea behind it. But where do we use host byte
>>order?
> 
> 
> Currently, some parts of the nfnetlink message are in host byte order
> and some in network byte order. For example, the netlink header and the
> attribute header (TL) are un host byte order, but the attribute values
> (V) are in network byte order.


Right.

> Having a look at the code, if we decide to remove the nested bit,
> conntrackd will have to parse the message coming from the kernel, put in
> a nf_conntrack object and generate a new message un network byte order.
> Moreover, I'll have to extend libnfnetlink and libnetfilter_conntrack to
> indicate the byte order of a certain nfnetlink message, since without
> the nested bit, I can't do proxying anymore.


Not really. The NEST bit allows to walk nested structures without
being aware of the structure. So all you need to do is make it aware
of which attributes are nested - something you need anyway for
parsing I suppose.

The byteorder is already clear, all netlink header values are in
host byte order, all attributes in network byte order.

> I'm fine with using the new netlink infrastructure. We could remove the
> nested bit, release new libraries that don't send it to kernel anymore
> and keep the old nfnetlink code that understand the nest bit thing for
> quite some time. Thus, doing the port to the new infrastructure later.


Yes, we should probably wait for at least one year.

  reply	other threads:[~2007-03-22 13:29 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-03-21  5:08 NFNL_NFA_NEST Patrick McHardy
2007-03-21 10:04 ` NFNL_NFA_NEST Jozsef Kadlecsik
2007-03-21 10:13   ` NFNL_NFA_NEST Patrick McHardy
2007-03-21 10:39     ` NFNL_NFA_NEST Jozsef Kadlecsik
2007-03-21 22:54 ` NFNL_NFA_NEST Pablo Neira Ayuso
2007-03-22 11:00   ` NFNL_NFA_NEST Patrick McHardy
2007-03-22 13:18     ` NFNL_NFA_NEST Pablo Neira Ayuso
2007-03-22 13:29       ` Patrick McHardy [this message]
2007-03-22 16:44         ` NFNL_NFA_NEST Pablo Neira Ayuso
2007-03-22 17:01           ` NFNL_NFA_NEST Patrick McHardy
2007-03-23 12:18             ` NFNL_NFA_NEST Pablo Neira Ayuso
2007-03-23 12:55               ` NFNL_NFA_NEST Pablo Neira Ayuso
2007-03-23 13:01                 ` NFNL_NFA_NEST Patrick McHardy
2007-03-23 13:00               ` NFNL_NFA_NEST Patrick McHardy
2007-03-23 17:37                 ` NFNL_NFA_NEST Pablo Neira Ayuso
2007-03-24 10:49                   ` NFNL_NFA_NEST Patrick McHardy
2007-03-24 11:30                     ` NFNL_NFA_NEST Pablo Neira Ayuso
2007-03-24 14:37                       ` NFNL_NFA_NEST Patrick McHardy

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=460284D4.30709@trash.net \
    --to=kaber@trash.net \
    --cc=netfilter-devel@lists.netfilter.org \
    --cc=pablo@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.