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/netfilter_arp.h> 25 #include <linux/netfilter/x_tables.h> 26 #define ARPT_FUNCTION_MAXNAMELEN XT_FUNCTION_MAXNAMELEN 27 #define ARPT_TABLE_MAXNAMELEN XT_TABLE_MAXNAMELEN 28 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 29 #define arpt_entry_target xt_entry_target 30 #define arpt_standard_target xt_standard_target 31 #define arpt_error_target xt_error_target 32 #define ARPT_CONTINUE XT_CONTINUE 33 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 34 #define ARPT_RETURN XT_RETURN 35 #define arpt_counters_info xt_counters_info 36 #define arpt_counters xt_counters 37 #define ARPT_STANDARD_TARGET XT_STANDARD_TARGET 38 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 39 #define ARPT_ERROR_TARGET XT_ERROR_TARGET 40 #define ARPT_ENTRY_ITERATE(entries, size, fn, args...) XT_ENTRY_ITERATE(struct arpt_entry, entries, size, fn, ## args) 41 #define ARPT_DEV_ADDR_LEN_MAX 16 42 struct arpt_devaddr_info { 43 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 44 char addr[ARPT_DEV_ADDR_LEN_MAX]; 45 char mask[ARPT_DEV_ADDR_LEN_MAX]; 46 }; 47 struct arpt_arp { 48 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 49 struct in_addr src, tgt; 50 struct in_addr smsk, tmsk; 51 __u8 arhln, arhln_mask; 52 struct arpt_devaddr_info src_devaddr; 53 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 54 struct arpt_devaddr_info tgt_devaddr; 55 __be16 arpop, arpop_mask; 56 __be16 arhrd, arhrd_mask; 57 __be16 arpro, arpro_mask; 58 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 59 char iniface[IFNAMSIZ], outiface[IFNAMSIZ]; 60 unsigned char iniface_mask[IFNAMSIZ], outiface_mask[IFNAMSIZ]; 61 __u8 flags; 62 __u16 invflags; 63 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 64 }; 65 #define ARPT_F_MASK 0x00 66 #define ARPT_INV_VIA_IN 0x0001 67 #define ARPT_INV_VIA_OUT 0x0002 68 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 69 #define ARPT_INV_SRCIP 0x0004 70 #define ARPT_INV_TGTIP 0x0008 71 #define ARPT_INV_SRCDEVADDR 0x0010 72 #define ARPT_INV_TGTDEVADDR 0x0020 73 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 74 #define ARPT_INV_ARPOP 0x0040 75 #define ARPT_INV_ARPHRD 0x0080 76 #define ARPT_INV_ARPPRO 0x0100 77 #define ARPT_INV_ARPHLN 0x0200 78 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 79 #define ARPT_INV_MASK 0x03FF 80 struct arpt_entry 81 { 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