Hello everybody,
I try to write a C code in userspace which must check a ipv6 packet header. If the the ipv6 header contains a HOP by HOP options(meaning next header is hop by hop header ), i want to store this hop by hop options data else (no hop hop header) i want to include a stored options data in the ipv6 header.
I use libnetfilter_queue to intercept packet and nfq_verdict t send them after.
My current code can intercept packet, check it to get ipv6 header and print ipsrc, ipdst and ip6_nxt.(ifip6_nxt==0 the header contains hop by hop header, else no header).
But I don't understant how i can store a hop by hop options data or set them to another ipv6 header before sending the packets.
Can someone help me. Thank you in advance.