Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

176 lines
2.9 KiB

  1. /*++
  2. Copyright (c) 1998, Microsoft Corporation
  3. Module Name:
  4. rmapi.h
  5. Abstract:
  6. This module contains declarations for the part of the router-manager
  7. interface which is common to all the protocols in this component.
  8. Author:
  9. Abolade Gbadegesin (aboladeg) 4-Mar-1998
  10. Revision History:
  11. --*/
  12. #ifndef _NATHLP_RMAPI_H_
  13. #define _NATHLP_RMAPI_H_
  14. typedef enum {
  15. NhUninitializedMode,
  16. NhSharedAccessMode,
  17. NhRoutingProtocolMode,
  18. NhMaximumMode
  19. } NH_COMPONENT_MODE, *PNH_COMPONENT_MODE;
  20. #define NhIsBoundaryInterface(i,b) NatIsBoundaryInterface((i),(b))
  21. #define NhQuerySharedConnectionDomainName() NatQuerySharedConnectionDomainName()
  22. extern NH_COMPONENT_MODE NhComponentMode;
  23. extern CRITICAL_SECTION NhLock;
  24. extern HMODULE NhpRtrmgrDll;
  25. extern const WCHAR NhTcpipParametersString[];
  26. //
  27. // Application settings (response protocols) handling
  28. //
  29. extern LIST_ENTRY NhApplicationSettingsList;
  30. extern LIST_ENTRY NhDhcpReservationList;
  31. extern DWORD NhDhcpScopeAddress;
  32. extern DWORD NhDhcpScopeMask;
  33. typedef struct _NAT_APP_ENTRY
  34. {
  35. LIST_ENTRY Link;
  36. UCHAR Protocol;
  37. USHORT Port;
  38. USHORT ResponseCount;
  39. HNET_RESPONSE_RANGE *ResponseArray;
  40. } NAT_APP_ENTRY, *PNAT_APP_ENTRY;
  41. typedef struct _NAT_DHCP_RESERVATION
  42. {
  43. LIST_ENTRY Link;
  44. LPWSTR Name;
  45. ULONG Address;
  46. } NAT_DHCP_RESERVATION, *PNAT_DHCP_RESERVATION;
  47. typedef DWORD (CALLBACK *MAPINTERFACETOADAPTER)(DWORD);
  48. VOID
  49. NhBuildDhcpReservations(
  50. VOID
  51. );
  52. ULONG
  53. NhDialSharedConnection(
  54. VOID
  55. );
  56. VOID
  57. NhFreeApplicationSettings(
  58. VOID
  59. );
  60. VOID
  61. NhFreeDhcpReservations(
  62. VOID
  63. );
  64. BOOLEAN
  65. NhIsDnsProxyEnabled(
  66. VOID
  67. );
  68. BOOLEAN
  69. NhIsLocalAddress(
  70. ULONG Address
  71. );
  72. BOOLEAN
  73. NhIsWinsProxyEnabled(
  74. VOID
  75. );
  76. PIP_ADAPTER_BINDING_INFO
  77. NhQueryBindingInformation(
  78. ULONG AdapterIndex
  79. );
  80. NTSTATUS
  81. NhQueryDomainName(
  82. PCHAR* DomainName
  83. );
  84. ULONG
  85. NhQueryHostByName(
  86. PWCHAR pszHostName,
  87. PWCHAR pszDomainName,
  88. ULONG ScopeNetwork,
  89. ULONG ScopeMask
  90. );
  91. NTSTATUS
  92. NhQueryICSDomainSuffix(
  93. PWCHAR *ppszDomain
  94. );
  95. NTSTATUS
  96. NhQueryValueKey(
  97. HANDLE Key,
  98. const WCHAR ValueName[],
  99. PKEY_VALUE_PARTIAL_INFORMATION* Information
  100. );
  101. VOID
  102. NhSignalNatInterface(
  103. ULONG Index,
  104. BOOLEAN Boundary
  105. );
  106. ULONG
  107. NhMapAddressToAdapter(
  108. ULONG Address
  109. );
  110. ULONG
  111. NhMapInterfaceToAdapter(
  112. ULONG Index
  113. );
  114. extern
  115. ULONG
  116. NhMapInterfaceToRouterIfType(
  117. ULONG Index
  118. );
  119. VOID
  120. NhResetComponentMode(
  121. VOID
  122. );
  123. BOOLEAN
  124. NhSetComponentMode(
  125. NH_COMPONENT_MODE ComponentMode
  126. );
  127. VOID
  128. NhUpdateApplicationSettings(
  129. VOID
  130. );
  131. ULONG
  132. APIENTRY
  133. RegisterProtocol(
  134. IN OUT PMPR_ROUTING_CHARACTERISTICS RoutingCharacteristics,
  135. IN OUT PMPR_SERVICE_CHARACTERISTICS ServiceCharacteristics
  136. );
  137. #endif // _NATHLP_RMAPI_H_