Source code of Windows XP (NT5)
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.

169 lines
3.7 KiB

  1. /*++
  2. Copyright (c) 1996-1197 Microsoft Corporation
  3. Module Name:
  4. rpcstrcs.h
  5. Abstract:
  6. Domain Name System (DNS)
  7. DNS Caching Resolver Structures
  8. Author:
  9. Glenn Curtis (glennc) January 11, 1997
  10. Revision History:
  11. --*/
  12. #ifndef _RPCSTRCS_INCLUDED_
  13. #define _RPCSTRCS_INCLUDED_
  14. #ifndef _DNSAPI_INCLUDE_
  15. #include <dnsapi.h>
  16. #endif
  17. #ifdef MIDL_PASS
  18. #define LPSTR [string] char *
  19. #define LPCSTR [string] const char *
  20. #endif
  21. //
  22. // Net adapter list structures
  23. //
  24. typedef struct _DNS_IP_ADDR_LIST_
  25. {
  26. DWORD dwAddressCount;
  27. #ifdef MIDL_PASS
  28. [size_is(dwAddressCount)] DNS_ADDRESS_INFO AddressArray[];
  29. #else // MIDL_PASS
  30. DNS_ADDRESS_INFO AddressArray[1];
  31. #endif // MIDL_PASS
  32. }
  33. DNS_IP_ADDR_LIST, *PDNS_IP_ADDR_LIST;
  34. typedef struct _DWORD_LIST_ITEM_
  35. {
  36. struct _DWORD_LIST_ITEM_ * pNext;
  37. DWORD Value1;
  38. DWORD Value2;
  39. }
  40. DWORD_LIST_ITEM, *PDWORD_LIST_ITEM;
  41. typedef struct _DNS_STATS_TABLE_
  42. {
  43. struct _DNS_STATS_TABLE_ * pNext;
  44. PDWORD_LIST_ITEM pListItem;
  45. }
  46. DNS_STATS_TABLE, *PDNS_STATS_TABLE;
  47. typedef struct _DNS_RPC_CACHE_TABLE_
  48. {
  49. struct _DNS_RPC_CACHE_TABLE_ * pNext;
  50. LPWSTR Name;
  51. WORD Type1;
  52. WORD Type2;
  53. WORD Type3;
  54. }
  55. DNS_RPC_CACHE_TABLE, *PDNS_RPC_CACHE_TABLE;
  56. //
  57. // Most of the resolver interface is poorly designed or
  58. // useless. For instance there is NO reason to have
  59. // turned any of the above into linked lists.
  60. //
  61. // We simply need definitions that are MIDL_PASS aware.
  62. // This should sit in a common header and be picked up
  63. // by dnslib.h. This must wait until dnslib.h is
  64. // private again OR we separate out the private stuff
  65. // like this in some fashion.
  66. //
  67. // Note, taking this private should also involve rename,
  68. // the PUBLIC structs are obviously the one's that should
  69. // have the "DNS" tag. (Amazing.)
  70. //
  71. typedef struct _NameServerInfo
  72. {
  73. IP_ADDRESS ipAddress;
  74. DWORD Priority;
  75. DNS_STATUS Status;
  76. }
  77. NAME_SERVER_INFO, *PNAME_SERVER_INFO;
  78. typedef struct _AdapterInfo
  79. {
  80. LPSTR pszAdapterGuidName;
  81. LPSTR pszAdapterDomain;
  82. PIP_ARRAY pAdapterIPAddresses;
  83. PIP_ARRAY pAdapterIPSubnetMasks;
  84. DWORD Status;
  85. DWORD InfoFlags;
  86. DWORD ReturnFlags;
  87. DWORD ipLastSend;
  88. DWORD cServerCount;
  89. DWORD cTotalListSize;
  90. #ifdef MIDL_PASS
  91. [size_is(cTotalListSize)] NAME_SERVER_INFO aipServers[];
  92. #else
  93. NAME_SERVER_INFO aipServers[1];
  94. #endif
  95. }
  96. ADAPTER_INFO, *PADAPTER_INFO;
  97. typedef struct _SearchName
  98. {
  99. LPSTR pszName;
  100. DWORD Flags;
  101. }
  102. SEARCH_NAME, *PSEARCH_NAME;
  103. typedef struct _RpcSearchList
  104. {
  105. LPSTR pszDomainOrZoneName;
  106. DWORD cNameCount; // Zero for FindAuthoritativeZone
  107. DWORD cTotalListSize; // Zero for FindAuthoritativeZone
  108. DWORD CurrentName; // 0 for pszDomainOrZoneName
  109. // 1 for first name in array below
  110. // ...
  111. #ifdef MIDL_PASS
  112. [size_is(cTotalListSize)] SEARCH_NAME aSearchListNames[];
  113. #else
  114. SEARCH_NAME aSearchListNames[1];
  115. #endif
  116. }
  117. RPC_SEARCH_LIST, *PRPC_SEARCH_LIST;
  118. typedef struct _NetworkInfo
  119. {
  120. DWORD ReturnFlags;
  121. DWORD InfoFlags;
  122. PRPC_SEARCH_LIST pSearchList;
  123. DWORD cAdapterCount;
  124. DWORD cTotalListSize;
  125. #ifdef MIDL_PASS
  126. [size_is(cTotalListSize)] PADAPTER_INFO aAdapterInfoList[];
  127. #else
  128. PADAPTER_INFO aAdapterInfoList[1];
  129. #endif
  130. }
  131. NETWORK_INFO, *PNETWORK_INFO;
  132. #endif // _RPCSTRCS_INCLUDED_