Blame iis/mymodule.h

Packit 284210
/*
Packit 284210
* ModSecurity for Apache 2.x, http://www.modsecurity.org/
Packit 284210
* Copyright (c) 2004-2013 Trustwave Holdings, Inc. (http://www.trustwave.com/)
Packit 284210
*
Packit 284210
* You may not use this file except in compliance with
Packit 284210
* the License.  You may obtain a copy of the License at
Packit 284210
*
Packit 284210
*     http://www.apache.org/licenses/LICENSE-2.0
Packit 284210
*
Packit 284210
* If any of the files related to licensing are missing or if you have any
Packit 284210
* other questions related to licensing please contact Trustwave Holdings, Inc.
Packit 284210
* directly using the email address security@modsecurity.org.
Packit 284210
*/
Packit 284210

Packit 284210
#ifndef __MY_MODULE_H__
Packit 284210
#define __MY_MODULE_H__
Packit 284210

Packit 284210
//  The module implementation.
Packit 284210
//  This class is responsible for implementing the 
Packit 284210
//  module functionality for each of the server events
Packit 284210
//  that it registers for.
Packit 284210
class CMyHttpModule : public CHttpModule
Packit 284210
{
Packit 284210
public:
Packit 284210
    HANDLE				m_hEventLog;
Packit 284210
    DWORD				m_dwPageSize;
Packit 284210
	CRITICAL_SECTION	m_csLock;
Packit 284210

Packit 284210
    REQUEST_NOTIFICATION_STATUS
Packit 284210
    OnBeginRequest(
Packit 284210
        IN IHttpContext * pHttpContext,
Packit 284210
        IN IHttpEventProvider * pProvider
Packit 284210
    );
Packit 284210

Packit 284210
    REQUEST_NOTIFICATION_STATUS
Packit 284210
    OnSendResponse(
Packit 284210
    IN IHttpContext * pHttpContext,
Packit 284210
        IN ISendResponseProvider * pProvider
Packit 284210
    );
Packit 284210

Packit 284210
    REQUEST_NOTIFICATION_STATUS
Packit 284210
    OnPostEndRequest(
Packit 284210
    IN IHttpContext * pHttpContext,
Packit 284210
    IN IHttpEventProvider * pProvider
Packit 284210
    );
Packit 284210

Packit 284210
    HRESULT ReadFileChunk(HTTP_DATA_CHUNK *chunk, char *buf);
Packit 284210

Packit 284210
    CMyHttpModule();
Packit 284210
    ~CMyHttpModule();
Packit 284210

Packit 284210
    void Dispose();
Packit 284210

Packit 284210
    BOOL WriteEventViewerLog(LPCSTR szNotification, WORD category = EVENTLOG_INFORMATION_TYPE);
Packit 284210
    BOOL status_call_already_sent;
Packit 284210
};
Packit 284210

Packit 284210
#endif