History

netfilter: nf_tables: Add support for IPv6 NAT

This patch generalizes the NAT expression to support both IPv4 and IPv6 using the existing IPv4/IPv6 NAT infrastructure. This also adds the NAT chain type for IPv6. This patch collapses the following patches that were posted to the netfilter-devel mailing list, from Tomasz: * nf_tables: Change NFTA_NAT_ attributes to better semantic significance * nf_tables: Split IPv4 NAT into NAT expression and IPv4 NAT chain * nf_tables: Add support for IPv6 NAT expression * nf_tables: Add support for IPv6 NAT chain * nf_tables: Fix up build issue on IPv6 NAT support And, from Pablo Neira Ayuso: * fix missing dependencies in nft_chain_nat

Tomasz Bursztyka committed 13 years ago

Commit eb316281 parent 9ddf6329 files · +457 −162Browse files

Showing the changes to include/uapi/linux (1 of 9 files). Show all

Unified · Split

include/uapi/linux/netfilter/nf_tables.h+10−8
@@ -695,18 +695,20 @@ enum nft_nat_types { · 694 unmodified lines
695695 * enum nft_nat_attributes - nf_tables nat expression netlink attributes
696696 *
697697 * @NFTA_NAT_TYPE: NAT type (NLA_U32: nft_nat_types)
698− * @NFTA_NAT_ADDR_MIN: source register of address range start (NLA_U32: nft_registers)
699− * @NFTA_NAT_ADDR_MAX: source register of address range end (NLA_U32: nft_registers)
700− * @NFTA_NAT_PROTO_MIN: source register of proto range start (NLA_U32: nft_registers)
701− * @NFTA_NAT_PROTO_MAX: source register of proto range end (NLA_U32: nft_registers)
698+ * @NFTA_NAT_FAMILY: NAT family (NLA_U32)
699+ * @NFTA_NAT_REG_ADDR_MIN: source register of address range start (NLA_U32: nft_registers)
700+ * @NFTA_NAT_REG_ADDR_MAX: source register of address range end (NLA_U32: nft_registers)
701+ * @NFTA_NAT_REG_PROTO_MIN: source register of proto range start (NLA_U32: nft_registers)
702+ * @NFTA_NAT_REG_PROTO_MAX: source register of proto range end (NLA_U32: nft_registers)
702703 */
703704 enum nft_nat_attributes {
704705 NFTA_NAT_UNSPEC,
705706 NFTA_NAT_TYPE,
706− NFTA_NAT_ADDR_MIN,
707− NFTA_NAT_ADDR_MAX,
708− NFTA_NAT_PROTO_MIN,
709− NFTA_NAT_PROTO_MAX,
707+ NFTA_NAT_FAMILY,
708+ NFTA_NAT_REG_ADDR_MIN,
709+ NFTA_NAT_REG_ADDR_MAX,
710+ NFTA_NAT_REG_PROTO_MIN,
711+ NFTA_NAT_REG_PROTO_MAX,
710712 __NFTA_NAT_MAX
711713 };
712714 #define NFTA_NAT_MAX (__NFTA_NAT_MAX - 1)