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.

53 lines
1.7 KiB

  1. #if !defined( _CERT_INCLUDED )
  2. #define _CERT_INCLUDED
  3. class CCertMapperMethod
  4. {
  5. #define IISMAPPER_LOCATE_BY_CERT 1
  6. #define IISMAPPER_LOCATE_BY_NAME 2
  7. #define IISMAPPER_LOCATE_BY_ACCT 3
  8. #define IISMAPPER_LOCATE_BY_INDEX 4
  9. private:
  10. IMSAdminBase* m_pIABase; //interface pointer
  11. METADATA_HANDLE m_hmd;
  12. LPWSTR m_pszMetabasePath;
  13. HRESULT Init(LPCWSTR);
  14. HRESULT Locate(LONG, VARIANT, LPWSTR);
  15. HRESULT SetString(LONG, VARIANT, BSTR, DWORD);
  16. HRESULT SetBSTR(BSTR*, DWORD, LPBYTE);
  17. HRESULT SetVariantAsByteArray(VARIANT*, DWORD, LPBYTE);
  18. HRESULT SetVariantAsBSTR(VARIANT*, DWORD, LPBYTE);
  19. HRESULT SetVariantAsLong(VARIANT*, DWORD);
  20. HRESULT GetStringAFromBSTR(BSTR, LPSTR*, LPDWORD, BOOL fAddDelimInCount = true);
  21. HRESULT GetBlobFromVariant(VARIANT*, LPBYTE*, LPDWORD, BOOL fAddDelimInCount = true);
  22. HRESULT OpenMd(LPWSTR, DWORD dwPermission = METADATA_PERMISSION_READ);
  23. HRESULT CloseMd(BOOL fSave = FALSE);
  24. HRESULT DeleteMdObject(LPWSTR);
  25. HRESULT CreateMdObject(LPWSTR);
  26. HRESULT OpenAdminBaseKey(LPWSTR, DWORD);
  27. void CloseAdminBaseKey();
  28. public:
  29. CCertMapperMethod(LPCWSTR);
  30. ~CCertMapperMethod();
  31. HRESULT CreateMapping(VARIANT, BSTR, BSTR, BSTR, LONG);
  32. HRESULT GetMapping(LONG, VARIANT, VARIANT*, VARIANT*, VARIANT*, VARIANT*, VARIANT*);
  33. HRESULT DeleteMapping(LONG, VARIANT);
  34. HRESULT SetEnabled(LONG, VARIANT, LONG);
  35. HRESULT SetName(LONG, VARIANT, BSTR);
  36. HRESULT SetPwd(LONG, VARIANT, BSTR);
  37. HRESULT SetAcct(LONG, VARIANT, BSTR);
  38. HRESULT SetMdData(LPWSTR, DWORD, DWORD, DWORD, LPBYTE);
  39. HRESULT GetMdData(LPWSTR, DWORD, DWORD, LPDWORD, LPBYTE*);
  40. };
  41. #endif