ReactOS  0.4.13-dev-482-ge57f103
winsafer.h File Reference
#include <guiddef.h>
#include <wincrypt.h>
#include <pshpack8.h>
#include <poppack.h>
Include dependency graph for winsafer.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  _SAFER_CODE_PROPERTIES_V1
 
struct  _SAFER_CODE_PROPERTIES_V2
 
struct  _SAFER_IDENTIFICATION_HEADER
 
struct  _SAFER_PATHNAME_IDENTIFICATION
 
struct  _SAFER_HASH_IDENTIFICATION
 
struct  _SAFER_HASH_IDENTIFICATION2
 
struct  _SAFER_URLZONE_IDENTIFICATION
 

Macros

#define _WINSAFER_H
 
#define SAFER_SCOPEID_MACHINE   1
 
#define SAFER_SCOPEID_USER   2
 
#define SAFER_LEVELID_DISALLOWED   0x00000
 
#define SAFER_LEVELID_UNTRUSTED   0x01000
 
#define SAFER_LEVELID_CONSTRAINED   0x10000
 
#define SAFER_LEVELID_NORMALUSER   0x20000
 
#define SAFER_LEVELID_FULLYTRUSTED   0x40000
 
#define SAFER_LEVEL_OPEN   1
 
#define SAFER_MAX_HASH_SIZE   64
 
#define SAFER_MAX_DESCRIPTION_SIZE   256
 
#define SAFER_MAX_FRIENDLYNAME_SIZE   256
 
#define SAFER_TOKEN_NULL_IF_EQUAL   0x1
 
#define SAFER_TOKEN_COMPARE_ONLY   0x2
 
#define SAFER_TOKEN_MAKE_INERT   0x4
 
#define SAFER_TOKEN_WANT_FLAGS   0x8
 
#define SAFER_CRITERIA_IMAGEPATH   0x0001
 
#define SAFER_CRITERIA_NOSIGNEDHASH   0x0002
 
#define SAFER_CRITERIA_IMAGEHASH   0x0004
 
#define SAFER_CRITERIA_AUTHENTICODE   0x0008
 
#define SAFER_CRITERIA_URLZONE   0x0010
 
#define SAFER_CRITERIA_APPX_PACKAGE   0x0020
 
#define SAFER_CRITERIA_IMAGEPATH_NT   0x1000
 
#define SAFER_POLICY_JOBID_UNTRUSTED   0x03000000
 
#define SAFER_POLICY_JOBID_CONSTRAINED   0x04000000
 
#define SAFER_POLICY_JOBID_MASK   0xFF000000
 
#define SAFER_POLICY_ONLY_EXES   0x00010000
 
#define SAFER_POLICY_SANDBOX_INERT   0x00020000
 
#define SAFER_POLICY_HASH_DUPLICATE   0x00040000
 
#define SAFER_POLICY_ONLY_AUDIT   0x00001000
 
#define SAFER_POLICY_BLOCK_CLIENT_UI   0x00002000
 
#define SAFER_POLICY_UIFLAGS_INFORMATION_PROMPT   0x00000001
 
#define SAFER_POLICY_UIFLAGS_OPTION_PROMPT   0x00000002
 
#define SAFER_POLICY_UIFLAGS_HIDDEN   0x00000004
 
#define SAFER_POLICY_UIFLAGS_MASK   0x000000FF
 
#define SRP_POLICY_EXE   L"EXE"
 
#define SRP_POLICY_DLL   L"DLL"
 
#define SRP_POLICY_MSI   L"MSI"
 
#define SRP_POLICY_SCRIPT   L"SCRIPT"
 
#define SRP_POLICY_SHELL   L"SHELL"
 
#define SRP_POLICY_NOV2   L"IGNORESRPV2"
 
#define SRP_POLICY_APPX   L"APPX"
 
#define SRP_POLICY_WLDPMSI   L"WLDPMSI"
 
#define SRP_POLICY_WLDPSCRIPT   L"WLDPSCRIPT"
 

Typedefs

typedef struct _SAFER_CODE_PROPERTIES_V1 SAFER_CODE_PROPERTIES_V1
 
