Home | History | Annotate | Download | only in netfilter_ipv6
      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 _IP6_TABLES_H
     20 #define _IP6_TABLES_H
     21 #include <linux/compiler.h>
     22 #include <linux/netfilter_ipv6.h>
     23 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     24 #include <linux/netfilter/x_tables.h>
     25 #define IP6T_FUNCTION_MAXNAMELEN XT_FUNCTION_MAXNAMELEN
     26 #define IP6T_TABLE_MAXNAMELEN XT_TABLE_MAXNAMELEN
     27 #define ip6t_match xt_match
     28 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     29 #define ip6t_target xt_target
     30 #define ip6t_table xt_table
     31 #define ip6t_get_revision xt_get_revision
     32 struct ip6t_ip6 {
     33 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     34  struct in6_addr src, dst;
     35  struct in6_addr smsk, dmsk;
     36  char iniface[IFNAMSIZ], outiface[IFNAMSIZ];
     37  unsigned char iniface_mask[IFNAMSIZ], outiface_mask[IFNAMSIZ];
     38 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     39  u_int16_t proto;
     40  u_int8_t tos;
     41  u_int8_t flags;
     42  u_int8_t invflags;
     43 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     44 };
     45 #define ip6t_entry_match xt_entry_match
     46 #define ip6t_entry_target xt_entry_target
     47 #define ip6t_standard_target xt_standard_target
     48 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     49 #define ip6t_counters xt_counters
     50 #define IP6T_F_PROTO 0x01
     51 #define IP6T_F_TOS 0x02
     52 #define IP6T_F_GOTO 0x04
     53 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     54 #define IP6T_F_MASK 0x07
     55 #define IP6T_INV_VIA_IN 0x01
     56 #define IP6T_INV_VIA_OUT 0x02
     57 #define IP6T_INV_TOS 0x04
     58 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     59 #define IP6T_INV_SRCIP 0x08
     60 #define IP6T_INV_DSTIP 0x10
     61 #define IP6T_INV_FRAG 0x20
     62 #define IP6T_INV_PROTO XT_INV_PROTO
     63 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     64 #define IP6T_INV_MASK 0x7F
     65 struct ip6t_entry
     66 {
     67  struct ip6t_ip6 ipv6;
     68 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     69  unsigned int nfcache;
     70  u_int16_t target_offset;
     71  u_int16_t next_offset;
     72  unsigned int comefrom;
     73 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     74  struct xt_counters counters;
     75  unsigned char elems[0];
     76 };
     77 #define IP6T_BASE_CTL XT_BASE_CTL
     78 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     79 #define IP6T_SO_SET_REPLACE XT_SO_SET_REPLACE
     80 #define IP6T_SO_SET_ADD_COUNTERS XT_SO_SET_ADD_COUNTERS
     81 #define IP6T_SO_SET_MAX XT_SO_SET_MAX
     82 #define IP6T_SO_GET_INFO XT_SO_GET_INFO
     83 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     84 #define IP6T_SO_GET_ENTRIES XT_SO_GET_ENTRIES
     85 #define IP6T_SO_GET_REVISION_MATCH XT_SO_GET_REVISION_MATCH
     86 #define IP6T_SO_GET_REVISION_TARGET XT_SO_GET_REVISION_TARGET
     87 #define IP6T_SO_GET_MAX XT_SO_GET_REVISION_TARGET
     88 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     89 #define IP6T_CONTINUE XT_CONTINUE
     90 #define IP6T_RETURN XT_RETURN
     91 #include <linux/netfilter/xt_tcpudp.h>
     92 #define ip6t_tcp xt_tcp
     93 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     94 #define ip6t_udp xt_udp
     95 #define IP6T_TCP_INV_SRCPT XT_TCP_INV_SRCPT
     96 #define IP6T_TCP_INV_DSTPT XT_TCP_INV_DSTPT
     97 #define IP6T_TCP_INV_FLAGS XT_TCP_INV_FLAGS
     98 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
     99 #define IP6T_TCP_INV_OPTION XT_TCP_INV_OPTION
    100 #define IP6T_TCP_INV_MASK XT_TCP_INV_MASK
    101 #define IP6T_UDP_INV_SRCPT XT_UDP_INV_SRCPT
    102 #define IP6T_UDP_INV_DSTPT XT_UDP_INV_DSTPT
    103 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
    104 #define IP6T_UDP_INV_MASK XT_UDP_INV_MASK
    105 struct ip6t_icmp
    106 {
    107  u_int8_t type;
    108 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
    109  u_int8_t code[2];
    110  u_int8_t invflags;
    111 };
    112 #define IP6T_ICMP_INV 0x01
    113 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
    114 struct ip6t_getinfo
    115 {
    116  char name[IP6T_TABLE_MAXNAMELEN];
    117  unsigned int valid_hooks;
    118 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
    119  unsigned int hook_entry[NF_IP6_NUMHOOKS];
    120  unsigned int underflow[NF_IP6_NUMHOOKS];
    121  unsigned int num_entries;
    122  unsigned int size;
    123 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
    124 };
    125 struct ip6t_replace
    126 {
    127  char name[IP6T_TABLE_MAXNAMELEN];
    128 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
    129  unsigned int valid_hooks;
    130  unsigned int num_entries;
    131  unsigned int size;
    132  unsigned int hook_entry[NF_IP6_NUMHOOKS];
    133 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
    134  unsigned int underflow[NF_IP6_NUMHOOKS];
    135  unsigned int num_counters;
    136  struct xt_counters __user *counters;
    137  struct ip6t_entry entries[0];
    138 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
    139 };
    140 #define ip6t_counters_info xt_counters_info
    141 struct ip6t_get_entries
    142 {
    143 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
    144  char name[IP6T_TABLE_MAXNAMELEN];
    145  unsigned int size;
    146  struct ip6t_entry entrytable[0];
    147 };
    148 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
    149 #define IP6T_STANDARD_TARGET XT_STANDARD_TARGET
    150 #define IP6T_ERROR_TARGET XT_ERROR_TARGET
    151 static __inline__ struct ip6t_entry_target *
    152 ip6t_get_target(struct ip6t_entry *e)
    153 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
    154 {
    155  return (void *)e + e->target_offset;
    156 }
    157 #define IP6T_MATCH_ITERATE(e, fn, args...)  ({   unsigned int __i;   int __ret = 0;   struct ip6t_entry_match *__m;     for (__i = sizeof(struct ip6t_entry);   __i < (e)->target_offset;   __i += __m->u.match_size) {   __m = (void *)(e) + __i;     __ret = fn(__m , ## args);   if (__ret != 0)   break;   }   __ret;  })
    158 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
    159 #define IP6T_ENTRY_ITERATE(entries, size, fn, args...)  ({   unsigned int __i;   int __ret = 0;   struct ip6t_entry *__e;     for (__i = 0; __i < (size); __i += __e->next_offset) {   __e = (void *)(entries) + __i;     __ret = fn(__e , ## args);   if (__ret != 0)   break;   }   __ret;  })
    160 #endif
    161