Fix some issues reported by winapi_check:
Add mscat.h and wintrust.h; update wincrypt.h. Fix the CryptCATAdminAcquireContext() and WinVerifyTrust() prototypes so they use the proper types. Update the wintrust section of win32.api.
This commit is contained in:
parent
a4b013c9f2
commit
85ae255f96
|
@ -24,6 +24,8 @@
|
||||||
#include "winbase.h"
|
#include "winbase.h"
|
||||||
#include "winerror.h"
|
#include "winerror.h"
|
||||||
#include "guiddef.h"
|
#include "guiddef.h"
|
||||||
|
#include "wintrust.h"
|
||||||
|
#include "mscat.h"
|
||||||
|
|
||||||
#include "wine/debug.h"
|
#include "wine/debug.h"
|
||||||
|
|
||||||
|
@ -32,8 +34,8 @@ WINE_DEFAULT_DEBUG_CHANNEL(wintrust);
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
* CryptCATAdminAcquireContext (WINTRUST.@)
|
* CryptCATAdminAcquireContext (WINTRUST.@)
|
||||||
*/
|
*/
|
||||||
BOOL WINAPI CryptCATAdminAcquireContext(/* HCATADMIN */ void *catAdmin,
|
BOOL WINAPI CryptCATAdminAcquireContext(HCATADMIN* catAdmin,
|
||||||
GUID *sysSystem, DWORD dwFlags )
|
const GUID *sysSystem, DWORD dwFlags )
|
||||||
{
|
{
|
||||||
FIXME("%p %s %lx\n", catAdmin, debugstr_guid(sysSystem), dwFlags);
|
FIXME("%p %s %lx\n", catAdmin, debugstr_guid(sysSystem), dwFlags);
|
||||||
SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
|
SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
|
||||||
|
@ -43,7 +45,7 @@ BOOL WINAPI CryptCATAdminAcquireContext(/* HCATADMIN */ void *catAdmin,
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
* WinVerifyTrust (WINTRUST.@)
|
* WinVerifyTrust (WINTRUST.@)
|
||||||
*/
|
*/
|
||||||
LONG WINAPI WinVerifyTrust( HWND hwnd, GUID *ActionID, LPVOID ActionData )
|
LONG WINAPI WinVerifyTrust( HWND hwnd, GUID *ActionID, WINTRUST_DATA* ActionData )
|
||||||
{
|
{
|
||||||
FIXME("(hwnd %p ActionId %p ActionData %p): stub (nothing will be verified)\n",
|
FIXME("(hwnd %p ActionId %p ActionData %p): stub (nothing will be verified)\n",
|
||||||
hwnd, ActionID, ActionData);
|
hwnd, ActionID, ActionData);
|
||||||
|
|
|
@ -154,6 +154,7 @@ WINDOWS_INCLUDES = \
|
||||||
msacm.h \
|
msacm.h \
|
||||||
msacmdlg.h \
|
msacmdlg.h \
|
||||||
msacmdrv.h \
|
msacmdrv.h \
|
||||||
|
mscat.h \
|
||||||
msi.h \
|
msi.h \
|
||||||
msiquery.h \
|
msiquery.h \
|
||||||
mssip.h \
|
mssip.h \
|
||||||
|
@ -238,6 +239,7 @@ WINDOWS_INCLUDES = \
|
||||||
wintab.h \
|
wintab.h \
|
||||||
wintabx.h \
|
wintabx.h \
|
||||||
winternl.h \
|
winternl.h \
|
||||||
|
wintrust.h \
|
||||||
winuser.h \
|
winuser.h \
|
||||||
winver.h \
|
winver.h \
|
||||||
wnaspi32.h \
|
wnaspi32.h \
|
||||||
|
|
|
@ -0,0 +1,35 @@
|
||||||
|
/*
|
||||||
|
* Copyright (C) 2004 Francois Gouget
|
||||||
|
*
|
||||||
|
* This library is free software; you can redistribute it and/or
|
||||||
|
* modify it under the terms of the GNU Lesser General Public
|
||||||
|
* License as published by the Free Software Foundation; either
|
||||||
|
* version 2.1 of the License, or (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This library is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||||
|
* Lesser General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU Lesser General Public
|
||||||
|
* License along with this library; if not, write to the Free Software
|
||||||
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef __WINE_MSCAT_H
|
||||||
|
#define __WINE_MSCAT_H
|
||||||
|
|
||||||
|
typedef HANDLE HCATADMIN;
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C" {
|
||||||
|
#endif
|
||||||
|
|
||||||
|
BOOL WINAPI CryptCATAdminAcquireContext(HCATADMIN*,const GUID*,DWORD);
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
|
@ -234,6 +234,17 @@ typedef struct _CTL_CONTEXT {
|
||||||
} CTL_CONTEXT, *PCTL_CONTEXT;
|
} CTL_CONTEXT, *PCTL_CONTEXT;
|
||||||
typedef const CTL_CONTEXT *PCCTL_CONTEXT;
|
typedef const CTL_CONTEXT *PCCTL_CONTEXT;
|
||||||
|
|
||||||
|
typedef struct _CMSG_SIGNER_INFO {
|
||||||
|
DWORD dwVersion;
|
||||||
|
CERT_NAME_BLOB Issuer;
|
||||||
|
CRYPT_INTEGER_BLOB SerialNumber;
|
||||||
|
CRYPT_ALGORITHM_IDENTIFIER HashAlgorithm;
|
||||||
|
CRYPT_ALGORITHM_IDENTIFIER HashEncryptionAlgorithm;
|
||||||
|
CRYPT_DATA_BLOB EncryptedHash;
|
||||||
|
CRYPT_ATTRIBUTES AuthAttrs;
|
||||||
|
CRYPT_ATTRIBUTES UnauthAttrs;
|
||||||
|
} CMSG_SIGNER_INFO, *PCMSG_SIGNER_INFO;
|
||||||
|
|
||||||
typedef struct _CERT_REVOCATION_CRL_INFO {
|
typedef struct _CERT_REVOCATION_CRL_INFO {
|
||||||
DWORD cbSize;
|
DWORD cbSize;
|
||||||
PCCRL_CONTEXT pBaseCrlContext;
|
PCCRL_CONTEXT pBaseCrlContext;
|
||||||
|
|
|
@ -0,0 +1,116 @@
|
||||||
|
/*
|
||||||
|
* Copyright (C) 2004 Francois Gouget
|
||||||
|
*
|
||||||
|
* This library is free software; you can redistribute it and/or
|
||||||
|
* modify it under the terms of the GNU Lesser General Public
|
||||||
|
* License as published by the Free Software Foundation; either
|
||||||
|
* version 2.1 of the License, or (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This library is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||||
|
* Lesser General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU Lesser General Public
|
||||||
|
* License along with this library; if not, write to the Free Software
|
||||||
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef __WINE_WINTRUST_H
|
||||||
|
#define __WINE_WINTRUST_H
|
||||||
|
|
||||||
|
#include <wincrypt.h>
|
||||||
|
|
||||||
|
|
||||||
|
#include <pshpack8.h>
|
||||||
|
|
||||||
|
typedef struct WINTRUST_FILE_INFO_
|
||||||
|
{
|
||||||
|
DWORD cbStruct;
|
||||||
|
LPCWSTR pcwszFilePath;
|
||||||
|
HANDLE hFile;
|
||||||
|
GUID* pgKnownSubject;
|
||||||
|
} WINTRUST_FILE_INFO, *PWINTRUST_FILE_INFO;
|
||||||
|
|
||||||
|
typedef struct WINTRUST_CATALOG_INFO_
|
||||||
|
{
|
||||||
|
DWORD cbStruct;
|
||||||
|
DWORD dwCatalogVersion;
|
||||||
|
LPCWSTR pcwszCatalogFilePath;
|
||||||
|
LPCWSTR pcwszMemberTag;
|
||||||
|
LPCWSTR pcwszMemberFilePath;
|
||||||
|
HANDLE hMemberFile;
|
||||||
|
BYTE* pbCalculatedFileHash;
|
||||||
|
DWORD cbCalculatedFileHash;
|
||||||
|
PCCTL_CONTEXT pcCatalogContext;
|
||||||
|
} WINTRUST_CATALOG_INFO, *PWINTRUST_CATALOG_INFO;
|
||||||
|
|
||||||
|
typedef struct WINTRUST_BLOB_INFO_
|
||||||
|
{
|
||||||
|
DWORD cbStruct;
|
||||||
|
GUID gSubject;
|
||||||
|
LPCWSTR pcwszDisplayName;
|
||||||
|
DWORD cbMemObject;
|
||||||
|
BYTE* pbMemObject;
|
||||||
|
DWORD cbMemSignedMsg;
|
||||||
|
BYTE* pbMemSignedMsg;
|
||||||
|
} WINTRUST_BLOB_INFO, *PWINTRUST_BLOB_INFO;
|
||||||
|
|
||||||
|
typedef struct WINTRUST_SGNR_INFO_
|
||||||
|
{
|
||||||
|
DWORD cbStruct;
|
||||||
|
LPCWSTR pcwszDisplayName;
|
||||||
|
CMSG_SIGNER_INFO* psSignerInfo;
|
||||||
|
DWORD chStores;
|
||||||
|
HCERTSTORE* pahStores;
|
||||||
|
} WINTRUST_SGNR_INFO, *PWINTRUST_SGNR_INFO;
|
||||||
|
|
||||||
|
typedef struct WINTRUST_CERT_INFO_
|
||||||
|
{
|
||||||
|
DWORD cbStruct;
|
||||||
|
LPCWSTR pcwszDisplayName;
|
||||||
|
CERT_CONTEXT* psCertContext;
|
||||||
|
DWORD chStores;
|
||||||
|
HCERTSTORE* pahStores;
|
||||||
|
DWORD dwFlags;
|
||||||
|
FILETIME* psftVerifyAsOf;
|
||||||
|
} WINTRUST_CERT_INFO, *PWINTRUST_CERT_INFO;
|
||||||
|
|
||||||
|
|
||||||
|
typedef struct _WINTRUST_DATA
|
||||||
|
{
|
||||||
|
DWORD cbStruct;
|
||||||
|
LPVOID pPolicyCallbackData;
|
||||||
|
LPVOID pSIPClientData;
|
||||||
|
DWORD dwUIChoice;
|
||||||
|
DWORD fdwRevocationChecks;
|
||||||
|
DWORD dwUnionChoice;
|
||||||
|
union
|
||||||
|
{
|
||||||
|
struct WINTRUST_FILE_INFO_* pFile;
|
||||||
|
struct WINTRUST_CATALOG_INFO_* pCatalog;
|
||||||
|
struct WINTRUST_BLOB_INFO_* pBlob;
|
||||||
|
struct WINTRUST_SGNR_INFO_* pSgnr;
|
||||||
|
struct WINTRUST_CERT_INFO_* pCert;
|
||||||
|
} DUMMYUNIONNAME;
|
||||||
|
|
||||||
|
DWORD dwStateAction;
|
||||||
|
HANDLE hWVTStateData;
|
||||||
|
WCHAR* pwszURLReference;
|
||||||
|
DWORD dwProvFlags;
|
||||||
|
} WINTRUST_DATA, *PWINTRUST_DATA;
|
||||||
|
|
||||||
|
#include <poppack.h>
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C" {
|
||||||
|
#endif
|
||||||
|
|
||||||
|
LONG WINAPI WinVerifyTrust(HWND,GUID*,WINTRUST_DATA*);
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
|
@ -4511,13 +4511,16 @@ LPWSTR
|
||||||
|
|
||||||
%long
|
%long
|
||||||
|
|
||||||
|
BOOL
|
||||||
|
DWORD
|
||||||
HWND
|
HWND
|
||||||
LONG
|
LONG
|
||||||
|
|
||||||
%ptr
|
%ptr
|
||||||
|
|
||||||
GUID *
|
GUID *
|
||||||
LPVOID
|
HCATADMIN *
|
||||||
|
WINTRUST_DATA *
|
||||||
|
|
||||||
%%wnaspi32.dll
|
%%wnaspi32.dll
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue