]> granicus.if.org Git - libnl/commit
ct: add ICMPv6 type,code and ID
authorHolger Eitzenberger <holger@eitzenberger.org>
Sun, 31 Mar 2013 19:16:21 +0000 (21:16 +0200)
committerThomas Graf <tgraf@suug.ch>
Tue, 2 Apr 2013 09:42:59 +0000 (11:42 +0200)
commit18152ca91622e11f8ac1e2b9806c134d616fd1fe
tree33c62b17704721ea903a2552472829484aa98af0
parentff567100d6190c9014514f90de522281007c90db
ct: add ICMPv6 type,code and ID

Add ICMPv6 type, code and ID (if set) by using the already available
conntrack atttributes.

Currently the ICMPv6 conntrack objects in libnl are without type, code
and ID.  This e. g. is the output of nl_object_dump() without the patch:

  ipv6-icmp ::1 <-> ::1
  id 0xdd0871f0 family inet6 timeout 30s <NOREPLY,SNAT_INIT,DNAT_INIT>

The attached patch tries to solve that.  It then looks like

  ipv6-icmp ::1 <-> ::1 icmp type 128 code 0 id 28253
  id 0xdf3a11f0 family inet6 timeout 30s <SNAT_INIT,DNAT_INIT>

It is the 'small' approach, because it reuses the existing ICMP
attributes of the conntrack object (currently only used for IPv4).
This way I can avoid to add new _icmp6_get_, _icmp6_set_ and
_icmp6_test_ functions.

Signed-off-by: Holger Eitzenberger <holger@eitzenberger.org>
Signed-off-by: Thomas Graf <tgraf@suug.ch>
lib/netfilter/ct.c