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.

96 lines
3.1 KiB

  1. #pragma once
  2. #ifndef _MSOAV_H
  3. #define _MSOAV_H
  4. typedef struct _msoavinfo
  5. {
  6. int cbsize; //size of this struct
  7. struct {
  8. ULONG fPath:1; //when true use pwzFullPath else use lpstg
  9. ULONG fReadOnlyRequest:1; //user requests file to be opened read/only
  10. ULONG fInstalled:1; //the file at pwzFullPath is an installed file
  11. ULONG fHttpDownload:1; //the file at pwzFullPath is a temp file downloaded from http/ftp
  12. };
  13. HWND hwnd; //parent window of the Office9 app
  14. union {
  15. WCHAR *pwzFullPath; //full path to the file about to be opened
  16. LPSTORAGE lpstg; //OLE Storage of the doc about to be opened
  17. }u;
  18. WCHAR *pwzHostName; // Host Office 9 apps name
  19. WCHAR *pwzOrigURL; // URL of the origin of this downloaded file.
  20. }MSOAVINFO;
  21. // {56FFCC30-D398-11d0-B2AE-00A0C908FA49}
  22. DEFINE_GUID(IID_IOfficeAntiVirus,
  23. 0x56ffcc30, 0xd398, 0x11d0, 0xb2, 0xae, 0x0, 0xa0, 0xc9, 0x8, 0xfa, 0x49);
  24. // {56FFCC31-D398-11d0-B2AE-00A0C908FA49}
  25. DEFINE_GUID(CATID_MSOfficeAntiVirus,
  26. 0x56ffcc30, 0xd398, 0x11d0, 0xb2, 0xae, 0x0, 0xa0, 0xc9, 0x8, 0xfa, 0x49);
  27. #undef INTERFACE
  28. #define INTERFACE IOfficeAntiVirus
  29. DECLARE_INTERFACE_(IOfficeAntiVirus, IUnknown)
  30. {
  31. BEGIN_INTERFACE
  32. // *** IUnknown methods ***
  33. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  34. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  35. STDMETHOD_(ULONG, Release)(THIS) PURE;
  36. // *** IOfficeAntiVirus methods ***
  37. STDMETHOD_(HRESULT, Scan)(THIS_ MSOAVINFO *pmsoavinfo ) PURE;
  38. };
  39. #ifndef AVVENDOR
  40. MSOAPI_(BOOL) MsoFAnyAntiVirus(HMSOINST hmsoinst);
  41. MSOAPI_(BOOL) MsoFDoAntiVirusScan(HMSOINST hmsoinst, MSOAVINFO *msoavinfo);
  42. MSOAPI_(void) MsoFreeMsoavStuff(HMSOINST hmsoinst);
  43. MSOAPI_(BOOL) MsoFDoSecurityLevelDlg(HMSOINST hmsoinst,DWORD msorid, int *pSecurityLevel,
  44. BOOL *pfTrustInstalled, HWND hwndParent, BOOL fShowVirusCheckers,
  45. WCHAR *wzHelpFile, DWORD dwHelpId);
  46. //output of the Enable/disable macro (edm) dialog
  47. #define msoedmEnable 1
  48. #define msoedmDisable 2
  49. #define msoedmDontOpen 3
  50. MSOAPI_(int) MsoMsoedmDialog(HMSOINST hmsoinst, BOOL fAppIsActive, BOOL fHasVBMacros,
  51. BOOL fHasXLMMacros, void *pvDigSigStore, void *pvMacro, int nAppID, HWND hwnd,
  52. const WCHAR *pwtzPath, int iClient, int iSecurityLevel, int *pmsodsv,
  53. WCHAR *wzHelpFile, DWORD dwHelpId, HANDLE hFileDLL, BOOL fUserControl);
  54. //Security level
  55. #define msoslUndefined 0
  56. #define msoslNone 1
  57. #define msoslMedium 2
  58. #define msoslHigh 3
  59. MSOAPI_(int) MsoMsoslGetSL(HMSOINST hmsoinst);
  60. MSOAPI_(int) MsoMsoslSetSL(DWORD msorid, HMSOINST hmsoinst);
  61. //output of the digital signature verification (dsv)
  62. #define msodsvNoMacros 0
  63. #define msodsvUnsigned 1
  64. // msodsvPassedTrusted is very unfortunately named because it has nothing to do with
  65. // trust - it just means that the doc is signed and the signature matched. Too late
  66. // to change the name now so I'm adding a msodsvPassedTrustedCert to mean the doc was
  67. // signed and cert was trusted.
  68. #define msodsvPassedTrusted 2
  69. #define msodsvFailed 3
  70. #define msodsvLowSecurityLevel 4
  71. #define msodsvPassedTrustedCert 5
  72. #endif //!AVVENDOR
  73. #endif // _MSOAV_H