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.

120 lines
2.8 KiB

  1. /*++
  2. Copyright (c) 1997 Microsoft Corporation
  3. Module Name :
  4. colog.hxx
  5. Abstract:
  6. Custom logging stuff
  7. Author:
  8. Anil Ruia (AnilR) 1-Jul-2000
  9. --*/
  10. #ifndef _COLOG_HXX_
  11. #define _COLOG_HXX_
  12. extern CHAR g_pszComputerName[MAX_COMPUTERNAME_LENGTH + 1];
  13. class CInetLogInformation : public IInetLogInformation
  14. {
  15. public:
  16. CInetLogInformation()
  17. : m_pLogContext (NULL)
  18. {}
  19. HRESULT STDMETHODCALLTYPE
  20. QueryInterface(REFIID,
  21. VOID **ppObject)
  22. {
  23. *ppObject = NULL;
  24. return E_NOINTERFACE;
  25. }
  26. ULONG STDMETHODCALLTYPE AddRef(){return 1;}
  27. ULONG STDMETHODCALLTYPE Release(){return 1;}
  28. LPSTR STDMETHODCALLTYPE
  29. GetSiteName(IN PCHAR pszSiteName,
  30. IN PDWORD pcbSize);
  31. LPSTR STDMETHODCALLTYPE
  32. GetComputerName(IN PCHAR pszComputerName,
  33. IN PDWORD pcbSize);
  34. LPSTR STDMETHODCALLTYPE
  35. GetClientHostName(IN PCHAR pszClientHostName,
  36. IN PDWORD pcbSize);
  37. LPSTR STDMETHODCALLTYPE
  38. GetClientUserName(IN PCHAR pszClientUserName,
  39. IN PDWORD pcbSize);
  40. LPSTR STDMETHODCALLTYPE
  41. GetServerAddress(IN PCHAR pszServerAddress,
  42. IN PDWORD pcbSize);
  43. LPSTR STDMETHODCALLTYPE
  44. GetOperation(IN PCHAR pszOperation,
  45. IN PDWORD pcbSize);
  46. LPSTR STDMETHODCALLTYPE
  47. GetTarget(IN PCHAR pszTarget,
  48. IN PDWORD pcbSize);
  49. LPSTR STDMETHODCALLTYPE
  50. GetParameters(IN PCHAR pszParameters,
  51. IN PDWORD pcbSize);
  52. LPSTR STDMETHODCALLTYPE
  53. GetVersionString(IN PCHAR pszVersionString,
  54. IN PDWORD pcbSize);
  55. LPSTR STDMETHODCALLTYPE
  56. GetExtraHTTPHeaders(IN PCHAR pszHTTPHeaders,
  57. IN PDWORD pcbSize);
  58. DWORD STDMETHODCALLTYPE
  59. GetTimeForProcessing()
  60. { return m_pLogContext->m_msProcessingTime; }
  61. DWORD STDMETHODCALLTYPE
  62. GetBytesSent()
  63. { return m_pLogContext->m_dwBytesSent; }
  64. DWORD STDMETHODCALLTYPE
  65. GetBytesRecvd()
  66. { return m_pLogContext->m_dwBytesRecvd; }
  67. DWORD STDMETHODCALLTYPE
  68. GetWin32Status()
  69. { return m_pLogContext->QueryUlLogData()->Win32Status; }
  70. DWORD STDMETHODCALLTYPE
  71. GetProtocolStatus()
  72. { return m_pLogContext->QueryUlLogData()->ProtocolStatus; }
  73. DWORD STDMETHODCALLTYPE
  74. GetPortNumber()
  75. { return m_pLogContext->QueryUlLogData()->ServerPort; }
  76. VOID STDMETHODCALLTYPE
  77. CanonicalizeLogRecord(IN LOG_CONTEXT *pInetLogRecord);
  78. private:
  79. STRA m_strUserName;
  80. STRA m_strTarget;
  81. LOG_CONTEXT *m_pLogContext;
  82. };
  83. #endif // _COLOG_HXX