typedef struct _SAFER_CODE_PROPERTIES_V1PSAFER_CODE_PROPERTIES_V1
 
typedef struct _SAFER_CODE_PROPERTIES_V2 SAFER_CODE_PROPERTIES_V2
 
typedef struct _SAFER_CODE_PROPERTIES_V2PSAFER_CODE_PROPERTIES_V2
 
typedef SAFER_CODE_PROPERTIES_V1 SAFER_CODE_PROPERTIES
 
typedef SAFER_CODE_PROPERTIES_V1PSAFER_CODE_PROPERTIES
 
typedef enum _SAFER_OBJECT_INFO_CLASS SAFER_OBJECT_INFO_CLASS
 
typedef enum _SAFER_POLICY_INFO_CLASS SAFER_POLICY_INFO_CLASS
 
typedef enum _SAFER_IDENTIFICATION_TYPES SAFER_IDENTIFICATION_TYPES
 
typedef struct _SAFER_IDENTIFICATION_HEADER SAFER_IDENTIFICATION_HEADER
 
typedef struct _SAFER_IDENTIFICATION_HEADERPSAFER_IDENTIFICATION_HEADER
 
typedef struct _SAFER_PATHNAME_IDENTIFICATION SAFER_PATHNAME_IDENTIFICATION
 
typedef struct _SAFER_PATHNAME_IDENTIFICATIONPSAFER_PATHNAME_IDENTIFICATION
 
typedef struct _SAFER_HASH_IDENTIFICATION SAFER_HASH_IDENTIFICATION
 
typedef struct _SAFER_HASH_IDENTIFICATIONPSAFER_HASH_IDENTIFICATION
 
typedef struct _SAFER_HASH_IDENTIFICATION2 SAFER_HASH_IDENTIFICATION2
 
typedef struct _SAFER_HASH_IDENTIFICATION2PSAFER_HASH_IDENTIFICATION2
 
typedef struct _SAFER_URLZONE_IDENTIFICATION SAFER_URLZONE_IDENTIFICATION
 
typedef struct _SAFER_URLZONE_IDENTIFICATIONPSAFER_URLZONE_IDENTIFICATION
 

Enumerations

enum  _SAFER_OBJECT_INFO_CLASS {
  SaferObjectLevelId = 1, SaferObjectScopeId = 2, SaferObjectFriendlyName = 3, SaferObjectDescription = 4,
  SaferObjectBuiltin = 5, SaferObjectDisallowed = 6, SaferObjectDisableMaxPrivilege = 7, SaferObjectInvertDeletedPrivileges = 8,
  SaferObjectDeletedPrivileges = 9, SaferObjectDefaultOwner = 10, SaferObjectSidsToDisable = 11, SaferObjectRestrictedSidsInverted = 12,
  SaferObjectRestrictedSidsAdded = 13, SaferObjectAllIdentificationGuids = 14, SaferObjectSingleIdentification = 15, SaferObjectExtendedError = 16
}
 
enum  _SAFER_POLICY_INFO_CLASS {
  SaferPolicyLevelList = 1, SaferPolicyEnableTransparentEnforcement = 2, SaferPolicyDefaultLevel = 3, SaferPolicyEvaluateUserScope = 4,
  SaferPolicyScopeFlags = 5, SaferPolicyDefaultLevelFlags = 6, SaferPolicyAuthenticodeEnabled = 7
}
 
enum  _SAFER_IDENTIFICATION_TYPES {
  SaferIdentityDefault = 0, SaferIdentityTypeImageName = 1, SaferIdentityTypeImageHash = 2, SaferIdentityTypeUrlZone = 3,
  SaferIdentityTypeCertificate = 4
}
 

Functions

 DECLARE_HANDLE (SAFER_LEVEL_HANDLE)
 
WINADVAPI BOOL WINAPI SaferCloseLevel (_In_ SAFER_LEVEL_HANDLE hLevelHandle)
 
WINADVAPI BOOL WINAPI SaferComputeTokenFromLevel (_In_ SAFER_LEVEL_HANDLE LevelHandle, _In_opt_ HANDLE InAccessToken, _Out_ PHANDLE OutAccessToken, _In_ DWORD dwFlags, _Inout_opt_ PVOID pReserved)
 
