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 _UAPI_ARPTABLES_H 20 #define _UAPI_ARPTABLES_H 21 #include <linux/types.h> 22 #include <linux/compiler.h> 23 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 24 #include <linux/if.h> 25 #include <linux/netfilter_arp.h> 26 #include <linux/netfilter/x_tables.h> 27 #define ARPT_FUNCTION_MAXNAMELEN XT_FUNCTION_MAXNAMELEN 28 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 29 #define ARPT_TABLE_MAXNAMELEN XT_TABLE_MAXNAMELEN 30 #define arpt_entry_target xt_entry_target 31 #define arpt_standard_target xt_standard_target 32 #define arpt_error_target xt_error_target 33 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 34 #define ARPT_CONTINUE XT_CONTINUE 35 #define ARPT_RETURN XT_RETURN 36 #define arpt_counters_info xt_counters_info 37 #define arpt_counters xt_counters 38 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 39 #define ARPT_STANDARD_TARGET XT_STANDARD_TARGET 40 #define ARPT_ERROR_TARGET XT_ERROR_TARGET 41 #define ARPT_ENTRY_ITERATE(entries,size,fn,args...) XT_ENTRY_ITERATE(struct arpt_entry, entries, size, fn, ##args) 42 #define ARPT_DEV_ADDR_LEN_MAX 16 43 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 44 struct arpt_devaddr_info { 45 char addr[ARPT_DEV_ADDR_LEN_MAX]; 46 char mask[ARPT_DEV_ADDR_LEN_MAX]; 47 }; 48 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 49 struct arpt_arp { 50 struct in_addr src, tgt; 51 struct in_addr smsk, tmsk; 52 __u8 arhln, arhln_mask; 53 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 54 struct arpt_devaddr_info src_devaddr; 55 struct arpt_devaddr_info tgt_devaddr; 56 __be16 arpop, arpop_mask; 57 __be16 arhrd, arhrd_mask; 58 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 59 __be16 arpro, arpro_mask; 60 char iniface[IFNAMSIZ], outiface[IFNAMSIZ]; 61 unsigned char iniface_mask[IFNAMSIZ], outiface_mask[IFNAMSIZ]; 62 __u8 flags; 63 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 64 __u16 invflags; 65 }; 66 #define ARPT_F_MASK 0x00 67 #define ARPT_INV_VIA_IN 0x0001 68 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 69 #define ARPT_INV_VIA_OUT 0x0002 70 #define ARPT_INV_SRCIP 0x0004 71 #define ARPT_INV_TGTIP 0x0008 72 #define ARPT_INV_SRCDEVADDR 0x0010 73 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 74 #define ARPT_INV_TGTDEVADDR 0x0020 75 #define ARPT_INV_ARPOP 0x0040 76 #define ARPT_INV_ARPHRD 0x0080 77 #define ARPT_INV_ARPPRO 0x0100 78 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 79 #define ARPT_INV_ARPHLN 0x0200 80 #define ARPT_INV_MASK 0x03FF 81 struct arpt_entry { 82 struct arpt_arp arp; 83 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 84 __u16 target_offset; 85 __u16 next_offset; 86 unsigned int comefrom; 87 struct xt_counters counters; 88 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 89 unsigned char elems[0]; 90 }; 91 #define ARPT_BASE_CTL 96 92 #define ARPT_SO_SET_REPLACE (ARPT_BASE_CTL) 93 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 94 #define ARPT_SO_SET_ADD_COUNTERS (ARPT_BASE_CTL + 1) 95 #define ARPT_SO_SET_MAX ARPT_SO_SET_ADD_COUNTERS 96 #define ARPT_SO_GET_INFO (ARPT_BASE_CTL) 97 #define ARPT_SO_GET_ENTRIES (ARPT_BASE_CTL + 1) 98 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 99 #define ARPT_SO_GET_REVISION_TARGET (ARPT_BASE_CTL + 3) 100 #define ARPT_SO_GET_MAX (ARPT_SO_GET_REVISION_TARGET) 101 struct arpt_getinfo { 102 char name[XT_TABLE_MAXNAMELEN]; 103 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 104 unsigned int valid_hooks; 105 unsigned int hook_entry[NF_ARP_NUMHOOKS]; 106 unsigned int underflow[NF_ARP_NUMHOOKS]; 107 unsigned int num_entries; 108 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 109 unsigned int size; 110 }; 111 struct arpt_replace { 112 char name[XT_TABLE_MAXNAMELEN]; 113 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 114 unsigned int valid_hooks; 115 unsigned int num_entries; 116 unsigned int size; 117 unsigned int hook_entry[NF_ARP_NUMHOOKS]; 118 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 119 unsigned int underflow[NF_ARP_NUMHOOKS]; 120 unsigned int num_counters; 121 struct xt_counters __user * counters; 122 struct arpt_entry entries[0]; 123 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 124 }; 125 struct arpt_get_entries { 126 char name[XT_TABLE_MAXNAMELEN]; 127 unsigned int size; 128 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 129 struct arpt_entry entrytable[0]; 130 }; 131 #endif 132