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.

181 lines
3.3 KiB

  1. /*++
  2. Copyright (c) 1999 Microsoft Corporation
  3. Module Name:
  4. sfc.h
  5. Abstract:
  6. Header file for public SFC interfaces.
  7. Author:
  8. Wesley Witt (wesw) 2-Feb-1999
  9. Revision History:
  10. --*/
  11. #ifndef _SFC_
  12. #define _SFC_
  13. #ifdef __cplusplus
  14. extern "C" {
  15. #endif
  16. #define SFC_DISABLE_NORMAL 0
  17. #define SFC_DISABLE_ASK 1
  18. #define SFC_DISABLE_ONCE 2
  19. #define SFC_DISABLE_SETUP 3
  20. #define SFC_DISABLE_NOPOPUPS 4
  21. #define SFC_SCAN_NORMAL 0
  22. #define SFC_SCAN_ALWAYS 1
  23. #define SFC_SCAN_ONCE 2
  24. #define SFC_SCAN_IMMEDIATE 3
  25. #define SFC_QUOTA_DEFAULT 50
  26. #define SFC_QUOTA_ALL_FILES ((ULONG)-1)
  27. #define SFC_IDLE_TRIGGER L"WFP_IDLE_TRIGGER"
  28. typedef struct _PROTECTED_FILE_DATA {
  29. WCHAR FileName[MAX_PATH];
  30. DWORD FileNumber;
  31. } PROTECTED_FILE_DATA, *PPROTECTED_FILE_DATA;
  32. BOOL
  33. WINAPI
  34. SfcGetNextProtectedFile(
  35. IN HANDLE RpcHandle, // must be NULL
  36. IN PPROTECTED_FILE_DATA ProtFileData
  37. );
  38. BOOL
  39. WINAPI
  40. SfcIsFileProtected(
  41. IN HANDLE RpcHandle, // must be NULL
  42. IN LPCWSTR ProtFileName
  43. );
  44. //
  45. // new APIs which are not currently supported, but are stubbed out
  46. //
  47. BOOL
  48. WINAPI
  49. SfpVerifyFile(
  50. IN LPCSTR pszFileName,
  51. IN LPSTR pszError,
  52. IN DWORD dwErrSize
  53. );
  54. #define SFC_REGISTRY_DEFAULT 0
  55. #define SFC_REGISTRY_OVERRIDE 1
  56. HANDLE
  57. WINAPI
  58. SfcConnectToServer(
  59. IN LPCWSTR ServerName
  60. );
  61. VOID
  62. SfcClose(
  63. IN HANDLE RpcHandle
  64. );
  65. #define SFC_ACTION_ADDED 0x00000001
  66. #define SFC_ACTION_REMOVED 0x00000002
  67. #define SFC_ACTION_MODIFIED 0x00000004
  68. #define SFC_ACTION_RENAMED_OLD_NAME 0x00000008
  69. #define SFC_ACTION_RENAMED_NEW_NAME 0x00000010
  70. DWORD
  71. WINAPI
  72. SfcFileException(
  73. IN HANDLE RpcHandle,
  74. IN PCWSTR FileName,
  75. IN DWORD ExpectedChangeType
  76. );
  77. DWORD
  78. WINAPI
  79. SfcInitiateScan(
  80. IN HANDLE RpcHandle,
  81. IN DWORD ScanWhen
  82. );
  83. ULONG
  84. SfcInitProt(
  85. IN ULONG OverrideRegistry,
  86. IN ULONG ReqDisable,
  87. IN ULONG ReqScan,
  88. IN ULONG ReqQuota,
  89. IN HWND ProgressWindow, OPTIONAL
  90. IN PCWSTR SourcePath, OPTIONAL
  91. IN PCWSTR IgnoreFiles OPTIONAL
  92. );
  93. VOID
  94. SfcTerminateWatcherThread(
  95. VOID
  96. );
  97. #define WM_SFC_NOTIFY (WM_USER+601)
  98. typedef struct _FILEINSTALL_STATUS {
  99. PCWSTR FileName;
  100. DWORDLONG Version;
  101. ULONG Win32Error;
  102. } FILEINSTALL_STATUS, *PFILEINSTALL_STATUS;
  103. typedef BOOL
  104. (CALLBACK *PSFCNOTIFICATIONCALLBACK) (
  105. IN PFILEINSTALL_STATUS FileInstallStatus,
  106. IN DWORD_PTR Context
  107. );
  108. BOOL
  109. WINAPI
  110. SfcInstallProtectedFiles(
  111. IN HANDLE RpcHandle,
  112. IN PCWSTR FileNames,
  113. IN BOOL AllowUI,
  114. IN PCWSTR ClassName,
  115. IN PCWSTR WindowName,
  116. IN PSFCNOTIFICATIONCALLBACK SfcNotificationCallback,
  117. IN DWORD_PTR Context
  118. );
  119. //
  120. // new APIs which are not currently supported, but are stubbed out
  121. //
  122. DWORD
  123. WINAPI
  124. SfpInstallCatalog(
  125. IN LPCSTR pszCatName,
  126. IN LPCSTR pszCatDependency,
  127. IN PVOID Reserved
  128. );
  129. DWORD
  130. WINAPI
  131. SfpDeleteCatalog(
  132. IN LPCSTR pszCatName,
  133. IN PVOID Reserved
  134. );
  135. #ifdef __cplusplus
  136. }
  137. #endif
  138. #endif // _SFC_