WINADVAPI BOOL WINAPI SaferCreateLevel (_In_ DWORD dwScopeId, _In_ DWORD dwLevelId, _In_ DWORD OpenFlags, _Outptr_ SAFER_LEVEL_HANDLE *pLevelHandle, _Reserved_ PVOID pReserved)
 
WINADVAPI BOOL WINAPI SaferGetLevelInformation (_In_ SAFER_LEVEL_HANDLE LevelHandle, _In_ SAFER_OBJECT_INFO_CLASS dwInfoType, _Out_writes_bytes_opt_(dwInBufferSize) PVOID pQueryBuffer, _In_ DWORD dwInBufferSize, _Out_ PDWORD pdwOutBufferSize)
 
WINADVAPI BOOL WINAPI SaferGetPolicyInformation (_In_ DWORD dwScopeId, _In_ SAFER_POLICY_INFO_CLASS SaferPolicyInfoClass, _In_ DWORD InfoBufferSize, _Out_writes_bytes_opt_(InfoBufferSize) PVOID InfoBuffer, _Out_ PDWORD InfoBufferRetSize, _Reserved_ PVOID pReserved)
 
WINADVAPI BOOL WINAPI SaferIdentifyLevel (_In_ DWORD dwNumProperties, _In_reads_opt_(dwNumProperties) PSAFER_CODE_PROPERTIES pCodeProperties, _Outptr_ SAFER_LEVEL_HANDLE *pLevelHandle, _Reserved_ PVOID pReserved)
 
WINADVAPI BOOL WINAPI SaferiIsExecutableFileType (_In_ PCWSTR szFullPath, _In_ BOOLEAN bFromShellExecute)
 
WINADVAPI BOOL WINAPI SaferRecordEventLogEntry (_In_ SAFER_LEVEL_HANDLE hLevel, _In_ PCWSTR szTargetPath, _Reserved_ PVOID pReserved)
 
WINADVAPI BOOL WINAPI SaferSetLevelInformation (_In_ SAFER_LEVEL_HANDLE LevelHandle, _In_ SAFER_OBJECT_INFO_CLASS dwInfoType, _In_reads_bytes_(dwInBufferSize) PVOID pQueryBuffer, _In_ DWORD dwInBufferSize)
 
WINADVAPI BOOL WINAPI SaferSetPolicyInformation (_In_ DWORD dwScopeId, _In_ SAFER_POLICY_INFO_CLASS SaferPolicyInfoClass, _In_ DWORD InfoBufferSize, _In_reads_bytes_(InfoBufferSize) PVOID InfoBuffer, _Reserved_ PVOID pReserved)
 

Macro Definition Documentation

◆ _WINSAFER_H

#define _WINSAFER_H

Definition at line 23 of file winsafer.h.

◆ SAFER_CRITERIA_APPX_PACKAGE

#define SAFER_CRITERIA_APPX_PACKAGE   0x0020

Definition at line 59 of file winsafer.h.

◆ SAFER_CRITERIA_AUTHENTICODE

#define SAFER_CRITERIA_AUTHENTICODE   0x0008

Definition at line 57 of file winsafer.h.

◆ SAFER_CRITERIA_IMAGEHASH

#define SAFER_CRITERIA_IMAGEHASH   0x0004

Definition at line 56 of file winsafer.h.

◆ SAFER_CRITERIA_IMAGEPATH

#define SAFER_CRITERIA_IMAGEPATH   0x0001

Definition at line 54 of file winsafer.h.

◆ SAFER_CRITERIA_IMAGEPATH_NT

#define SAFER_CRITERIA_IMAGEPATH_NT   0x1000

Definition at line 60 of file winsafer.h.

◆ SAFER_CRITERIA_NOSIGNEDHASH

#define SAFER_CRITERIA_NOSIGNEDHASH   0x0002

Definition at line 55 of file winsafer.h.

◆ SAFER_CRITERIA_URLZONE

#define SAFER_CRITERIA_URLZONE   0x0010

Definition at line 58 of file winsafer.h.

◆ SAFER_LEVEL_OPEN

#define SAFER_LEVEL_OPEN   1

