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.

77 lines
2.1 KiB

  1. #define MDNAME_INCOMPLETE "incomplete"
  2. #define MDNAME_DISABLED "disabled"
  3. #define MDNAME_DEFAULT "default"
  4. #define MD_W3BASE "/lm/w3svc/"
  5. // foward declare the service
  6. class CMDKeyService;
  7. //-------------------------------------------------------------
  8. // This is the key object
  9. class CMDKey : public CCmnKey
  10. {
  11. public:
  12. CMDKey();
  13. CMDKey(CMDKeyService* pService);
  14. ~CMDKey();
  15. void SetName( CString &szNewName );
  16. virtual void UpdateCaption( void );
  17. // copy the members from a key into this key
  18. virtual void CopyDataFrom( CKey* pKey );
  19. virtual CKey* PClone( void );
  20. // install a cert
  21. virtual BOOL FInstallCertificate( PVOID pCert, DWORD cbCert, CString &szPass );
  22. void OnProperties();
  23. // add a binding to the binding list
  24. void AddBinding( LPCSTR psz );
  25. // remove a specified binding
  26. void RemoveBinding( CString szBinding );
  27. // is a given binding already associated with the key
  28. BOOL FContainsBinding( CString szBinding );
  29. // get the unique identifying string for this key. - actually the certificate serial number
  30. // return false if this is an incomplete key
  31. BOOL FGetIdentString( CWrapMetaBase* pWrap, PCHAR pszObj, CString &szIdent );
  32. BOOL FGetIdentString( PVOID pCert, DWORD cbCert, CString &szIdent );
  33. BOOL FGetIdentString( CString &szIdent );
  34. // load the key out of the metabase
  35. BOOL FLoadKey( CWrapMetaBase* pWrap, PCHAR pszObj );
  36. // write the key out to the metabase
  37. BOOL FWriteKey( CWrapMetaBase* pWrap, DWORD iKey, CStringArray* prgbsz );
  38. // the list of target binding names for the metabase objects
  39. CStringArray m_rgbszBindings;
  40. // cache the identifier string for faster use later
  41. CString m_szIdent;
  42. // the target port address
  43. // DWORD m_dwPort;
  44. // update flags
  45. BOOL m_fUpdateKeys;
  46. BOOL m_fUpdateFriendlyName;
  47. BOOL m_fUpdateIdent;
  48. BOOL m_fUpdateBindings;
  49. protected:
  50. // DO declare all this DYNCREATE
  51. DECLARE_DYNCREATE(CMDKey);
  52. // write out the data portion to a particular binding
  53. BOOL FWriteData( CWrapMetaBase* pWrap, CString szBinding, BOOL fWriteAll );
  54. // the service that created and owns this key
  55. CMDKeyService* m_pService;
  56. private:
  57. };