widl: Always check the runtimeclass interfaces presence.
[wine/zf.git] / dlls / mssign32 / mssign32_private.h
blobbcbaa65d85b2a6d60857cfce3ec71cce1995b501
1 /*
2 * Copyright 2019 Gijs Vermeulen
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19 #include "windef.h"
20 #include "winbase.h"
21 #include "wincrypt.h"
22 #include "mssip.h"
24 #define SIGNER_CERT_SPC_FILE 1
25 #define SIGNER_CERT_STORE 2
26 #define SIGNER_CERT_SPC_CHAIN 3
28 #define SIGNER_CERT_POLICY_STORE 0x1
29 #define SIGNER_CERT_POLICY_CHAIN 0x2
30 #define SIGNER_CERT_POLICY_CHAIN_NO_ROOT 0x8
32 #define SIGNER_NO_ATTR 0
33 #define SIGNER_AUTHCODE_ATTR 1
35 typedef struct _SIGNER_CONTEXT {
36 DWORD cbSize;
37 DWORD cbBlob;
38 BYTE *pbBlob;
39 } SIGNER_CONTEXT, *PSIGNER_CONTEXT;
41 typedef struct _SIGNER_FILE_INFO {
42 DWORD cbSize;
43 const WCHAR *pwszFileName;
44 HANDLE hFile;
45 } SIGNER_FILE_INFO, *PSIGNER_FILE_INFO;
47 typedef struct _SIGNER_BLOB_INFO {
48 DWORD cbSize;
49 GUID *pGuidSubject;
50 DWORD cbBlob;
51 BYTE *pbBlob;
52 const WCHAR *pwszDisplayName;
53 } SIGNER_BLOB_INFO, *PSIGNER_BLOB_INFO;
55 typedef struct _SIGNER_SUBJECT_INFO {
56 DWORD cbSize;
57 DWORD *pdwIndex;
58 DWORD dwSubjectChoice;
59 union {
60 SIGNER_FILE_INFO *pSignerFileInfo;
61 SIGNER_BLOB_INFO *pSignerBlobInfo;
63 } SIGNER_SUBJECT_INFO, *PSIGNER_SUBJECT_INFO;
65 typedef struct _SIGNER_CERT_STORE_INFO {
66 DWORD cbSize;
67 const CERT_CONTEXT *pSigningCert;
68 DWORD dwCertPolicy;
69 HCERTSTORE hCertStore;
70 } SIGNER_CERT_STORE_INFO, *PSIGNER_CERT_STORE_INFO;
72 typedef struct _SIGNER_SPC_CHAIN_INFO {
73 DWORD cbSize;
74 const WCHAR *pwszSpcFile;
75 DWORD dwCertPolicy;
76 HCERTSTORE hCertStore;
77 } SIGNER_SPC_CHAIN_INFO, *PSIGNER_SPC_CHAIN_INFO;
79 typedef struct _SIGNER_CERT {
80 DWORD cbSize;
81 DWORD dwCertChoice;
82 union {
83 const WCHAR *pwszSpcFile;
84 SIGNER_CERT_STORE_INFO *pCertStoreInfo;
85 SIGNER_SPC_CHAIN_INFO *pSpcChainInfo;
87 HWND hwnd;
88 } SIGNER_CERT, *PSIGNER_CERT;
90 typedef struct _SIGNER_ATTR_AUTHCODE {
91 DWORD cbSize;
92 BOOL fCommercial;
93 BOOL fIndividual;
94 const WCHAR *pwszName;
95 const WCHAR *pwszInfo;
96 } SIGNER_ATTR_AUTHCODE, *PSIGNER_ATTR_AUTHCODE;
98 typedef struct _SIGNER_SIGNATURE_INFO {
99 DWORD cbSize;
100 ALG_ID algidHash;
101 DWORD dwAttrChoice;
102 union {
103 SIGNER_ATTR_AUTHCODE *pAttrAuthcode;
105 CRYPT_ATTRIBUTES *psAuthenticated;
106 CRYPT_ATTRIBUTES *psUnauthenticated;
107 } SIGNER_SIGNATURE_INFO, *PSIGNER_SIGNATURE_INFO;
109 typedef struct _SIGNER_PROVIDER_INFO {
110 DWORD cbSize;
111 const WCHAR *pwszProviderName;
112 DWORD dwProviderType;
113 DWORD dwKeySpec;
114 DWORD dwPvkChoice;
115 union {
116 WCHAR *pwszPvkFileName;
117 WCHAR *pwszKeyContainer;
119 } SIGNER_PROVIDER_INFO, *PSIGNER_PROVIDER_INFO;