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.

255 lines
7.9 KiB

  1. /*++
  2. Copyright (c) 1995 Microsoft Corporation
  3. Module Name:
  4. smtpsvc.idl
  5. Abstract:
  6. Contains the Smtp RPC interface specification for the SMTP server.
  7. This includes API from the following catagories:
  8. Also contains the RPC specific data structures for these API.
  9. Author:
  10. Johnson Apacible (johnsona) 13-Oct-1995
  11. Based on srvsvc.idl code from DanL and JohnsonA
  12. Environment:
  13. User Mode - Win32 - MIDL
  14. Revision History:
  15. Keith Lau (keithlau) 7/18/96 Created new RPCs
  16. Keith Lau (keithlau) 8/28/96 Created new SDK RPCs
  17. --*/
  18. //
  19. // Interface Attributes
  20. //
  21. [
  22. uuid(8cfb5d70-31a4-11cf-a7d8-00805f48a135),
  23. version(3.0),
  24. #ifdef __midl
  25. ms_union,
  26. #endif // __midl
  27. pointer_default(unique)
  28. ]
  29. interface smtp
  30. {
  31. import "import.idl";
  32. #include <lmcons.h>
  33. //
  34. // BUGBUG - take this definition out when midl understands LPWSTR etc
  35. //
  36. typedef [handle] LPWSTR SMTP_HANDLE;
  37. typedef [handle] LPWSTR SMTP_IMPERSONATE_HANDLE;
  38. //
  39. // Structures - Smtp
  40. //
  41. typedef [switch_type(unsigned long)] union _STAT_INFO {
  42. [case(0)]
  43. PSMTP_STATISTICS_BLOCK_ARRAY StatInfo0;
  44. [default]
  45. ;
  46. } STAT_INFO, *PSTAT_INFO, *LPSTAT_INFO;
  47. NET_API_STATUS
  48. NET_API_FUNCTION
  49. SmtprGetAdminInformation(
  50. [in, string, unique] SMTP_HANDLE pszServer,
  51. [out] LPSMTP_CONFIG_INFO * ppConfig,
  52. [in] DWORD dwInstance
  53. );
  54. NET_API_STATUS
  55. NET_API_FUNCTION
  56. SmtprSetAdminInformation(
  57. [in, string, unique] SMTP_HANDLE pszServer,
  58. [in] LPSMTP_CONFIG_INFO pConfig,
  59. [in] DWORD dwInstance
  60. );
  61. NET_API_STATUS
  62. SmtprQueryStatistics(
  63. [in,string,unique] SMTP_HANDLE ServerName,
  64. [in] DWORD Level,
  65. [out, switch_is(Level)] LPSTAT_INFO InfoStruct
  66. );
  67. NET_API_STATUS
  68. SmtprClearStatistics(
  69. [in,string,unique] SMTP_HANDLE ServerName,
  70. [in] DWORD dwInstance
  71. );
  72. NET_API_STATUS
  73. SmtprGetConnectedUserList(
  74. [in,string,unique] SMTP_HANDLE wszServerName,
  75. [out] LPSMTP_CONN_USER_LIST *ppConnUserList,
  76. [in] DWORD dwInstance
  77. );
  78. NET_API_STATUS
  79. SmtprDisconnectUser(
  80. [in,string,unique] SMTP_HANDLE wszServerName,
  81. [in] DWORD dwUserId,
  82. [in] DWORD dwInstance
  83. );
  84. NET_API_STATUS
  85. SmtprCreateUser(
  86. [in,string,unique] SMTP_HANDLE wszServerName,
  87. [in,string,unique] LPWSTR wszEmail,
  88. [in,string,unique] LPWSTR wszForwardEmail,
  89. [in] DWORD dwLocal,
  90. [in] DWORD dwMailboxSize,
  91. [in] DWORD dwMailboxMessageSize,
  92. [in,string,unique] LPWSTR wszVRoot,
  93. [in] DWORD dwInstance
  94. );
  95. NET_API_STATUS
  96. SmtprDeleteUser(
  97. [in,string,unique] SMTP_HANDLE wszServerName,
  98. [in,string,unique] LPWSTR wszEmail,
  99. [in] DWORD dwInstance
  100. );
  101. NET_API_STATUS
  102. SmtprGetUserProps(
  103. [in,string,unique] SMTP_HANDLE wszServerName,
  104. [in,string,unique] LPWSTR wszEmail,
  105. [out] LPSMTP_USER_PROPS *ppUserProps,
  106. [in] DWORD dwInstance
  107. );
  108. NET_API_STATUS
  109. SmtprSetUserProps(
  110. [in,string,unique] SMTP_HANDLE wszServerName,
  111. [in,string,unique] LPWSTR wszEmail,
  112. [in,unique] LPSMTP_USER_PROPS pUserProps,
  113. [in] DWORD dwInstance
  114. );
  115. NET_API_STATUS
  116. SmtprCreateDistList(
  117. [in,string,unique] SMTP_HANDLE wszServerName,
  118. [in,string,unique] LPWSTR wszEmail,
  119. [in] DWORD dwType,
  120. [in] DWORD dwInstance
  121. );
  122. NET_API_STATUS
  123. SmtprDeleteDistList(
  124. [in,string,unique] SMTP_HANDLE wszServerName,
  125. [in,string,unique] LPWSTR wszEmail,
  126. [in] DWORD dwInstance
  127. );
  128. NET_API_STATUS
  129. SmtprCreateDistListMember(
  130. [in,string,unique] SMTP_HANDLE wszServerName,
  131. [in,string,unique] LPWSTR wszEmail,
  132. [in,string,unique] LPWSTR wszEmailMember,
  133. [in] DWORD dwInstance
  134. );
  135. NET_API_STATUS
  136. SmtprDeleteDistListMember(
  137. [in,string,unique] SMTP_HANDLE wszServerName,
  138. [in,string,unique] LPWSTR wszEmail,
  139. [in,string,unique] LPWSTR wszEmailMember,
  140. [in] DWORD dwInstance
  141. );
  142. NET_API_STATUS
  143. SmtprGetNameList(
  144. [in,string,unique] SMTP_HANDLE wszServerName,
  145. [in,string,unique] LPWSTR wszEmail,
  146. [in] DWORD dwType,
  147. [in] DWORD dwRowsRequested,
  148. [in] BOOL fForward,
  149. [out] LPSMTP_NAME_LIST *ppNameList,
  150. [in] DWORD dwInstance
  151. );
  152. NET_API_STATUS
  153. SmtprGetNameListFromList(
  154. [in,string,unique] SMTP_HANDLE wszServerName,
  155. [in,string,unique] LPWSTR wszEmailList,
  156. [in,string,unique] LPWSTR wszEmail,
  157. [in] DWORD dwType,
  158. [in] DWORD dwRowsRequested,
  159. [in] BOOL fForward,
  160. [out] LPSMTP_NAME_LIST *ppNameList,
  161. [in] DWORD dwInstance
  162. );
  163. NET_API_STATUS
  164. SmtprGetVRootSize(
  165. [in,string,unique] SMTP_HANDLE wszServerName,
  166. [in,string,unique] LPWSTR wszVRoot,
  167. [out] LPDWORD pdwBytes,
  168. [in] DWORD dwInstance
  169. );
  170. NET_API_STATUS
  171. SmtprBackupRoutingTable(
  172. [in,string,unique] SMTP_HANDLE wszServerName,
  173. [in,string,unique] LPWSTR wszPath,
  174. [in] DWORD dwInstance
  175. );
  176. #ifdef USE_OLD_SDK
  177. // ===================================================
  178. // SMTP SDK RPCs
  179. //
  180. NET_API_STATUS
  181. NET_API_FUNCTION
  182. SmtprGetUserProfileInformation(
  183. [in, string, unique] SMTP_HANDLE wszServer,
  184. [in, string, unique] LPWSTR wszEmail,
  185. [in, string, unique] LPWSTR wszExtensionDllName,
  186. [in, string, unique] LPWSTR wszKey,
  187. [out, string] LPWSTR *ppwszValue,
  188. [in, out] LPDWORD lpdwSize,
  189. [in] DWORD dwInstance
  190. );
  191. NET_API_STATUS
  192. NET_API_FUNCTION
  193. SmtprSetUserProfileInformation(
  194. [in, string, unique] SMTP_HANDLE wszServer,
  195. [in, string, unique] LPWSTR wszEmail,
  196. [in, string, unique] LPWSTR wszExtensionDllName,
  197. [in, string, unique] LPWSTR wszKey,
  198. [in, string, unique] LPWSTR wszValue,
  199. [in] DWORD dwInstance
  200. );
  201. #endif
  202. }