Commit 8021d449 authored by Hans Leidekker's avatar Hans Leidekker Committed by Alexandre Julliard

advapi32: Add a stub implementation of SaferIdentifyLevel.

parent 98ea906b
...@@ -717,7 +717,7 @@ ...@@ -717,7 +717,7 @@
@ stdcall SaferCreateLevel(long long long ptr ptr) @ stdcall SaferCreateLevel(long long long ptr ptr)
# @ stub SaferGetLevelInformation # @ stub SaferGetLevelInformation
@ stdcall SaferGetPolicyInformation(long long long ptr ptr ptr) @ stdcall SaferGetPolicyInformation(long long long ptr ptr ptr)
# @ stub SaferIdentifyLevel @ stdcall SaferIdentifyLevel(long ptr ptr ptr)
# @ stub SaferRecordEventLogEntry # @ stub SaferRecordEventLogEntry
@ stdcall SaferSetLevelInformation(ptr long ptr long) @ stdcall SaferSetLevelInformation(ptr long ptr long)
# @ stub SaferSetPolicyInformation # @ stub SaferSetPolicyInformation
......
...@@ -6185,6 +6185,17 @@ BOOL WINAPI SaferGetPolicyInformation(DWORD scope, SAFER_POLICY_INFO_CLASS class ...@@ -6185,6 +6185,17 @@ BOOL WINAPI SaferGetPolicyInformation(DWORD scope, SAFER_POLICY_INFO_CLASS class
} }
/****************************************************************************** /******************************************************************************
* SaferIdentifyLevel [ADVAPI32.@]
*/
BOOL WINAPI SaferIdentifyLevel(DWORD count, SAFER_CODE_PROPERTIES *properties, SAFER_LEVEL_HANDLE *handle,
void *reserved)
{
FIXME("(%u %p %p %p) stub\n", count, properties, handle, reserved);
*handle = (SAFER_LEVEL_HANDLE)0xdeadbeef;
return TRUE;
}
/******************************************************************************
* SaferSetLevelInformation [ADVAPI32.@] * SaferSetLevelInformation [ADVAPI32.@]
*/ */
BOOL WINAPI SaferSetLevelInformation(SAFER_LEVEL_HANDLE handle, SAFER_OBJECT_INFO_CLASS infotype, BOOL WINAPI SaferSetLevelInformation(SAFER_LEVEL_HANDLE handle, SAFER_OBJECT_INFO_CLASS infotype,
......
...@@ -30,6 +30,32 @@ extern "C" { ...@@ -30,6 +30,32 @@ extern "C" {
DECLARE_HANDLE(SAFER_LEVEL_HANDLE); DECLARE_HANDLE(SAFER_LEVEL_HANDLE);
#define SAFER_MAX_HASH_SIZE 64
#include <pshpack8.h>
typedef struct _SAFER_CODE_PROPERTIES_V2 {
DWORD cbSize;
DWORD dwCheckFlags;
LPCWSTR ImagePath;
HANDLE hImageFileHandle;
DWORD UrlZoneId;
BYTE ImageHash[SAFER_MAX_HASH_SIZE];
DWORD dwImageHashSize;
LARGE_INTEGER ImageSize;
ALG_ID HashAlgorithm;
LPBYTE pByteBlock;
HWND hWndParent;
DWORD dwWVTUIChoice;
LPCWSTR PackageMoniker;
LPCWSTR PackagePublisher;
LPCWSTR PackageName;
ULONG64 PackageVersion;
BOOL PackageIsFramework;
} SAFER_CODE_PROPERTIES_V2, *PSAFER_CODE_PROPERTIES_V2;
typedef SAFER_CODE_PROPERTIES_V2 SAFER_CODE_PROPERTIES, *PSAFER_CODE_PROPERTIES;
#include <poppack.h>
#define SAFER_SCOPEID_MACHINE 1 #define SAFER_SCOPEID_MACHINE 1
#define SAFER_SCOPEID_USER 2 #define SAFER_SCOPEID_USER 2
...@@ -41,8 +67,6 @@ DECLARE_HANDLE(SAFER_LEVEL_HANDLE); ...@@ -41,8 +67,6 @@ DECLARE_HANDLE(SAFER_LEVEL_HANDLE);
#define SAFER_LEVEL_OPEN 1 #define SAFER_LEVEL_OPEN 1
WINADVAPI BOOL WINAPI SaferCreateLevel(DWORD,DWORD,DWORD,SAFER_LEVEL_HANDLE*,LPVOID);
typedef enum _SAFER_POLICY_INFO_CLASS { typedef enum _SAFER_POLICY_INFO_CLASS {
SaferPolicyLevelList = 1, SaferPolicyLevelList = 1,
SaferPolicyEnableTransparentEnforcement, SaferPolicyEnableTransparentEnforcement,
...@@ -70,7 +94,9 @@ typedef enum _SAFER_OBJECT_INFO_CLASS { ...@@ -70,7 +94,9 @@ typedef enum _SAFER_OBJECT_INFO_CLASS {
SaferObjectExtendedError SaferObjectExtendedError
} SAFER_OBJECT_INFO_CLASS; } SAFER_OBJECT_INFO_CLASS;
WINADVAPI BOOL WINAPI SaferCreateLevel(DWORD,DWORD,DWORD,SAFER_LEVEL_HANDLE*,LPVOID);
WINADVAPI BOOL WINAPI SaferGetPolicyInformation(DWORD,SAFER_POLICY_INFO_CLASS,DWORD,PVOID,PDWORD,LPVOID); WINADVAPI BOOL WINAPI SaferGetPolicyInformation(DWORD,SAFER_POLICY_INFO_CLASS,DWORD,PVOID,PDWORD,LPVOID);
WINADVAPI BOOL WINAPI SaferIdentifyLevel(DWORD,PSAFER_CODE_PROPERTIES,SAFER_LEVEL_HANDLE*,LPVOID);
WINADVAPI BOOL WINAPI SaferSetLevelInformation(SAFER_LEVEL_HANDLE,SAFER_OBJECT_INFO_CLASS,LPVOID,DWORD); WINADVAPI BOOL WINAPI SaferSetLevelInformation(SAFER_LEVEL_HANDLE,SAFER_OBJECT_INFO_CLASS,LPVOID,DWORD);
#ifdef __cplusplus #ifdef __cplusplus
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment