linux/include/uapi/linux/netfilter_ipv6
Florian Westphal 121d1e0941 netfilter: ipv6: add getsockopt to retrieve origdst
userspace can query the original ipv4 destination address of a REDIRECTed
connection via
getsockopt(m_sock, SOL_IP, SO_ORIGINAL_DST, &m_server_addr, &addrsize)

but for ipv6 no such option existed.

This adds getsockopt(..., IPPROTO_IPV6, IP6T_SO_ORIGINAL_DST, ...).

Without this, userspace needs to parse /proc or use ctnetlink, which
appears to be overkill.

This uses option number 80 for IP6T_SO_ORIGINAL_DST, which is spare,
to use the same number we use in the IPv4 socket option SO_ORIGINAL_DST.

Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
2012-11-02 12:26:32 +01:00
..
Kbuild
ip6_tables.h netfilter: ipv6: add getsockopt to retrieve origdst 2012-11-02 12:26:32 +01:00
ip6t_HL.h
ip6t_LOG.h
ip6t_NPT.h
ip6t_REJECT.h
ip6t_ah.h
ip6t_frag.h
ip6t_hl.h
ip6t_ipv6header.h
ip6t_mh.h
ip6t_opts.h
ip6t_rt.h