home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Windows Gam…ming Gurus (2nd Edition) / Disc2.iso / vc98 / include / ipxrip.h < prev    next >
C/C++ Source or Header  |  1998-04-25  |  5KB  |  217 lines

  1. /*++
  2.  
  3. Copyright (c) 1995 Microsoft Corporation
  4.  
  5. Module Name:
  6.  
  7.     ipxrip.h
  8.  
  9. Abstract:
  10.  
  11.     This module contains the definitions of the:
  12.  
  13.     interface management APIs structures
  14.     rip MIB management APIs structures
  15.  
  16. Author:
  17.  
  18.     Stefan Solomon  06/30/1995
  19.  
  20. Revision History:
  21.  
  22.  
  23. --*/
  24.  
  25. #ifndef _IPXRIP_
  26. #define _IPXRIP_
  27.  
  28. #include <ipxconst.h>
  29.  
  30. typedef struct _RIP_GLOBAL_INFO {
  31.     DWORD       EventLogMask;
  32. } RIP_GLOBAL_INFO, *PRIP_GLOBAL_INFO;
  33.  
  34. //********************************************************************
  35. //                                     *
  36. //            RIP Configuration Information             *
  37. //                                     *
  38. //********************************************************************
  39.  
  40.  
  41. //*** RIP Interface Only Information ***
  42.  
  43. typedef struct _RIP_IF_INFO {
  44.  
  45.     ULONG        AdminState;  // The desired state of the interface
  46.     ULONG        UpdateMode;    // RIP update mechanism used on this interface
  47.     ULONG        PacketType;  // The RIP packet type used on this interface
  48.     ULONG        Supply; // Send RIP updates on this interface
  49.     ULONG        Listen; // Listen to RIP updates on this interface
  50.     ULONG        PeriodicUpdateInterval; // in seconds - default 60
  51.     ULONG        AgeIntervalMultiplier; // default - 3
  52.  
  53.     } RIP_IF_INFO, *PRIP_IF_INFO;
  54.  
  55. // UpdateMode Values:
  56. //
  57. // This parameter controls the RIP    database update on this interface.
  58. //
  59. // If this is a LAN interface, use IPX_PERIODIC_UPDATE as default.
  60. // If this is a WAN router interface with static routes, use IPX_NO_UPDATE as default.
  61. // If you want to trigger an update on this interface and to keep the data
  62. // as static data, use IPX_AUTO_STATIC value.
  63. // IPX_AUTO_STATIC update can be set only on a WAN interface
  64. //
  65. // PacketType Default Values:
  66. //
  67. // If UpdateMode is set to IPX_NO_UPDATE, this field is meaningless.
  68. // If this is a LAN interface, use IPX_STANDARD_PACKET_TYPE as default.
  69. // If you want reliable delivery of the update data in a triggered update,
  70. // use IPX_RELIABLE_DELIVERY_PACKET_TYPE (this can be set only in combination with
  71. // IPX_AUTO_STATIC_UPDATE in the UpdateMode).
  72.  
  73. // RIP Route Filter Info
  74. //
  75. // These filters apply to routes accepted or advertised by RIP on each interface.
  76.  
  77. typedef struct _RIP_ROUTE_FILTER_INFO {
  78.  
  79.     UCHAR        Network[4];
  80.     UCHAR        Mask[4];
  81.  
  82.     } RIP_ROUTE_FILTER_INFO, *PRIP_ROUTE_FILTER_INFO;
  83.  
  84. //*** RIP Filters Only Information ***
  85. //
  86. //  This header is followed by RIP_ROUTE_FILTER_STRUCTURES in order:
  87. //  First Supply filters
  88. //  Next Listen filters
  89.  
  90. typedef struct _RIP_IF_FILTERS {
  91.  
  92.     ULONG            SupplyFilterAction;
  93.     ULONG            SupplyFilterCount;
  94.     ULONG            ListenFilterAction;
  95.     ULONG            ListenFilterCount;
  96.     RIP_ROUTE_FILTER_INFO   RouteFilter[1];
  97.  
  98.     } RIP_IF_FILTERS, *PRIP_IF_FILTERS;
  99.  
  100. // FilterAction -
  101.  
  102. #define IPX_ROUTE_FILTER_PERMIT        1
  103. #define IPX_ROUTE_FILTER_DENY        2
  104.  
  105. //
  106. //*** RIP Interface Configuration Information ***
  107. //
  108. // This structure is passed in AddInterface and SetInterface Entry Points
  109. //
  110.  
  111. typedef struct _RIP_IF_CONFIG {
  112.  
  113.     RIP_IF_INFO     RipIfInfo;
  114.     RIP_IF_FILTERS  RipIfFilters;
  115.  
  116.     } RIP_IF_CONFIG, *PRIP_IF_CONFIG;
  117.  
  118. // ***********************************************************
  119. // ***                               ***
  120. // ***        RIP MIB Table Identifiers           ***
  121. // ***                               ***
  122. // ***********************************************************
  123.  
  124.  
  125. #define RIP_BASE_ENTRY                0
  126. #define RIP_INTERFACE_TABLE            1
  127.  
  128. //************************************************************
  129. //                                 *
  130. //        RIP MIB Basic Structures             *
  131. //                                 *
  132. //************************************************************
  133.  
  134. //
  135. // RIP MIB Base Entry
  136. //
  137.  
  138. typedef struct _RIPMIB_BASE {
  139.  
  140.     ULONG        RIPOperState;
  141.  
  142.     } RIPMIB_BASE, *PRIPMIB_BASE;
  143.  
  144.  
  145. //
  146. // RIP MIB Interface Table Entry
  147. //
  148.  
  149. typedef struct _RIP_IF_STATS {
  150.  
  151.     ULONG            RipIfOperState;   // up, down or sleeping
  152.     ULONG            RipIfInputPackets;
  153.     ULONG            RipIfOutputPackets;
  154.  
  155.     } RIP_IF_STATS, *PRIP_IF_STATS;
  156.  
  157.  
  158.  
  159. typedef struct _RIP_INTERFACE {
  160.  
  161.     ULONG        InterfaceIndex;
  162.     RIP_IF_INFO        RipIfInfo;
  163.     RIP_IF_STATS    RipIfStats;
  164.  
  165.     } RIP_INTERFACE, *PRIP_INTERFACE;
  166.  
  167. //***************************************************************
  168. //                                *
  169. //         INPUT DATA For: Get, GetFirst, GetNext        *
  170. //                                *
  171. //***************************************************************
  172.  
  173. typedef struct _RIP_MIB_GET_INPUT_DATA {
  174.  
  175.     ULONG        TableId;
  176.     ULONG        InterfaceIndex;
  177.  
  178.     } RIP_MIB_GET_INPUT_DATA, *PRIP_MIB_GET_INPUT_DATA;
  179.  
  180. //***************************************************************
  181. //                                *
  182. //         INPUT DATA For: Create, Delete, Set        *
  183. //                                *
  184. //***************************************************************
  185.  
  186. typedef struct _RIP_MIB_SET_INPUT_DATA {
  187.  
  188.     ULONG         TableId;
  189.     RIP_INTERFACE     RipInterface;
  190.  
  191.     } RIP_MIB_SET_INPUT_DATA, *PRIP_MIB_SET_INPUT_DATA;
  192.  
  193. //
  194. // ***            RIP Base Entry                    ***
  195. //
  196.  
  197. // MIB Functions: Get
  198.  
  199. // INPUT DATA: RIP_MIB_GET_INPUT_DATA and Index is not used
  200.  
  201. // OUTPUT DATA: RIP_INTERFACE
  202.  
  203. //
  204. // ***            RIP Interface Table                    ***
  205. //
  206.  
  207. // MIB Functions: Get, GetFirst, GetNext, Set
  208.  
  209. // INPUT DATA: RIP_MIB_GET_INPUT_DATA for Get, GetFirst and GetNext
  210. //           RIP_MIB_SET_INPUT_DATA for Set
  211.  
  212. //
  213. // OUTPUT DATA: RIP_INTERFACE
  214. //
  215.  
  216. #endif
  217.