| 1 | /* $Id: ipexport.h,v 1.1 2000-05-19 18:44:45 jeroen Exp $ */ | 
|---|
| 2 |  | 
|---|
| 3 | /* IPEXPORT.H */ | 
|---|
| 4 |  | 
|---|
| 5 | #ifndef IP_EXPORT_H | 
|---|
| 6 | #define IP_EXPORT_H | 
|---|
| 7 |  | 
|---|
| 8 | typedef ULONG  IPAddr; | 
|---|
| 9 | typedef ULONG  IPMask; | 
|---|
| 10 | typedef ULONG  IP_STATUS; | 
|---|
| 11 |  | 
|---|
| 12 | typedef struct ip_option_information { | 
|---|
| 13 | u_char      Ttl; | 
|---|
| 14 | u_char      Tos; | 
|---|
| 15 | u_char      Flags; | 
|---|
| 16 | u_char      OptionsSize; | 
|---|
| 17 | u_char     *OptionsData; | 
|---|
| 18 | } IP_OPTION_INFORMATION, *PIP_OPTION_INFORMATION; | 
|---|
| 19 |  | 
|---|
| 20 | typedef struct icmp_echo_reply { | 
|---|
| 21 | IPAddr                        Address; | 
|---|
| 22 | u_long                        Status; | 
|---|
| 23 | u_long                        RoundTripTime; | 
|---|
| 24 | u_short                       DataSize; | 
|---|
| 25 | u_short                       Reserved; | 
|---|
| 26 | void                         *Data; | 
|---|
| 27 | struct ip_option_information  Options; | 
|---|
| 28 | } ICMP_ECHO_REPLY, *PICMP_ECHO_REPLY; | 
|---|
| 29 |  | 
|---|
| 30 | #define IP_STATUS_BASE              11000 | 
|---|
| 31 |  | 
|---|
| 32 | #define IP_SUCCESS                  0 | 
|---|
| 33 | #define IP_BUF_TOO_SMALL            (IP_STATUS_BASE + 1) | 
|---|
| 34 | #define IP_DEST_NET_UNREACHABLE     (IP_STATUS_BASE + 2) | 
|---|
| 35 | #define IP_DEST_HOST_UNREACHABLE    (IP_STATUS_BASE + 3) | 
|---|
| 36 | #define IP_DEST_PROT_UNREACHABLE    (IP_STATUS_BASE + 4) | 
|---|
| 37 | #define IP_DEST_PORT_UNREACHABLE    (IP_STATUS_BASE + 5) | 
|---|
| 38 | #define IP_NO_RESOURCES             (IP_STATUS_BASE + 6) | 
|---|
| 39 | #define IP_BAD_OPTION               (IP_STATUS_BASE + 7) | 
|---|
| 40 | #define IP_HW_ERROR                 (IP_STATUS_BASE + 8) | 
|---|
| 41 | #define IP_PACKET_TOO_BIG           (IP_STATUS_BASE + 9) | 
|---|
| 42 | #define IP_REQ_TIMED_OUT            (IP_STATUS_BASE + 10) | 
|---|
| 43 | #define IP_BAD_REQ                  (IP_STATUS_BASE + 11) | 
|---|
| 44 | #define IP_BAD_ROUTE                (IP_STATUS_BASE + 12) | 
|---|
| 45 | #define IP_TTL_EXPIRED_TRANSIT      (IP_STATUS_BASE + 13) | 
|---|
| 46 | #define IP_TTL_EXPIRED_REASSEM      (IP_STATUS_BASE + 14) | 
|---|
| 47 | #define IP_PARAM_PROBLEM            (IP_STATUS_BASE + 15) | 
|---|
| 48 | #define IP_SOURCE_QUENCH            (IP_STATUS_BASE + 16) | 
|---|
| 49 | #define IP_OPTION_TOO_BIG           (IP_STATUS_BASE + 17) | 
|---|
| 50 | #define IP_BAD_DESTINATION          (IP_STATUS_BASE + 18) | 
|---|
| 51 | #define IP_ADDR_DELETED             (IP_STATUS_BASE + 19) | 
|---|
| 52 | #define IP_SPEC_MTU_CHANGE          (IP_STATUS_BASE + 20) | 
|---|
| 53 | #define IP_MTU_CHANGE               (IP_STATUS_BASE + 21) | 
|---|
| 54 | #define IP_UNLOAD                   (IP_STATUS_BASE + 22) | 
|---|
| 55 | #define IP_ADDR_ADDED               (IP_STATUS_BASE + 23) | 
|---|
| 56 | #define IP_GENERAL_FAILURE          (IP_STATUS_BASE + 50) | 
|---|
| 57 | #define MAX_IP_STATUS                IP_GENERAL_FAILURE | 
|---|
| 58 | #define IP_PENDING                  (IP_STATUS_BASE + 255) | 
|---|
| 59 |  | 
|---|
| 60 |  | 
|---|
| 61 | #define IP_FLAG_DF                  0x2 | 
|---|
| 62 |  | 
|---|
| 63 | #define IP_OPT_EOL                  0 | 
|---|
| 64 | #define IP_OPT_NOP                  1 | 
|---|
| 65 | #define IP_OPT_SECURITY             0x82 | 
|---|
| 66 | #define IP_OPT_LSRR                 0x83 | 
|---|
| 67 | #define IP_OPT_SSRR                 0x89 | 
|---|
| 68 | #define IP_OPT_RR                   0x7 | 
|---|
| 69 | #define IP_OPT_TS                   0x44 | 
|---|
| 70 | #define IP_OPT_SID                  0x88 | 
|---|
| 71 |  | 
|---|
| 72 | #define MAX_OPT_SIZE                40 | 
|---|
| 73 |  | 
|---|
| 74 | #endif                                 /* IP_EXPORT_H                      */ | 
|---|