Definition at line 43 of file winsafer.h.

◆ SAFER_LEVELID_CONSTRAINED

#define SAFER_LEVELID_CONSTRAINED   0x10000

Definition at line 39 of file winsafer.h.

◆ SAFER_LEVELID_DISALLOWED

#define SAFER_LEVELID_DISALLOWED   0x00000

Definition at line 37 of file winsafer.h.

◆ SAFER_LEVELID_FULLYTRUSTED

#define SAFER_LEVELID_FULLYTRUSTED   0x40000

Definition at line 41 of file winsafer.h.

◆ SAFER_LEVELID_NORMALUSER

#define SAFER_LEVELID_NORMALUSER   0x20000

Definition at line 40 of file winsafer.h.

◆ SAFER_LEVELID_UNTRUSTED

#define SAFER_LEVELID_UNTRUSTED   0x01000

Definition at line 38 of file winsafer.h.

◆ SAFER_MAX_DESCRIPTION_SIZE

#define SAFER_MAX_DESCRIPTION_SIZE   256

Definition at line 46 of file winsafer.h.

◆ SAFER_MAX_FRIENDLYNAME_SIZE

#define SAFER_MAX_FRIENDLYNAME_SIZE   256

Definition at line 47 of file winsafer.h.

◆ SAFER_MAX_HASH_SIZE

#define SAFER_MAX_HASH_SIZE   64

Definition at line 45 of file winsafer.h.

◆ SAFER_POLICY_BLOCK_CLIENT_UI

#define SAFER_POLICY_BLOCK_CLIENT_UI   0x00002000

Definition at line 69 of file winsafer.h.

◆ SAFER_POLICY_HASH_DUPLICATE

#define SAFER_POLICY_HASH_DUPLICATE   0x00040000

Definition at line 67 of file winsafer.h.

◆ SAFER_POLICY_JOBID_CONSTRAINED

#define SAFER_POLICY_JOBID_CONSTRAINED   0x04000000

Definition at line 63 of file winsafer.h.

◆ SAFER_POLICY_JOBID_MASK

#define SAFER_POLICY_JOBID_MASK   0xFF000000

Definition at line 64 of file winsafer.h.

◆ SAFER_POLICY_JOBID_UNTRUSTED

#define SAFER_POLICY_JOBID_UNTRUSTED   0x03000000

Definition at line 62 of file winsafer.h.

◆ SAFER_POLICY_ONLY_AUDIT

#define SAFER_POLICY_ONLY_AUDIT   0x00001000

Definition at line 68 of file winsafer.h.

◆ SAFER_POLICY_ONLY_EXES

#define SAFER_POLICY_ONLY_EXES   0x00010000

Definition at line 65 of file winsafer.h.

◆ SAFER_POLICY_SANDBOX_INERT

#define SAFER_POLICY_SANDBOX_INERT   0x00020000

Definition at line 66 of file winsafer.h.

◆ SAFER_POLICY_UIFLAGS_HIDDEN

#define SAFER_POLICY_UIFLAGS_HIDDEN   0x00000004

Definition at line 72 of file winsafer.h.

◆ SAFER_POLICY_UIFLAGS_INFORMATION_PROMPT

#define SAFER_POLICY_UIFLAGS_INFORMATION_PROMPT   0x00000001

Definition at line 70 of file winsafer.h.

◆ SAFER_POLICY_UIFLAGS_MASK

#define SAFER_POLICY_UIFLAGS_MASK   0x000000FF

Definition at line 73 of file winsafer.h.

◆ SAFER_POLICY_UIFLAGS_OPTION_PROMPT

#define SAFER_POLICY_UIFLAGS_OPTION_PROMPT   0x00000002

Definition at line 71 of file winsafer.h.

◆ SAFER_SCOPEID_MACHINE

#define SAFER_SCOPEID_MACHINE   1

Definition at line 34 of file winsafer.h.

◆ SAFER_SCOPEID_USER

#define SAFER_SCOPEID_USER   2

Definition at line 35 of file winsafer.h.

◆ SAFER_TOKEN_COMPARE_ONLY

#define SAFER_TOKEN_COMPARE_ONLY   0x2

