1#ifndef _NF_OSF_H
2#define _NF_OSF_H
3
4#include <linux/types.h>
5
6#define MAXGENRELEN 32
7
8#define NF_OSF_GENRE (1 << 0)
9#define NF_OSF_TTL (1 << 1)
10#define NF_OSF_LOG (1 << 2)
11#define NF_OSF_INVERT (1 << 3)
12
13#define NF_OSF_LOGLEVEL_ALL 0
14#define NF_OSF_LOGLEVEL_FIRST 1
15#define NF_OSF_LOGLEVEL_ALL_KNOWN 2
16
17#define NF_OSF_TTL_TRUE 0
18
19
20#define NF_OSF_TTL_NOCHECK 2
21
22
23
24
25
26struct nf_osf_wc {
27 __u32 wc;
28 __u32 val;
29};
30
31
32
33
34struct nf_osf_opt {
35 __u16 kind, length;
36 struct nf_osf_wc wc;
37};
38
39struct nf_osf_info {
40 char genre[MAXGENRELEN];
41 __u32 len;
42 __u32 flags;
43 __u32 loglevel;
44 __u32 ttl;
45};
46
47struct nf_osf_user_finger {
48 struct nf_osf_wc wss;
49
50 __u8 ttl, df;
51 __u16 ss, mss;
52 __u16 opt_num;
53
54 char genre[MAXGENRELEN];
55 char version[MAXGENRELEN];
56 char subtype[MAXGENRELEN];
57
58
59 struct nf_osf_opt opt[MAX_IPOPTLEN];
60};
61
62struct nf_osf_nlmsg {
63 struct nf_osf_user_finger f;
64 struct iphdr ip;
65 struct tcphdr tcp;
66};
67
68
69enum iana_options {
70 OSFOPT_EOL = 0,
71 OSFOPT_NOP,
72 OSFOPT_MSS,
73 OSFOPT_WSO,
74 OSFOPT_SACKP,
75 OSFOPT_SACK,
76 OSFOPT_ECHO,
77 OSFOPT_ECHOREPLY,
78 OSFOPT_TS,
79 OSFOPT_POCP,
80 OSFOPT_POSP,
81
82
83 OSFOPT_EMPTY = 255,
84};
85
86#endif
87