fabien.marotte at mindspeed
Sep 17, 2007, 12:58 AM
Post #1 of 1
libnfconntrack and ipv6 addresses
I am developping an application that uses libnfconntrack. I currently try
to get the ipv6 addresses from a conntrack.
However it seems it is not possible to get the ipv6 address (that is 128
bits) from the conntrack since the available getter functions are
nfct_get_attr_u32, nfct_get_attr_u16 and nfct_get_attr_u8.
First question, Is there a way to get the ipv6 addresses with the current
In case it is not possible, I am going to add the getter for that.
I see several possibilities:
Add a nfct_get_attr_u128 --> will return a pointer on a "malloced"
structure, not very good I think. Who will free the structure ?
Add a nfct_get_attr_ipv6 --> Will return struct in6_addr , but not very
Remove const from nfct_get_attr in order to be available by the
applications that use the library, Not very good since the application
will have access to a pointer to the conntrack memory space.
What is the better way, according to you to do that ?
+33 (0)4 93 00 69 09