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.

149 lines
2.7 KiB

  1. /*
  2. File SdoWrap.h
  3. Defines functions that interact directly with sdo
  4. objects.
  5. These functions are also implemented in rasuser.dll but
  6. have been ported to this .dll for efficiency and so that
  7. we have control over the functionality.
  8. Paul Mayfield, 6/9/98
  9. */
  10. #ifndef __mprapi_sdowrap_h
  11. #define __mprapi_sdowrap_h
  12. #ifdef __cplusplus
  13. extern "C" {
  14. #endif
  15. //
  16. // Exported C function to open the SDO. This function is also
  17. // exported from rasuser.dll.
  18. //
  19. // usertype: IAS_USER_STORE_LOCAL_SAM or IAS_USER_STORE_ACTIVE_DIRECTORY
  20. // retriveType: RETRIEVE_SERVER_DATA_FROM_DS or 0
  21. // returns S_OK, or error message from SDO
  22. //
  23. HRESULT WINAPI
  24. SdoWrapOpenServer(
  25. IN BSTR pszMachine,
  26. IN BOOL bLocal,
  27. OUT HANDLE* phSdoSrv);
  28. //
  29. // Closes out an open sdo server object
  30. //
  31. HRESULT WINAPI
  32. SdoWrapCloseServer(
  33. IN HANDLE hSdoSrv);
  34. //
  35. // Get a reference to a user in the sdo object
  36. //
  37. // usertype: IAS_USER_STORE_LOCAL_SAM or
  38. // IAS_USER_STORE_ACTIVE_DIRECTORY
  39. //
  40. // returns S_OK, or error message from SDO
  41. //
  42. HRESULT WINAPI
  43. SdoWrapOpenUser(
  44. IN HANDLE hSdoSrv,
  45. IN BSTR pszUser,
  46. OUT HANDLE* phSdoObj);
  47. //
  48. // Retrieves the default profile object
  49. //
  50. HRESULT WINAPI
  51. SdoWrapOpenDefaultProfile (
  52. IN HANDLE hSdoSrv,
  53. OUT PHANDLE phSdoObj);
  54. //
  55. // Closes an open sdo object
  56. //
  57. HRESULT WINAPI
  58. SdoWrapClose(
  59. IN HANDLE hSdoObj);
  60. HRESULT WINAPI
  61. SdoWrapCloseProfile(
  62. IN HANDLE hProfile);
  63. //
  64. // Commits an sdo object
  65. //
  66. // bCommitChanges -- TRUE, all changes are saved,
  67. // FALSE restore to previous commit
  68. // returns S_OK or error message from SDO
  69. //
  70. HRESULT WINAPI
  71. SdoWrapCommit(
  72. IN HANDLE hSdoObj,
  73. IN BOOL bCommitChanges);
  74. //
  75. // Get's an sdo attribute
  76. //
  77. // when attribute is absent,
  78. // V_VT(pVar) = VT_ERROR;
  79. // V_ERROR(pVar) = DISP_E_PARAMNOTFOUND;
  80. //
  81. // returns S_OK or error message from SDO
  82. //
  83. HRESULT WINAPI
  84. SdoWrapGetAttr(
  85. IN HANDLE hSdoObj,
  86. IN ULONG ulPropId,
  87. OUT VARIANT* pVar);
  88. //
  89. // Puts an sdo attribute
  90. //
  91. // returns S_OK or error message from SDO
  92. //
  93. HRESULT WINAPI
  94. SdoWrapPutAttr(
  95. IN HANDLE hSdoObj,
  96. IN ULONG ulPropId,
  97. OUT VARIANT* pVar);
  98. //
  99. // Remove an attribute
  100. //
  101. // returns S_OK or error message from SDO
  102. //
  103. HRESULT WINAPI
  104. SdoWrapRemoveAttr(
  105. IN HANDLE hSdoObj,
  106. IN ULONG ulPropId);
  107. //
  108. // Returns values from a profile
  109. //
  110. HRESULT
  111. SdoWrapGetProfileValues(
  112. IN HANDLE hProfile,
  113. OUT VARIANT* pvarEp, // enc policy
  114. OUT VARIANT* varEt, // enc type
  115. OUT VARIANT* varAt); // auth type
  116. //
  117. // Writes out the set of profile values
  118. //
  119. HRESULT
  120. SdoWrapSetProfileValues(
  121. IN HANDLE hProfile,
  122. IN VARIANT* pvarEp OPTIONAL,
  123. IN VARIANT* pvarEt OPTIONAL,
  124. IN VARIANT* pvarAt OPTIONAL);
  125. #ifdef __cplusplus
  126. }
  127. #endif
  128. #endif