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.

244 lines
8.4 KiB

  1. /****************************************************************************/
  2. // jetrpc.idl
  3. //
  4. // RPC IDL covering the network interface between the Jet RPC client
  5. // tssdjet.dll (a TS Session Directory provider) and the server (dis.exe -
  6. // server component).
  7. //
  8. // Copyright (C) 2000 Microsoft Corporation
  9. /****************************************************************************/
  10. // Copied from tssd.h for use here.
  11. #define TSSD_MaxDisconnectedSessions 10
  12. // Length of some strings
  13. #define TSSD_UserNameLen 256
  14. #define TSSD_DomainLength 128
  15. #define TSSD_ServAddrLen 128
  16. #define TSSD_AppTypeLen 256
  17. #define TSSD_ClusterNameLen 128
  18. #define TSSD_ServerNameLen 128
  19. #define TSSD_MaxStringSize 256
  20. midl_pragma warning( disable: 2466 2467)
  21. // The number uuid was generated by UUIDGEN, and
  22. // is unique across time and space. This number should
  23. // never change for this service.
  24. [
  25. uuid(aa177641-fc9b-41bd-80ff-f964a701596f),
  26. version(1.0),
  27. pointer_default(unique)
  28. ]
  29. interface TSSDJetRPC
  30. {
  31. import "wtypes.idl";
  32. typedef [context_handle] void *HCLIENTINFO;
  33. typedef [string, max_is(TSSD_MaxStringSize)] WCHAR *TSSD_UserName;
  34. typedef [string, max_is(TSSD_MaxStringSize)] WCHAR *TSSD_Domain;
  35. typedef [string, max_is(TSSD_MaxStringSize)] WCHAR *TSSD_ServAddr;
  36. typedef [string, max_is(TSSD_MaxStringSize)] WCHAR *TSSD_AppType;
  37. typedef [range(0,10)] DWORD NumSessions_t;
  38. typedef struct {
  39. TSSD_ServAddr ServerAddress;
  40. DWORD SessionID;
  41. DWORD TSProtocol;
  42. TSSD_AppType AppType;
  43. DWORD ResolutionWidth;
  44. DWORD ResolutionHeight;
  45. DWORD ColorDepth;
  46. DWORD CreateTimeLow;
  47. DWORD CreateTimeHigh;
  48. DWORD DisconnectTimeLow;
  49. DWORD DisconnectTimeHigh;
  50. DWORD State;
  51. } TSSD_DiscSessInfo;
  52. typedef struct {
  53. TSSD_UserName UserName;
  54. TSSD_Domain Domain;
  55. DWORD SessionID;
  56. DWORD TSProtocol;
  57. TSSD_AppType AppType;
  58. DWORD ResolutionWidth;
  59. DWORD ResolutionHeight;
  60. DWORD ColorDepth;
  61. DWORD CreateTimeLow;
  62. DWORD CreateTimeHigh;
  63. DWORD DisconnectTimeLow;
  64. DWORD DisconnectTimeHigh;
  65. char State;
  66. } TSSD_RepopInfo;
  67. DWORD TSSDRpcServerOnline(
  68. [in] handle_t Binding,
  69. [in, string, max_is(TSSD_MaxStringSize)] WCHAR *ClusterName, // Max 64 chars incl. null.
  70. [out] HCLIENTINFO *hCI,
  71. [in] DWORD SrvOnlineFlags,
  72. [in, out, string] WCHAR ComputerName[TSSD_ServAddrLen], //max 128 chars, return the server name
  73. [in, string, max_is(TSSD_MaxStringSize)] WCHAR *ServerIPAddr); // Max 128 chars incl. null.
  74. DWORD TSSDRpcServerOffline(
  75. [in] handle_t Binding,
  76. [in, out] HCLIENTINFO *hCI);
  77. DWORD TSSDRpcGetUserDisconnectedSessions(
  78. [in] handle_t Binding,
  79. [in, out] HCLIENTINFO *hCI,
  80. [in, string, max_is(TSSD_MaxStringSize)] WCHAR *UserName, // Max 256 chars incl. null.
  81. [in, string, max_is(TSSD_MaxStringSize)] WCHAR *Domain, // Max 128 chars incl. null.
  82. [in, out, ref] NumSessions_t *pNumSessions, // Max 10
  83. // Pointer to an array of Disconnected session info structures
  84. // Note the comma indicates that the size_is applies to the array.
  85. [out, size_is(,*pNumSessions)] TSSD_DiscSessInfo **dsi);
  86. DWORD TSSDRpcCreateSession(
  87. [in] handle_t Binding,
  88. [in, out] HCLIENTINFO *hCI,
  89. [in, string, max_is(TSSD_MaxStringSize)] WCHAR *UserName, // Max 256 chars incl. null.
  90. [in, string, max_is(TSSD_MaxStringSize)] WCHAR *Domain, // Max 128 chars incl. null.
  91. [in] DWORD SessionID,
  92. [in] DWORD TSProtocol,
  93. [in, string, max_is(TSSD_MaxStringSize)] WCHAR *AppType, // Max 256 chars incl. null.
  94. [in] DWORD ResolutionWidth,
  95. [in] DWORD ResolutionHeight,
  96. [in] DWORD ColorDepth,
  97. [in] DWORD CreateTimeLow,
  98. [in] DWORD CreateTimeHigh);
  99. DWORD TSSDRpcDeleteSession(
  100. [in] handle_t Binding,
  101. [in, out] HCLIENTINFO *hCI,
  102. DWORD SessionID);
  103. DWORD TSSDRpcSetSessionDisconnected(
  104. [in] handle_t Binding,
  105. [in, out] HCLIENTINFO *hCI,
  106. DWORD SessionID,
  107. DWORD DiscTimeLow,
  108. DWORD DiscTimeHigh);
  109. DWORD TSSDRpcSetSessionReconnected(
  110. [in] handle_t Binding,
  111. [in, out] HCLIENTINFO *hCI,
  112. DWORD SessionID,
  113. DWORD TSProtocol,
  114. DWORD ResWidth,
  115. DWORD ResHeight,
  116. DWORD ColorDepth);
  117. DWORD TSSDRpcSetServerReconnectPending(
  118. [in] handle_t Binding,
  119. [in, string, max_is(TSSD_MaxStringSize)] WCHAR *ServerAddress,
  120. DWORD AlmostTimeLow,
  121. DWORD AlmostTimeHigh);
  122. DWORD TSSDRpcRepopulateAllSessions(
  123. [in] handle_t Binding,
  124. [in, out] HCLIENTINFO *hCI,
  125. [in] DWORD NumSessions,
  126. [in, size_is(NumSessions)] TSSD_RepopInfo rpi[]);
  127. DWORD TSSDRpcUpdateConfigurationSetting(
  128. [in] handle_t Binding,
  129. [in, out] HCLIENTINFO *hCI,
  130. [in] DWORD dwSetting,
  131. [in] DWORD dwSettingLength,
  132. [in, size_is(dwSettingLength)] BYTE pbValue[]);
  133. DWORD TSSDRpcPingSD(
  134. [in] handle_t Binding);
  135. }
  136. // RPC used to query infomation in the session directory
  137. [
  138. uuid(6af13c8b-0844-4c83-9064-1892ba825527),
  139. version(1.0),
  140. pointer_default(unique)
  141. ]
  142. interface TSSDQUERYRPC
  143. {
  144. import "wtypes.idl";
  145. typedef [string] WCHAR *TSSD_ClusterName;
  146. typedef [string] WCHAR *TSSD_ServName;
  147. typedef struct {
  148. WCHAR ClusterName[TSSD_ClusterNameLen];
  149. DWORD NumberOfServers;
  150. char SingleSessionMode;
  151. } TSSD_ClusterInfo;
  152. typedef struct {
  153. WCHAR ServerName[TSSD_ServerNameLen];
  154. WCHAR ServerIPAddress[TSSD_ServAddrLen];
  155. WCHAR ClusterName[TSSD_ClusterNameLen];
  156. DWORD NumberOfSessions;
  157. char SingleSessionMode;
  158. } TSSD_ServerInfo;
  159. typedef struct {
  160. WCHAR UserName[TSSD_UserNameLen];
  161. WCHAR DomainName[TSSD_DomainLength];
  162. WCHAR ServerName[TSSD_ServerNameLen];
  163. WCHAR ServerIPAddress[TSSD_ServAddrLen];
  164. DWORD SessionID;
  165. DWORD TSProtocol;
  166. WCHAR ApplicationType[TSSD_AppTypeLen];
  167. DWORD ResolutionWidth;
  168. DWORD ResolutionHeight;
  169. DWORD ColorDepth;
  170. FILETIME CreateTime;
  171. FILETIME DisconnectTime;
  172. char SessionState;
  173. } TSSD_SessionInfo;
  174. DWORD TSSDRpcQuerySessionInfoByUserName(
  175. [in] handle_t Binding,
  176. [in, string] WCHAR *UserName,
  177. [in, string] WCHAR *DomainName,
  178. [out] DWORD *pNumberOfSessions,
  179. [out, size_is(, *pNumberOfSessions)] TSSD_SessionInfo **ppSessionInfo);
  180. DWORD TSSDRpcQuerySessionInfoByServer(
  181. [in] handle_t Binding,
  182. [in, string] WCHAR *ServerName,
  183. [out] DWORD *pNumberOfSessions,
  184. [out, size_is(, *pNumberOfSessions)] TSSD_SessionInfo **ppSessionInfo);
  185. DWORD TSSDRpcQueryServerByName(
  186. [in] handle_t Binding,
  187. [in, string] WCHAR *ServerName,
  188. [out] DWORD *pNumberOfServers,
  189. [out, size_is(, *pNumberOfServers)] TSSD_ServerInfo **ppServerInfo);
  190. DWORD TSSDRpcQueryAllServers(
  191. [in] handle_t Binding,
  192. [out] DWORD *pNumberOfServers,
  193. [out, size_is(, *pNumberOfServers)] TSSD_ServerInfo **ppServerInfo);
  194. DWORD TSSDRpcQueryServersInCluster(
  195. [in] handle_t Binding,
  196. [in, string] WCHAR *ClusterName,
  197. [out] DWORD *pNumberOfServers,
  198. [out, size_is(, *pNumberOfServers)] TSSD_ServerInfo **ppServerInfo);
  199. DWORD TSSDRpcQueryAllClusterInfo(
  200. [in] handle_t Binding,
  201. [out] DWORD *pNumberOfClusters,
  202. [out, size_is(,*pNumberOfClusters)] TSSD_ClusterInfo **ppClusterInfo);
  203. DWORD TSSDRpcQueryClusterInfo(
  204. [in] handle_t Binding,
  205. [in, string] WCHAR *ClusterName,
  206. [out] DWORD *pNumberOfClusters,
  207. [out, size_is(,*pNumberOfClusters)] TSSD_ClusterInfo **ppClusterInfo);
  208. }