Definition at line 50 of file winsafer.h.

◆ SAFER_TOKEN_MAKE_INERT

#define SAFER_TOKEN_MAKE_INERT   0x4

Definition at line 51 of file winsafer.h.

◆ SAFER_TOKEN_NULL_IF_EQUAL

#define SAFER_TOKEN_NULL_IF_EQUAL   0x1

Definition at line 49 of file winsafer.h.

◆ SAFER_TOKEN_WANT_FLAGS

#define SAFER_TOKEN_WANT_FLAGS   0x8

Definition at line 52 of file winsafer.h.

◆ SRP_POLICY_APPX

#define SRP_POLICY_APPX   L"APPX"

Definition at line 299 of file winsafer.h.

◆ SRP_POLICY_DLL

#define SRP_POLICY_DLL   L"DLL"

Definition at line 294 of file winsafer.h.

◆ SRP_POLICY_EXE

#define SRP_POLICY_EXE   L"EXE"

Definition at line 293 of file winsafer.h.

◆ SRP_POLICY_MSI

#define SRP_POLICY_MSI   L"MSI"

Definition at line 295 of file winsafer.h.

◆ SRP_POLICY_NOV2

#define SRP_POLICY_NOV2   L"IGNORESRPV2"

Definition at line 298 of file winsafer.h.

◆ SRP_POLICY_SCRIPT

#define SRP_POLICY_SCRIPT   L"SCRIPT"

Definition at line 296 of file winsafer.h.

◆ SRP_POLICY_SHELL

#define SRP_POLICY_SHELL   L"SHELL"

Definition at line 297 of file winsafer.h.

◆ SRP_POLICY_WLDPMSI

#define SRP_POLICY_WLDPMSI   L"WLDPMSI"

Definition at line 300 of file winsafer.h.

◆ SRP_POLICY_WLDPSCRIPT

#define SRP_POLICY_WLDPSCRIPT   L"WLDPSCRIPT"

Definition at line 301 of file winsafer.h.

Typedef Documentation

◆ PSAFER_CODE_PROPERTIES

Definition at line 111 of file winsafer.h.

◆ PSAFER_CODE_PROPERTIES_V1

◆ PSAFER_CODE_PROPERTIES_V2

◆ PSAFER_HASH_IDENTIFICATION

◆ PSAFER_HASH_IDENTIFICATION2

◆ PSAFER_IDENTIFICATION_HEADER

◆ PSAFER_PATHNAME_IDENTIFICATION

◆ PSAFER_URLZONE_IDENTIFICATION

◆ SAFER_CODE_PROPERTIES

Definition at line 111 of file winsafer.h.

◆ SAFER_CODE_PROPERTIES_V1

◆ SAFER_CODE_PROPERTIES_V2

◆ SAFER_HASH_IDENTIFICATION

◆ SAFER_HASH_IDENTIFICATION2

◆ SAFER_IDENTIFICATION_HEADER

◆ SAFER_IDENTIFICATION_TYPES

◆ SAFER_OBJECT_INFO_CLASS

◆ SAFER_PATHNAME_IDENTIFICATION

◆ SAFER_POLICY_INFO_CLASS

◆ SAFER_URLZONE_IDENTIFICATION

Enumeration Type Documentation

◆ _SAFER_IDENTIFICATION_TYPES

Enumerator
SaferIdentityDefault 
SaferIdentityTypeImageName 
SaferIdentityTypeImageHash 
SaferIdentityTypeUrlZone 
SaferIdentityTypeCertificate 

Definition at line 145 of file winsafer.h.

◆ _SAFER_OBJECT_INFO_CLASS

Enumerator
SaferObjectLevelId 
SaferObjectScopeId 
SaferObjectFriendlyName 
SaferObjectDescription 
SaferObjectBuiltin 
SaferObjectDisallowed 
SaferObjectDisableMaxPrivilege 
SaferObjectInvertDeletedPrivileges 
SaferObjectDeletedPrivileges 
SaferObjectDefaultOwner 
SaferObjectSidsToDisable 
SaferObjectRestrictedSidsInverted 
SaferObjectRestrictedSidsAdded 
SaferObjectAllIdentificationGuids 
SaferObjectSingleIdentification 
SaferObjectExtendedError 

