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.

215 lines
3.4 KiB

  1. /*++
  2. Copyright (c) 1996 Microsoft Corporation
  3. Module Name:
  4. scep.h
  5. Abstract:
  6. This module defines the data structures and function prototypes
  7. for the security managment utility
  8. Author:
  9. Jin Huang (jinhuang) 28-Oct-1996
  10. Revision History:
  11. --*/
  12. #ifndef _srvutil_
  13. #define _srvutil_
  14. #ifdef __cplusplus
  15. extern "C" {
  16. #endif
  17. typedef enum _SCE_FLAG_TYPE {
  18. SCE_FLAG_CONFIG=1,
  19. SCE_FLAG_CONFIG_APPEND,
  20. SCE_FLAG_ANALYZE,
  21. SCE_FLAG_ANALYZE_APPEND,
  22. SCE_FLAG_CONFIG_SCP,
  23. SCE_FLAG_CONFIG_SCP_APPEND
  24. } SCEFLAGTYPE;
  25. SCESTATUS
  26. ScepGetTotalTicks(
  27. IN PCWSTR TemplateName,
  28. IN PSCECONTEXT Context,
  29. IN AREA_INFORMATION Area,
  30. IN SCEFLAGTYPE nFlag,
  31. OUT PDWORD pTotalTicks
  32. );
  33. BOOL
  34. ScepIsEngineRecovering();
  35. SCESTATUS
  36. ScepSaveAndOffAuditing(
  37. OUT PPOLICY_AUDIT_EVENTS_INFO *ppAuditEvent,
  38. IN BOOL bTurnOffAuditing,
  39. IN LSA_HANDLE PolicyHandle OPTIONAL
  40. );
  41. NTSTATUS
  42. ScepGetAccountExplicitRight(
  43. IN LSA_HANDLE PolicyHandle,
  44. IN PSID AccountSid,
  45. OUT PDWORD PrivilegeLowRights,
  46. OUT PDWORD PrivilegeHighRights
  47. );
  48. NTSTATUS
  49. ScepGetMemberListSids(
  50. IN PSID DomainSid,
  51. IN LSA_HANDLE PolicyHandle,
  52. IN PSCE_NAME_LIST pMembers,
  53. OUT PUNICODE_STRING *MemberNames,
  54. OUT PSID** Sids,
  55. OUT PULONG MemberCount
  56. );
  57. DWORD
  58. ScepOpenFileObject(
  59. IN LPWSTR pObjectName,
  60. IN ACCESS_MASK AccessMask,
  61. OUT PHANDLE Handle
  62. );
  63. DWORD
  64. ScepOpenRegistryObject(
  65. IN SE_OBJECT_TYPE ObjectType,
  66. IN LPWSTR pObjectName,
  67. IN ACCESS_MASK AccessMask,
  68. OUT PHKEY Handle
  69. );
  70. SCESTATUS
  71. ScepGetNameInLevel(
  72. IN PCWSTR ObjectFullName,
  73. IN DWORD Level,
  74. IN WCHAR Delim,
  75. OUT PWSTR Buffer,
  76. OUT PBOOL LastOne
  77. );
  78. SCESTATUS
  79. ScepTranslateFileDirName(
  80. IN PWSTR oldFileName,
  81. OUT PWSTR *newFileName
  82. );
  83. //
  84. // errlog.c
  85. //
  86. SCESTATUS
  87. ScepLogInitialize(
  88. IN PCWSTR logname
  89. );
  90. SCESTATUS
  91. ScepLogOutput2(
  92. IN INT ErrLevel,
  93. IN DWORD rc,
  94. IN PWSTR fmt,
  95. ...
  96. );
  97. SCESTATUS
  98. ScepLogOutput(
  99. IN DWORD rc,
  100. IN LPTSTR buf
  101. );
  102. SCESTATUS
  103. ScepLogOutput3(
  104. IN INT ErrLevel,
  105. IN DWORD rc,
  106. IN UINT nId,
  107. ...
  108. );
  109. SCESTATUS
  110. ScepLogClose();
  111. SCESTATUS
  112. ScepLogWriteError(
  113. IN PSCE_ERROR_LOG_INFO pErrlog,
  114. IN INT ErrLevel
  115. );
  116. SCESTATUS
  117. ScepConvertLdapToJetIndexName(
  118. IN PWSTR TempName,
  119. OUT PWSTR *OutName
  120. );
  121. SCESTATUS
  122. ScepRestoreAuditing(
  123. IN PPOLICY_AUDIT_EVENTS_INFO auditEvent,
  124. IN LSA_HANDLE PolicyHandle OPTIONAL
  125. );
  126. DWORD
  127. ScepGetDefaultDatabase(
  128. IN LPCTSTR JetDbName OPTIONAL,
  129. IN DWORD LogOptions,
  130. IN LPCTSTR LogFileName OPTIONAL,
  131. OUT PBOOL pAdminLogon OPTIONAL,
  132. OUT PWSTR *ppDefDatabase
  133. );
  134. BOOL
  135. ScepIsDomainLocal(
  136. IN PUNICODE_STRING pDomainName OPTIONAL
  137. );
  138. BOOL
  139. ScepIsDomainLocalBySid(
  140. IN PSID pSidLookup
  141. );
  142. NTSTATUS
  143. ScepAddAdministratorToThisList(
  144. IN SAM_HANDLE DomainHandle OPTIONAL,
  145. IN OUT PSCE_NAME_LIST *ppList
  146. );
  147. DWORD
  148. ScepDatabaseAccessGranted(
  149. IN LPTSTR DatabaseName,
  150. IN DWORD DesiredAccess,
  151. IN BOOL bCreate
  152. );
  153. DWORD
  154. ScepAddSidToNameList(
  155. OUT PSCE_NAME_LIST *pNameList,
  156. IN PSID pSid,
  157. IN BOOL bReuseBuffer,
  158. OUT BOOL *pbBufferUsed
  159. );
  160. BOOL
  161. ScepValidSid(
  162. PSID Sid
  163. );
  164. BOOL
  165. ScepBinarySearch(
  166. IN PWSTR *aPszPtrs,
  167. IN DWORD dwSize_aPszPtrs,
  168. IN PWSTR pszNameToFind
  169. );
  170. #ifdef __cplusplus
  171. }
  172. #endif
  173. #endif