[wintrust 8/8] Register WINTRUST_ACTION_GENERIC_CHAIN_VERIFY
Paul Vriens
Paul.Vriens at xs4all.nl
Tue Sep 5 13:38:23 CDT 2006
Hi,
this one also needed some extra defines at the top.
Changelog
Register WINTRUST_ACTION_GENERIC_CHAIN_VERIFY
Cheers,
Paul.
---
dlls/wintrust/register.c | 38 ++++++++++++++++++++++++++++++++++++++
1 files changed, 38 insertions(+), 0 deletions(-)
diff --git a/dlls/wintrust/register.c b/dlls/wintrust/register.c
index 36d68e2..9f229cb 100644
--- a/dlls/wintrust/register.c
+++ b/dlls/wintrust/register.c
@@ -57,6 +57,9 @@ static CRYPT_TRUST_REG_ENTRY DriverIniti
static CRYPT_TRUST_REG_ENTRY DriverFinalPolicy;
static CRYPT_TRUST_REG_ENTRY DriverCleanupPolicy;
+static CRYPT_TRUST_REG_ENTRY GenericChainCertificateTrust;
+static CRYPT_TRUST_REG_ENTRY GenericChainFinalProv;
+
static const WCHAR Trust[] = {'S','o','f','t','w','a','r','e','\\',
'M','i','c','r','o','s','o','f','t','\\',
'C','r','y','p','t','o','g','r','a','p','h','y','\\',
@@ -106,6 +109,8 @@ #define WINTRUST_INITREGENTRY( action, d
WINTRUST_INITREGENTRY(DriverInitializePolicy, SP_POLICY_PROVIDER_DLL_NAME, DRIVER_INITPROV_FUNCTION)
WINTRUST_INITREGENTRY(DriverFinalPolicy, SP_POLICY_PROVIDER_DLL_NAME, DRIVER_FINALPOLPROV_FUNCTION)
WINTRUST_INITREGENTRY(DriverCleanupPolicy, SP_POLICY_PROVIDER_DLL_NAME, DRIVER_CLEANUPPOLICY_FUNCTION)
+ WINTRUST_INITREGENTRY(GenericChainCertificateTrust, SP_POLICY_PROVIDER_DLL_NAME, GENERIC_CHAIN_CERTTRUST_FUNCTION)
+ WINTRUST_INITREGENTRY(GenericChainFinalProv, SP_POLICY_PROVIDER_DLL_NAME, GENERIC_CHAIN_FINALPOLICY_FUNCTION)
#undef WINTRUST_INITREGENTRY
}
@@ -138,6 +143,8 @@ #define WINTRUST_FREEREGENTRY( action )
WINTRUST_FREEREGENTRY(DriverInitializePolicy);
WINTRUST_FREEREGENTRY(DriverFinalPolicy);
WINTRUST_FREEREGENTRY(DriverCleanupPolicy);
+ WINTRUST_FREEREGENTRY(GenericChainCertificateTrust);
+ WINTRUST_FREEREGENTRY(GenericChainFinalProv);
#undef WINTRUST_FREEREGENTRY
}
@@ -672,6 +679,36 @@ static void WINTRUST_RegisterDriverVerif
WINTRUST_WriteProviderToReg(GuidString, Cleanup , DriverCleanupPolicy);
}
+/***************************************************************************
+ * WINTRUST_RegisterGenChainVerify
+ *
+ * Register WINTRUST_ACTION_GENERIC_CHAIN_VERIFY actions and usages.
+ *
+ * NOTES
+ * WINTRUST_ACTION_GENERIC_CHAIN_VERIFY ({FC451C16-AC75-11D1-B4B8-00C04FB66EA0})
+ * is defined in softpub.h
+ * We don't care about failures (see comments in DllRegisterServer)
+ */
+static void WINTRUST_RegisterGenChainVerify(void)
+{
+ GUID ProvGUID;
+ WCHAR GuidString[39];
+
+ ProvGUID = (GUID)WINTRUST_ACTION_GENERIC_CHAIN_VERIFY;
+ WINTRUST_Guid2Wstr(&ProvGUID , GuidString);
+
+ TRACE("Going to register WINTRUST_ACTION_GENERIC_CHAIN_VERIFY : %s\n", wine_dbgstr_w(GuidString));
+
+ /* HKLM\Software\Microsoft\Cryptography\Trust\Provider\*\{FC451C16-AC75-11D1-B4B8-00C04FB66EA0} */
+ WINTRUST_WriteProviderToReg(GuidString, Initialization, SoftpubInitialization);
+ WINTRUST_WriteProviderToReg(GuidString, Message , SoftpubMessage);
+ WINTRUST_WriteProviderToReg(GuidString, Signature , SoftpubSignature);
+ WINTRUST_WriteProviderToReg(GuidString, Certificate , GenericChainCertificateTrust);
+ WINTRUST_WriteProviderToReg(GuidString, CertCheck , SoftpubCertCheck);
+ WINTRUST_WriteProviderToReg(GuidString, FinalPolicy , GenericChainFinalProv);
+ WINTRUST_WriteProviderToReg(GuidString, Cleanup , SoftpubCleanup);
+}
+
/***********************************************************************
* DllRegisterServer (WINTRUST.@)
*/
@@ -717,6 +754,7 @@ HRESULT WINAPI DllRegisterServer(void)
WINTRUST_RegisterHttpsProv();
WINTRUST_RegisterOfficeSignVerify();
WINTRUST_RegisterDriverVerify();
+ WINTRUST_RegisterGenChainVerify();
/* Free the registry structures */
WINTRUST_FreeRegStructs();
--
1.4.1.1
More information about the wine-patches
mailing list