Definition at line 114 of file winsafer.h.

115 {
116  SaferObjectLevelId = 1,
117  SaferObjectScopeId = 2,
120  SaferObjectBuiltin = 5,
enum _SAFER_OBJECT_INFO_CLASS SAFER_OBJECT_INFO_CLASS

◆ _SAFER_POLICY_INFO_CLASS

Enumerator
SaferPolicyLevelList 
SaferPolicyEnableTransparentEnforcement 
SaferPolicyDefaultLevel 
SaferPolicyEvaluateUserScope 
SaferPolicyScopeFlags 
SaferPolicyDefaultLevelFlags 
SaferPolicyAuthenticodeEnabled 

Definition at line 134 of file winsafer.h.

Function Documentation

◆ DECLARE_HANDLE()

DECLARE_HANDLE ( SAFER_LEVEL_HANDLE  )

◆ SaferCloseLevel()

WINADVAPI BOOL WINAPI SaferCloseLevel ( _In_ SAFER_LEVEL_HANDLE  hLevelHandle)

Definition at line 80 of file safer.c.

82 {
83  FIXME("(%p) stub\n", hLevelHandle);
84  if (hLevelHandle != (SAFER_LEVEL_HANDLE)0x42)
85  {
87  return FALSE;
88  }
89  return TRUE;
90 }
#define TRUE
Definition: types.h:120
#define ERROR_INVALID_HANDLE
Definition: compat.h:88
#define FIXME(fmt,...)
Definition: debug.h:110
#define SetLastError(x)
Definition: compat.h:409

Referenced by START_TEST().

◆ SaferComputeTokenFromLevel()

WINADVAPI BOOL WINAPI SaferComputeTokenFromLevel ( _In_ SAFER_LEVEL_HANDLE  LevelHandle,
_In_opt_ HANDLE  InAccessToken,
_Out_ PHANDLE  OutAccessToken,
_In_ DWORD  dwFlags,
_Inout_opt_ PVOID  pReserved 
)

Definition at line 150 of file safer.c.

156 {
157  FIXME("(%p, %p, %p, 0x%lx, %p) stub\n", LevelHandle, InAccessToken, OutAccessToken, dwFlags, pReserved);
159  return FALSE;
160 }
#define FIXME(fmt,...)
Definition: debug.h:110
#define SetLastError(x)
Definition: compat.h:409
_In_ PCCERT_CONTEXT _In_ DWORD dwFlags
Definition: wincrypt.h:1175
#define ERROR_CALL_NOT_IMPLEMENTED
Definition: compat.h:92

◆ SaferCreateLevel()

WINADVAPI BOOL WINAPI SaferCreateLevel ( _In_ DWORD  dwScopeId,
_In_ DWORD  dwLevelId,
_In_ DWORD  OpenFlags,
_Outptr_ SAFER_LEVEL_HANDLE *  pLevelHandle,
_Reserved_ PVOID  pReserved 
)

Definition at line 23 of file safer.c.

29 {
30  FIXME("(%lu, %lu, %lu, %p, %p) stub\n", dwScopeId, dwLevelId, OpenFlags, pLevelHandle, pReserved);
31  *pLevelHandle = (SAFER_LEVEL_HANDLE)0x42;
32  return TRUE;
33 }
#define TRUE
Definition: types.h:120
#define FIXME(fmt,...)
Definition: debug.h:110

◆ SaferGetLevelInformation()

WINADVAPI BOOL WINAPI SaferGetLevelInformation ( _In_ SAFER_LEVEL_HANDLE  LevelHandle,
_In_ SAFER_OBJECT_INFO_CLASS  dwInfoType,
_Out_writes_bytes_opt_(dwInBufferSize) PVOID  pQueryBuffer,
_In_ DWORD  dwInBufferSize,
_Out_ PDWORD  pdwOutBufferSize 
)

◆ SaferGetPolicyInformation()

WINADVAPI BOOL WINAPI SaferGetPolicyInformation ( _In_ DWORD  dwScopeId,
_In_ SAFER_POLICY_INFO_CLASS  SaferPolicyInfoClass,
_In_ DWORD  InfoBufferSize,
_Out_writes_bytes_opt_(InfoBufferSize) PVOID  InfoBuffer,
_Out_ PDWORD  InfoBufferRetSize,
_Reserved_ PVOID  pReserved 
)

Definition at line 119 of file safer.c.

126 {
127  FIXME("(%lu, %d, %lu, %p, %p, %p) stub\n", dwScopeId, SaferPolicyInfoClass, InfoBufferSize, InfoBuffer, InfoBufferRetSize, pReserved);
129  return FALSE;
130 }
#define FIXME(fmt,...)
Definition: debug.h:110
#define SetLastError(x)
Definition: compat.h:409
#define ERROR_CALL_NOT_IMPLEMENTED
Definition: compat.h:92

◆ SaferIdentifyLevel()

WINADVAPI BOOL WINAPI SaferIdentifyLevel ( _In_ DWORD  dwNumProperties,
_In_reads_opt_(dwNumProperties) PSAFER_CODE_PROPERTIES  pCodeProperties,
_Outptr_ SAFER_LEVEL_HANDLE *  pLevelHandle,
_Reserved_ PVOID  pReserved 
)

Definition at line 43 of file safer.c.

48 {
49  DWORD i;
50 
51  if (pLevelHandle == NULL)
52  {
54  return FALSE;
55  }
56 
57  for (i = 0; i < dwNumProperties; i++)
58  {
59  if (pCodeProperties[i].cbSize != sizeof(SAFER_CODE_PROPERTIES_V1))
60  {
62  return FALSE;
63  }
64  }
65 
66  FIXME("(%lu, %p, %p, %p) stub\n", dwNumProperties, pCodeProperties, pLevelHandle, pReserved);
67 
68  *pLevelHandle = (SAFER_LEVEL_HANDLE)0x42;
69  return TRUE;
70 }
#define TRUE
Definition: types.h:120
#define ERROR_BAD_LENGTH
Definition: winerror.h:127
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
#define ERROR_NOACCESS
Definition: winerror.h:578
#define FIXME(fmt,...)
Definition: debug.h:110
smooth NULL
Definition: ftsmooth.c:416
unsigned long DWORD
Definition: ntddk_ex.h:95
#define SetLastError(x)
Definition: compat.h:409

◆ SaferiIsExecutableFileType()

WINADVAPI BOOL WINAPI SaferiIsExecutableFileType ( _In_ PCWSTR  szFullPath,
_In_ BOOLEAN  bFromShellExecute 
)

◆ SaferRecordEventLogEntry()

WINADVAPI BOOL WINAPI SaferRecordEventLogEntry ( _In_ SAFER_LEVEL_HANDLE  hLevel,
_In_ PCWSTR  szTargetPath,
_Reserved_ PVOID  pReserved 
)

Definition at line 170 of file safer.c.

174 {
175  FIXME("(%p, %s, %p) stub\n", hLevel, wine_dbgstr_w(szTargetPath), pReserved);
177  return FALSE;
178 }
#define wine_dbgstr_w
Definition: kernel32.h:34
#define FIXME(fmt,...)
Definition: debug.h:110
#define SetLastError(x)
Definition: compat.h:409
#define ERROR_CALL_NOT_IMPLEMENTED
Definition: compat.h:92

◆ SaferSetLevelInformation()

WINADVAPI BOOL WINAPI SaferSetLevelInformation ( _In_ SAFER_LEVEL_HANDLE  LevelHandle,
_In_ SAFER_OBJECT_INFO_CLASS  dwInfoType,
_In_reads_bytes_(dwInBufferSize) PVOID  pQueryBuffer,
_In_ DWORD  dwInBufferSize 
)

◆ SaferSetPolicyInformation()

WINADVAPI BOOL WINAPI SaferSetPolicyInformation ( _In_ DWORD  dwScopeId,
_In_ SAFER_POLICY_INFO_CLASS  SaferPolicyInfoClass,
_In_ DWORD  InfoBufferSize,
_In_reads_bytes_(InfoBufferSize) PVOID  InfoBuffer,
_Reserved_ PVOID  pReserved 
)