1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ |
2 | /* |
3 | * ebt_ip |
4 | * |
5 | * Authors: |
6 | * Bart De Schuymer <bart.de.schuymer@pandora.be> |
7 | * |
8 | * April, 2002 |
9 | * |
10 | * Changes: |
11 | * added ip-sport and ip-dport |
12 | * Innominate Security Technologies AG <mhopf@innominate.com> |
13 | * September, 2002 |
14 | */ |
15 | |
16 | #ifndef __LINUX_BRIDGE_EBT_IP_H |
17 | #define __LINUX_BRIDGE_EBT_IP_H |
18 | |
19 | #include <linux/types.h> |
20 | |
21 | #define EBT_IP_SOURCE 0x01 |
22 | #define EBT_IP_DEST 0x02 |
23 | #define EBT_IP_TOS 0x04 |
24 | #define EBT_IP_PROTO 0x08 |
25 | #define EBT_IP_SPORT 0x10 |
26 | #define EBT_IP_DPORT 0x20 |
27 | #define EBT_IP_ICMP 0x40 |
28 | #define EBT_IP_IGMP 0x80 |
29 | #define EBT_IP_MASK (EBT_IP_SOURCE | EBT_IP_DEST | EBT_IP_TOS | EBT_IP_PROTO |\ |
30 | EBT_IP_SPORT | EBT_IP_DPORT | EBT_IP_ICMP | EBT_IP_IGMP) |
31 | #define EBT_IP_MATCH "ip" |
32 | |
33 | /* the same values are used for the invflags */ |
34 | struct ebt_ip_info { |
35 | __be32 saddr; |
36 | __be32 daddr; |
37 | __be32 smsk; |
38 | __be32 dmsk; |
39 | __u8 tos; |
40 | __u8 protocol; |
41 | __u8 bitmask; |
42 | __u8 invflags; |
43 | union { |
44 | __u16 sport[2]; |
45 | __u8 icmp_type[2]; |
46 | __u8 igmp_type[2]; |
47 | }; |
48 | union { |
49 | __u16 dport[2]; |
50 | __u8 icmp_code[2]; |
51 | }; |
52 | }; |
53 | |
54 | #endif |
55 | |