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.

122 lines
3.6 KiB

  1. //--------------------------------------------------------------
  2. // Copyright (C) Microsoft Corporation, 1996 - 1999
  3. //
  4. // File: mgrcert.h
  5. //
  6. // Contents: The private include file for the dialogue of managing
  7. // certificates
  8. //
  9. // History: Feb-26-98 xiaohs created
  10. //
  11. //--------------------------------------------------------------
  12. #ifndef MGRCERT_H
  13. #define MGRCERT_H
  14. #include "dragdrop.h"
  15. //used for the context sensitive help
  16. #include "secauth.h"
  17. #ifdef __cplusplus
  18. extern "C" {
  19. #endif
  20. //**************************************************************************
  21. //
  22. // The private data used for the cert management dialogue
  23. //
  24. //**************************************************************************
  25. //constatns
  26. #define DIALOGUE_OK 1
  27. #define DIALOGUE_CANCEL 0
  28. #define ALL_SELECTED_CAN_DELETE 1
  29. #define ALL_SELECTED_DELETE 2
  30. #define ALL_SELECTED_COPY 3
  31. #define CERTMGR_MAX_FILE_NAME 88
  32. //the registry keys to persist the advanced options
  33. #define WSZCertMgrExportRegLocation L"Software\\Microsoft\\Cryptography\\UI\\Certmgr\\ExportFormat"
  34. #define WSZCertMgrPurposeRegLocation L"Software\\Microsoft\\Cryptography\\UI\\Certmgr\\Purpose"
  35. #define WSZCertMgrExportName L"Export"
  36. #define SZCertMgrPurposeName "Purpose"
  37. //-----------------------------------------------------------------------
  38. // PURPOSE_OID_INFO
  39. //
  40. //------------------------------------------------------------------------
  41. typedef struct _PURPOSE_OID_INFO
  42. {
  43. LPWSTR pwszName;
  44. BOOL fSelected;
  45. LPSTR pszOID;
  46. }PURPOSE_OID_INFO;
  47. //-----------------------------------------------------------------------
  48. // PURPOSE_OID_CALL_BACK
  49. //
  50. //------------------------------------------------------------------------
  51. typedef struct _PURPOSE_OID_CALL_BACK
  52. {
  53. DWORD *pdwOIDCount;
  54. PURPOSE_OID_INFO **pprgOIDInfo;
  55. }PURPOSE_OID_CALL_BACK;
  56. //-----------------------------------------------------------------------
  57. // CERT_MGR_INFO
  58. //
  59. //
  60. // This struct contains everything you will ever need to call
  61. // the cert mgr dialogue. This struct is private to the dll
  62. //------------------------------------------------------------------------
  63. typedef struct _CERT_MGR_INFO
  64. {
  65. PCCRYPTUI_CERT_MGR_STRUCT pCertMgrStruct;
  66. DWORD dwCertCount;
  67. PCCERT_CONTEXT *prgCertContext;
  68. DWORD dwOIDInfo;
  69. PURPOSE_OID_INFO *rgOIDInfo;
  70. DWORD dwExportFormat;
  71. BOOL fExportChain;
  72. BOOL fAdvOIDChanged;
  73. DWORD rgdwSortParam[5];
  74. int iColumn;
  75. IDropTarget *pIDropTarget;
  76. }CERT_MGR_INFO;
  77. //function prototypes
  78. BOOL FreeUsageOID(DWORD dwOIDInfo,
  79. PURPOSE_OID_INFO *pOIDInfo);
  80. void FreeCerts(CERT_MGR_INFO *pCertMgrInfo);
  81. HRESULT CCertMgrDropTarget_CreateInstance(HWND hwndDlg,
  82. CERT_MGR_INFO *pCertMgrInfo,
  83. IDropTarget **ppIDropTarget);
  84. void RefreshCertListView(HWND hwndDlg,
  85. CERT_MGR_INFO *pCertMgrInfo);
  86. void SaveAdvValueToReg(CERT_MGR_INFO *pCertMgrInfo);
  87. #ifdef __cplusplus
  88. } // Balance extern "C" above
  89. #endif
  90. #endif //MGRCERT_H