Re: [PATCH 3/4 v2] libnftnl: set: Implement new buffer of TLV objects.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Florian,

On Tue, Jan 05, 2016 at 02:28:47PM +0100, Florian Westphal wrote:
> Carlos Falgueras García <carlosfg@xxxxxxxxxx> wrote:
> > These functions allow create a buffer (nftnl_attrbuf) of TLV objects
> > (nftnl_attr). It is inspired in libmnl/src/attr.c.
> 
> It would be nice to get a summary on how this going to be used.
> 
> At this time I don't understand why nftnl needs this api,
> the kernel doesn't enforce any format on this data (good), so we cannot
> rely on it having any specific format when reading arbitrary userdata
> (added by someone else).

Since the introduction of concatenations, the NFTA_SET_DATA_TYPE
attribute became too short to store the datatype information that we
need to keep to interpret the elements datatypes. This field is very
useful when dumping things from the kernel, to interpret them given
that the kernel side has no understanding on the byte semantics that
it is storing.

Another problem is that we also don't want to have fixed integer
datatypes since we can also have header bitfields into sets, this
would also explode in number when consider host and network byteorder
variants, so the idea is to store this in flexible TLV format in the
set userdata area.
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Netfitler Users]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux