Source code of Windows XP (NT5)
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
5.8 KiB

  1. #include "dspch.h"
  2. #pragma hdrstop
  3. #include <wincrypt.h>
  4. #include <cryptui.h>
  5. #include <lenroll.h>
  6. static
  7. BOOL
  8. WINAPI
  9. CryptUIDlgViewCRLW(
  10. IN PCCRYPTUI_VIEWCRL_STRUCTW pcvcrl
  11. )
  12. {
  13. SetLastError(ERROR_PROC_NOT_FOUND);
  14. return FALSE;
  15. }
  16. static
  17. BOOL
  18. WINAPI
  19. CryptUIDlgViewCTLW(
  20. IN PCCRYPTUI_VIEWCTL_STRUCTW pcvctl
  21. )
  22. {
  23. SetLastError(ERROR_PROC_NOT_FOUND);
  24. return FALSE;
  25. }
  26. static
  27. BOOL
  28. WINAPI
  29. CryptUIDlgViewCertificateW(
  30. IN PCCRYPTUI_VIEWCERTIFICATE_STRUCTW pCertViewInfo,
  31. OUT BOOL *pfPropertiesChanged // OPTIONAL
  32. )
  33. {
  34. SetLastError(ERROR_PROC_NOT_FOUND);
  35. return FALSE;
  36. }
  37. HRESULT WINAPI LocalEnroll( DWORD dwFlags, //IN Required
  38. LPCWSTR pRequestString, // Reserved: must be NULL.
  39. void *pReserved, //IN Optional
  40. BOOL fKeyService, //IN Required: Whether the function is called remotely
  41. DWORD dwPurpose, //IN Required: Whether it is enrollment or renew
  42. BOOL fConfirmation, //IN Required: Set the TRUE if confirmation dialogue is needed
  43. HWND hwndParent, //IN Optional: The parent window
  44. LPWSTR pwszConfirmationTitle, //IN Optional: The title for confirmation dialogue
  45. UINT idsConfirmTitle, //IN Optional: The resource ID for the title of the confirmation dialogue
  46. LPWSTR pwszCALocation, //IN Required: The ca machine name
  47. LPWSTR pwszCAName, //IN Required: The ca name
  48. CERT_BLOB *pCertBlob, //IN Required: The renewed certifcate
  49. CERT_REQUEST_PVK_NEW *pRenewKey, //IN Required: The private key on the certificate
  50. BOOL fNewKey, //IN Required: Set the TRUE if new private key is needed
  51. CERT_REQUEST_PVK_NEW *pKeyNew, //IN Required: The private key information
  52. LPWSTR pwszHashAlg, //IN Optional: The hash algorithm
  53. LPWSTR pwszDesStore, //IN Optional: The destination store
  54. DWORD dwStoreFlags, //IN Optional: The store flags
  55. CERT_ENROLL_INFO *pRequestInfo, //IN Required: The information about the cert request
  56. CERT_BLOB *pPKCS7Blob, //OUT Optional: The PKCS7 from the CA
  57. CERT_BLOB *pHashBlob, //OUT Optioanl: The SHA1 hash of the enrolled/renewed certificate
  58. DWORD *pdwStatus, //OUT Optional: The status of the enrollment/renewal
  59. PCERT_CONTEXT *ppCertContext //OUT Optional: The enrolled certificate
  60. )
  61. {
  62. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  63. }
  64. HRESULT WINAPI LocalEnrollNoDS( DWORD dwFlags, //IN Required
  65. LPCWSTR pRequestString, // Reserved: must be NULL.
  66. void *pReserved, //IN Optional
  67. BOOL fKeyService, //IN Required: Whether the function is called remotely
  68. DWORD dwPurpose, //IN Required: Whether it is enrollment or renew
  69. BOOL fConfirmation, //IN Required: Set the TRUE if confirmation dialogue is needed
  70. HWND hwndParent, //IN Optional: The parent window
  71. LPWSTR pwszConfirmationTitle, //IN Optional: The title for confirmation dialogue
  72. UINT idsConfirmTitle, //IN Optional: The resource ID for the title of the confirmation dialogue
  73. LPWSTR pwszCALocation, //IN Required: The ca machine name
  74. LPWSTR pwszCAName, //IN Required: The ca name
  75. CERT_BLOB *pCertBlob, //IN Required: The renewed certifcate
  76. CERT_REQUEST_PVK_NEW *pRenewKey, //IN Required: The private key on the certificate
  77. BOOL fNewKey, //IN Required: Set the TRUE if new private key is needed
  78. CERT_REQUEST_PVK_NEW *pKeyNew, //IN Required: The private key information
  79. LPWSTR pwszHashAlg, //IN Optional: The hash algorithm
  80. LPWSTR pwszDesStore, //IN Optional: The destination store
  81. DWORD dwStoreFlags, //IN Optional: The store flags
  82. CERT_ENROLL_INFO *pRequestInfo, //IN Required: The information about the cert request
  83. CERT_BLOB *pPKCS7Blob, //OUT Optional: The PKCS7 from the CA
  84. CERT_BLOB *pHashBlob, //OUT Optioanl: The SHA1 hash of the enrolled/renewed certificate
  85. DWORD *pdwStatus, //OUT Optional: The status of the enrollment/renewal
  86. HANDLE *pResult //IN OUT Optional: The enrolled certificate
  87. )
  88. {
  89. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  90. }
  91. //
  92. // !! WARNING !! The entries below must be in alphabetical order, and are CASE SENSITIVE (eg lower case comes last!)
  93. //
  94. DEFINE_PROCNAME_ENTRIES(cryptui)
  95. {
  96. DLPENTRY(CryptUIDlgViewCRLW)
  97. DLPENTRY(CryptUIDlgViewCTLW)
  98. DLPENTRY(CryptUIDlgViewCertificateW)
  99. DLPENTRY(LocalEnroll)
  100. DLPENTRY(LocalEnrollNoDS)
  101. };
  102. DEFINE_PROCNAME_MAP(cryptui)