Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

115 lines
3.7 KiB

  1. //+-------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. //
  5. // Copyright (C) Microsoft Corporation, 1996 - 1999
  6. //
  7. // File: locals.h
  8. //
  9. // Contents: Microsoft Internet Security Trust Provider
  10. //
  11. //
  12. // History: 28-May-1997 pberkman created
  13. //
  14. //--------------------------------------------------------------------------
  15. #ifndef LOCALS_H
  16. #define LOCALS_H
  17. #ifdef __cplusplus
  18. extern "C"
  19. {
  20. #endif
  21. #define MY_NAME "WINTRUST.DLL"
  22. #define W_MY_NAME L"WINTRUST.DLL"
  23. //
  24. // dllmain.cpp
  25. //
  26. extern HANDLE hMeDLL;
  27. extern LIST_LOCK sProvLock;
  28. extern LIST_LOCK sStoreLock;
  29. extern HANDLE hStoreEvent;
  30. //
  31. // memory.cpp
  32. //
  33. extern void *WVTNew(DWORD cbSize);
  34. extern void WVTDelete(void *pvMem);
  35. extern BOOL WVTAddStore(CRYPT_PROVIDER_DATA *pProvData, HCERTSTORE hStore);
  36. extern BOOL WVTAddSigner(CRYPT_PROVIDER_DATA *pProvData,
  37. BOOL fCounterSigner,
  38. DWORD idxSigner,
  39. CRYPT_PROVIDER_SGNR *pSngr2Add);
  40. extern BOOL WVTAddCertContext(CRYPT_PROVIDER_DATA *pProvData, DWORD idxSigner,
  41. BOOL fCounterSigner, DWORD idxCounterSigner,
  42. PCCERT_CONTEXT pCert);
  43. extern BOOL WVTAddPrivateData(CRYPT_PROVIDER_DATA *pProvData,
  44. CRYPT_PROVIDER_PRIVDATA *pPrivData2Add);
  45. //
  46. // registry.cpp
  47. //
  48. extern BOOL GetRegProvider(GUID *pgActionID, WCHAR *pwszRegKey,
  49. WCHAR *pwszRetDLLName, char *pszRetFuncName);
  50. extern BOOL SetRegProvider(GUID *pgActionID, WCHAR *pwszRegKey,
  51. WCHAR *pwszDLLName, WCHAR *pwszFuncName);
  52. extern void GetRegSecuritySettings(DWORD *pdwState);
  53. extern BOOL RemoveRegProvider(GUID *pgActionID, WCHAR *pwszRegKey);
  54. //
  55. // chains.cpp
  56. //
  57. extern BOOL AddToStoreChain(HCERTSTORE hStore2Add, DWORD *pchStores,
  58. HCERTSTORE **pphStoreChain);
  59. extern BOOL AddToCertChain(CRYPT_PROVIDER_CERT *pPCert2Add, DWORD *pcPCerts,
  60. CRYPT_PROVIDER_CERT **ppPCertChain);
  61. extern BOOL AddToSignerChain(CRYPT_PROVIDER_SGNR *psSgnr2Add, DWORD *pcSgnrs,
  62. CRYPT_PROVIDER_SGNR **ppSgnrChain);
  63. extern void DeallocateCertChain(DWORD csPCert, CRYPT_PROVIDER_CERT **pasPCertChain);
  64. extern void DeallocateStoreChain(DWORD csStore, HCERTSTORE *phStoreChain);
  65. extern BOOL AllocateNewChain(DWORD cbMember, void *pNewMember, DWORD *pcChain,
  66. void **ppChain, DWORD cbAssumeSize);
  67. extern BOOL AllocateNewChainWithErrors(DWORD cbMember, void *pNewMember, DWORD *pcChain,
  68. void **ppChain, DWORD **ppdwErrors);
  69. //
  70. // provload.cpp
  71. //
  72. extern LOADED_PROVIDER *WintrustFindProvider(GUID *pgActionID);
  73. //
  74. // certtrst.cpp
  75. //
  76. extern HRESULT WINAPI WintrustCertificateTrust(CRYPT_PROVIDER_DATA *pProvData);
  77. //
  78. // wvtver1.cpp
  79. //
  80. extern LONG Version1_WinVerifyTrust(HWND hwnd, GUID *ActionID, LPVOID ActionData);
  81. //
  82. // wthelper.cpp
  83. //
  84. extern void * WTHelperCertAllocAndDecodeObject(DWORD dwCertEncodingType, LPCSTR lpszStructType,
  85. const BYTE *pbEncoded, DWORD cbEncoded,
  86. DWORD *pcbStructInfo);
  87. #ifdef __cplusplus
  88. }
  89. #endif
  90. #endif // LOCALS_H