Home | History | Annotate | Download | only in netfilter
      1 /****************************************************************************
      2  ****************************************************************************
      3  ***
      4  ***   This header was automatically generated from a Linux kernel header
      5  ***   of the same name, to make information necessary for userspace to
      6  ***   call into the kernel available to libc.  It contains only constants,
      7  ***   structures, and macros generated from the original header, and thus,
      8  ***   contains no copyrightable information.
      9  ***
     10  ***   To edit the content of this header, modify the corresponding
     11  ***   source file (e.g. under external/kernel-headers/original/) then
     12  ***   run bionic/libc/kernel/tools/update_all.py
     13  ***
     14  ***   Any manual change here will be lost the next time this script will
     15  ***   be run. You've been warned!
     16  ***
     17  ****************************************************************************
     18  ****************************************************************************/
     19 #ifndef _NETFILTER_NF_NAT_H
     20 #define _NETFILTER_NF_NAT_H
     21 #include <linux/netfilter.h>
     22 #include <linux/netfilter/nf_conntrack_tuple_common.h>
     23 #define NF_NAT_RANGE_MAP_IPS (1 << 0)
     24 #define NF_NAT_RANGE_PROTO_SPECIFIED (1 << 1)
     25 #define NF_NAT_RANGE_PROTO_RANDOM (1 << 2)
     26 #define NF_NAT_RANGE_PERSISTENT (1 << 3)
     27 #define NF_NAT_RANGE_PROTO_RANDOM_FULLY (1 << 4)
     28 #define NF_NAT_RANGE_PROTO_OFFSET (1 << 5)
     29 #define NF_NAT_RANGE_PROTO_RANDOM_ALL (NF_NAT_RANGE_PROTO_RANDOM | NF_NAT_RANGE_PROTO_RANDOM_FULLY)
     30 #define NF_NAT_RANGE_MASK (NF_NAT_RANGE_MAP_IPS | NF_NAT_RANGE_PROTO_SPECIFIED | NF_NAT_RANGE_PROTO_RANDOM | NF_NAT_RANGE_PERSISTENT | NF_NAT_RANGE_PROTO_RANDOM_FULLY | NF_NAT_RANGE_PROTO_OFFSET)
     31 struct nf_nat_ipv4_range {
     32   unsigned int flags;
     33   __be32 min_ip;
     34   __be32 max_ip;
     35   union nf_conntrack_man_proto min;
     36   union nf_conntrack_man_proto max;
     37 };
     38 struct nf_nat_ipv4_multi_range_compat {
     39   unsigned int rangesize;
     40   struct nf_nat_ipv4_range range[1];
     41 };
     42 struct nf_nat_range {
     43   unsigned int flags;
     44   union nf_inet_addr min_addr;
     45   union nf_inet_addr max_addr;
     46   union nf_conntrack_man_proto min_proto;
     47   union nf_conntrack_man_proto max_proto;
     48 };
     49 struct nf_nat_range2 {
     50   unsigned int flags;
     51   union nf_inet_addr min_addr;
     52   union nf_inet_addr max_addr;
     53   union nf_conntrack_man_proto min_proto;
     54   union nf_conntrack_man_proto max_proto;
     55   union nf_conntrack_man_proto base_proto;
     56 };
     57 #endif
     58