ReactOS 0.4.16-dev-340-g0540c21
sfc_os.c File Reference
#include <stdarg.h>
#include <windef.h>
#include <winbase.h>
#include <winreg.h>
#include <winuser.h>
#include <winwlx.h>
#include <debug.h>
Include dependency graph for sfc_os.c:

Go to the source code of this file.

Classes

struct  _PROTECTED_FILE_DATA
 

Macros

#define WIN32_NO_STATUS
 
#define NDEBUG
 

Typedefs

typedef struct _PROTECTED_FILE_DATA PROTECTED_FILE_DATA
 
typedef struct _PROTECTED_FILE_DATAPPROTECTED_FILE_DATA
 

Functions

BOOL WINAPI DllMain (HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
 
BOOL WINAPI SfcIsFileProtected (HANDLE RpcHandle, LPCWSTR ProtFileName)
 
BOOL WINAPI SfcIsKeyProtected (HKEY hKey, LPCWSTR lpSubKey, REGSAM samDesired)
 
BOOL WINAPI SfcGetNextProtectedFile (HANDLE RpcHandle, PPROTECTED_FILE_DATA ProtFileData)
 
DWORD WINAPI SfcFileException (DWORD dwUnknown0, PWCHAR pwszFile, DWORD dwUnknown1)
 
VOID WINAPI SfcWLEventLogoff (PWLX_NOTIFICATION_INFO pInfo)
 
VOID WINAPI SfcWLEventLogon (PWLX_NOTIFICATION_INFO pInfo)
 

Variables

HINSTANCE hLibModule
 

Macro Definition Documentation

◆ NDEBUG

#define NDEBUG

Definition at line 31 of file sfc_os.c.

◆ WIN32_NO_STATUS

#define WIN32_NO_STATUS

Definition at line 23 of file sfc_os.c.

Typedef Documentation

◆ PPROTECTED_FILE_DATA

◆ PROTECTED_FILE_DATA

Function Documentation

◆ DllMain()

BOOL WINAPI DllMain ( HINSTANCE  hinstDLL,
DWORD  fdwReason,
LPVOID  lpvReserved 
)

Definition at line 43 of file sfc_os.c.

44{
45 switch (fdwReason)
46 {
48 {
50 hLibModule = hinstDLL;
51 break;
52 }
54 {
55 break;
56 }
57 }
58
59 return TRUE;
60}
#define TRUE
Definition: types.h:120
#define DLL_PROCESS_ATTACH
Definition: compat.h:131
#define DLL_PROCESS_DETACH
Definition: compat.h:130
BOOL WINAPI DisableThreadLibraryCalls(IN HMODULE hLibModule)
Definition: loader.c:85
HINSTANCE hLibModule
Definition: sfc_os.c:34

◆ SfcFileException()

DWORD WINAPI SfcFileException ( DWORD  dwUnknown0,
PWCHAR  pwszFile,
DWORD  dwUnknown1 
)

Definition at line 170 of file sfc_os.c.

171{
173 /* Always return success */
174 return 0;
175}
#define UNIMPLEMENTED
Definition: ntoskrnl.c:15

◆ SfcGetNextProtectedFile()

BOOL WINAPI SfcGetNextProtectedFile ( HANDLE  RpcHandle,
PPROTECTED_FILE_DATA  ProtFileData 
)

Definition at line 142 of file sfc_os.c.

143{
144 if (!ProtFileData)
145 {
147 return FALSE;
148 }
149
152 return FALSE;
153}
#define FALSE
Definition: types.h:117
#define ERROR_INVALID_PARAMETER
Definition: compat.h:101
#define SetLastError(x)
Definition: compat.h:752
#define ERROR_NO_MORE_FILES
Definition: winerror.h:121

Referenced by START_TEST().

◆ SfcIsFileProtected()

BOOL WINAPI SfcIsFileProtected ( HANDLE  RpcHandle,
LPCWSTR  ProtFileName 
)

Definition at line 83 of file sfc_os.c.

84{
85 static BOOL reported = FALSE;
86
87 if (reported) {
88 DPRINT("(%p, %S) stub\n", RpcHandle, ProtFileName);
89 }
90 else
91 {
92 DPRINT1("(%p, %S) stub\n", RpcHandle, ProtFileName);
93 reported = TRUE;
94 }
95
97 return FALSE;
98}
LPCWSTR ProtFileName
#define DPRINT1
Definition: precomp.h:8
unsigned int BOOL
Definition: ntddk_ex.h:94
#define ERROR_FILE_NOT_FOUND
Definition: disk.h:79
#define DPRINT
Definition: sndvol32.h:73

Referenced by CLayerUIPropPage::InitFile(), START_TEST(), and Test_ProtectedFiles().

◆ SfcIsKeyProtected()

BOOL WINAPI SfcIsKeyProtected ( HKEY  hKey,
LPCWSTR  lpSubKey,
REGSAM  samDesired 
)

Definition at line 117 of file sfc_os.c.

118{
119 static BOOL reported = FALSE;
120
121 if (reported) {
122 DPRINT("(%p, %S) stub\n", hKey, lpSubKey);
123 }
124 else
125 {
126 DPRINT1("(%p, %S) stub\n", hKey, lpSubKey);
127 reported = TRUE;
128 }
129
130 if( !hKey ) {
132 return FALSE;
133 }
134
136 return FALSE;
137}
#define ERROR_INVALID_HANDLE
Definition: compat.h:98
FxAutoRegKey hKey

Referenced by START_TEST().

◆ SfcWLEventLogoff()

VOID WINAPI SfcWLEventLogoff ( PWLX_NOTIFICATION_INFO  pInfo)

Definition at line 191 of file sfc_os.c.

193{
195}

◆ SfcWLEventLogon()

VOID WINAPI SfcWLEventLogon ( PWLX_NOTIFICATION_INFO  pInfo)

Definition at line 211 of file sfc_os.c.

213{
215}

Variable Documentation

◆ hLibModule

HINSTANCE hLibModule

Definition at line 34 of file sfc_os.c.

Referenced by DllMain().