Merge 13831:14550 from trunk
[reactos.git] / reactos / include / tcpmisc.h
1 #ifndef TCPMISC_H
2 #define TCPMISC_H
3
4 #define IF_MIB_STATS_ID 1
5 #define MAX_PHYSADDR_SIZE 8
6 #define MAX_IFDESCR_LEN 256
7
8 /* ID to use for requesting an IFEntry for an interface */
9 #define IF_MIB_STATS_ID 1
10
11 /* ID to use for requesting an IPSNMPInfo for an interface */
12 #define IP_MIB_STATS_ID 1
13
14 /* ID to use for requesting the route table */
15 #define IP_MIB_ROUTETABLE_ENTRY_ID 0x101
16 #define IP_MIB_ADDRTABLE_ENTRY_ID 0x102
17
18 typedef struct IFEntry {
19 ULONG if_index;
20 ULONG if_type;
21 ULONG if_mtu;
22 ULONG if_speed;
23 ULONG if_physaddrlen;
24 UCHAR if_physaddr[MAX_PHYSADDR_SIZE];
25 ULONG if_adminstatus;
26 ULONG if_operstatus;
27 ULONG if_lastchange;
28 ULONG if_inoctets;
29 ULONG if_inucastpkts;
30 ULONG if_innucastpkts;
31 ULONG if_indiscards;
32 ULONG if_inerrors;
33 ULONG if_inunknownprotos;
34 ULONG if_outoctets;
35 ULONG if_outucastpkts;
36 ULONG if_outnucastpkts;
37 ULONG if_outdiscards;
38 ULONG if_outerrors;
39 ULONG if_outqlen;
40 ULONG if_descrlen;
41 UCHAR if_descr[1];
42 } IFEntry;
43
44 // As in the mib from RFC 1213
45
46 typedef struct _IPRouteEntry {
47 ULONG ire_dest;
48 ULONG ire_index; //matches if_index in IFEntry and iae_index in IPAddrEntry
49 ULONG ire_metric1;
50 ULONG ire_metric2;
51 ULONG ire_metric3;
52 ULONG ire_metric4;
53 ULONG ire_gw;
54 ULONG ire_type;
55 ULONG ire_proto;
56 ULONG ire_age;
57 ULONG ire_mask;
58 ULONG ire_metric5;
59 ULONG ire_info;
60 } IPRouteEntry;
61
62 typedef struct _IPAddrEntry {
63 ULONG iae_addr;
64 ULONG iae_index;
65 ULONG iae_mask;
66 ULONG iae_bcastaddr;
67 ULONG iae_reasmsize;
68 ULONG iae_context;
69 ULONG iae_pad;
70 } IPAddrEntry;
71
72 typedef struct _IPSNMPInfo {
73 ULONG ipsi_index;
74 ULONG ipsi_forwarding;
75 ULONG ipsi_defaultttl;
76 ULONG ipsi_inreceives;
77 ULONG ipsi_inhdrerrors;
78 ULONG ipsi_inaddrerrors;
79 ULONG ipsi_inunknownprotos;
80 ULONG ipsi_indiscards;
81 ULONG ipsi_indelivers;
82 ULONG ipsi_outrequests;
83 ULONG ipsi_routingdiscards;
84 ULONG ipsi_outdiscards;
85 ULONG ipsi_outnoroutes;
86 ULONG ipsi_reasmtimeout;
87 ULONG ipsi_reasmreqds;
88 ULONG ipsi_reasmoks;
89 ULONG ipsi_reasmfails;
90 ULONG ipsi_fragoks;
91 ULONG ipsi_fragfails;
92 ULONG ipsi_fragcreates;
93 ULONG ipsi_numif;
94 ULONG ipsi_numaddr;
95 ULONG ipsi_numroutes;
96 } IPSNMPInfo;
97
98 #endif /* TCPMISC_H */