xt_policy.h revision 106b3a8a7dc03c19a45e322de425ac56aafac358
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 _XT_POLICY_H
20#define _XT_POLICY_H
21#include <linux/types.h>
22#include <linux/in.h>
23/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
24#include <linux/in6.h>
25#define XT_POLICY_MAX_ELEM 4
26enum xt_policy_flags {
27  XT_POLICY_MATCH_IN = 0x1,
28/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
29  XT_POLICY_MATCH_OUT = 0x2,
30  XT_POLICY_MATCH_NONE = 0x4,
31  XT_POLICY_MATCH_STRICT = 0x8,
32};
33/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
34enum xt_policy_modes {
35  XT_POLICY_MODE_TRANSPORT,
36  XT_POLICY_MODE_TUNNEL
37};
38/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
39struct xt_policy_spec {
40  __u8 saddr : 1, daddr : 1, proto : 1, mode : 1, spi : 1, reqid : 1;
41};
42union xt_policy_addr {
43/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
44  struct in_addr a4;
45  struct in6_addr a6;
46};
47struct xt_policy_elem {
48/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
49  union {
50    struct {
51      union xt_policy_addr saddr;
52      union xt_policy_addr smask;
53/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
54      union xt_policy_addr daddr;
55      union xt_policy_addr dmask;
56    };
57  };
58/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
59  __be32 spi;
60  __u32 reqid;
61  __u8 proto;
62  __u8 mode;
63/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
64  struct xt_policy_spec match;
65  struct xt_policy_spec invert;
66};
67struct xt_policy_info {
68/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
69  struct xt_policy_elem pol[XT_POLICY_MAX_ELEM];
70  __u16 flags;
71  __u16 len;
72};
73/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
74#endif
75