home *** CD-ROM | disk | FTP | other *** search
/ Computer Shopper 186 / DPCS0803.ISO / Café / Dev-C++ / devcpp4980.exe / $INSTDIR / include / ddk / tdiinfo.h < prev    next >
Encoding:
C/C++ Source or Header  |  2003-05-15  |  3.1 KB  |  116 lines

  1. /*
  2.  * tdiinfo.h
  3.  *
  4.  * TDI set and query information interface
  5.  *
  6.  * This file is part of the w32api package.
  7.  *
  8.  * Contributors:
  9.  *   Created by Casper S. Hornstrup <chorns@users.sourceforge.net>
  10.  *
  11.  * THIS SOFTWARE IS NOT COPYRIGHTED
  12.  *
  13.  * This source code is offered for use in the public domain. You may
  14.  * use, modify or distribute it freely.
  15.  *
  16.  * This code is distributed in the hope that it will be useful but
  17.  * WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
  18.  * DISCLAIMED. This includes but is not limited to warranties of
  19.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  20.  *
  21.  */
  22.  
  23. #ifndef __TDIINFO_H
  24. #define __TDIINFO_H
  25.  
  26. #if __GNUC__ >=3
  27. #pragma GCC system_header
  28. #endif
  29.  
  30. #ifdef __cplusplus
  31. extern "C" {
  32. #endif
  33.  
  34. #pragma pack(push,4)
  35.  
  36. #include "ntddk.h"
  37.  
  38.  
  39. typedef struct TDIEntityID {
  40.   ULONG  tei_entity;
  41.   ULONG  tei_instance;
  42. } TDIEntityID;
  43.  
  44. #define    MAX_TDI_ENTITIES                  4096
  45. #define INVALID_ENTITY_INSTANCE           -1
  46. #define    GENERIC_ENTITY                            0
  47. #define    ENTITY_LIST_ID                            0
  48. #define    ENTITY_TYPE_ID                            1
  49.  
  50. #define    AT_ENTITY                                    0x280
  51. #define    CL_NL_ENTITY                              0x301
  52. #define    CL_TL_ENTITY                              0x401
  53. #define    CO_NL_ENTITY                              0x300
  54. #define    CO_TL_ENTITY                              0x400
  55. #define    ER_ENTITY                                    0x380
  56. #define    IF_ENTITY                                    0x200
  57.  
  58. #define    AT_ARP                                        0x280
  59. #define    AT_NULL                                        0x282
  60. #define    CL_TL_NBF                                    0x401
  61. #define    CL_TL_UDP                                    0x403
  62. #define    CL_NL_IPX                                    0x301
  63. #define    CL_NL_IP                                    0x303
  64. #define    CO_TL_NBF                                    0x400
  65. #define    CO_TL_SPX                                    0x402
  66. #define    CO_TL_TCP                                    0x404
  67. #define    CO_TL_SPP                                    0x406
  68. #define    ER_ICMP                                        0x380
  69. #define    IF_GENERIC                                  0x200
  70. #define    IF_MIB                                        0x202
  71.  
  72. /* TDIObjectID.toi_class constants */
  73. #define    INFO_CLASS_GENERIC                      0x100
  74. #define    INFO_CLASS_PROTOCOL                      0x200
  75. #define    INFO_CLASS_IMPLEMENTATION            0x300
  76.  
  77. /* TDIObjectID.toi_type constants */
  78. #define    INFO_TYPE_PROVIDER                      0x100
  79. #define    INFO_TYPE_ADDRESS_OBJECT            0x200
  80. #define    INFO_TYPE_CONNECTION                  0x300
  81.  
  82. typedef struct _TDIObjectID {
  83.     TDIEntityID  toi_entity;
  84.     ULONG  toi_class;
  85.     ULONG  toi_type;
  86.     ULONG  toi_id;
  87. } TDIObjectID;
  88.  
  89. #define    CONTEXT_SIZE                              16
  90.  
  91. typedef struct _TCP_REQUEST_QUERY_INFORMATION_EX {
  92.   TDIObjectID  ID;
  93.   ULONG_PTR  Context[CONTEXT_SIZE / sizeof(ULONG_PTR)];
  94. } TCP_REQUEST_QUERY_INFORMATION_EX, *PTCP_REQUEST_QUERY_INFORMATION_EX;
  95.  
  96. #if defined(_WIN64)
  97. typedef struct _TCP_REQUEST_QUERY_INFORMATION_EX32 {
  98.   TDIObjectID  ID;
  99.   ULONG32  Context[CONTEXT_SIZE / sizeof(ULONG32)];
  100. } TCP_REQUEST_QUERY_INFORMATION_EX32, *PTCP_REQUEST_QUERY_INFORMATION_EX32;
  101. #endif /* _WIN64 */
  102.  
  103. typedef struct _TCP_REQUEST_SET_INFORMATION_EX {
  104.   TDIObjectID  ID;
  105.   UINT  BufferSize;
  106.   UCHAR  Buffer[1];
  107. } TCP_REQUEST_SET_INFORMATION_EX, *PTCP_REQUEST_SET_INFORMATION_EX;
  108.  
  109. #pragma pack(pop)
  110.  
  111. #ifdef __cplusplus
  112. }
  113. #endif
  114.  
  115. #endif /* __TDIINFO_H */
  116.