ISAPI filter VC++ 2008

ASPcoder
ASPcoder used Ask the Experts™
on
Hello!
How i can create ISAPI Filter project in Visual C++ 2008 (MS Visual Studio 2008)?

P. S. Small code example (full)  for VC++ 2008 would be good.
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®

Author

Commented:
Thanks. but this ISAPI extension and old project.
I need Filter and how create it in C++ 2008.
jkr
Top Expert 2012

Commented:
Take a look at http://support.microsoft.com/kb/910382 - you'll find some information to shed in some light there (follow the pages linked from that one also)
Acronis in Gartner 2019 MQ for datacenter backup

It is an honor to be featured in Gartner 2019 Magic Quadrant for Datacenter Backup and Recovery Solutions. Gartner’s MQ sets a high standard and earning a place on their grid is a great affirmation that Acronis is delivering on our mission to protect all data, apps, and systems.

Author

Commented:
I'm downloading latest SDK http://www.microsoft.com/downloads/details.aspx?familyid=71DEB800-C591-4F97-A900-BEA146E4FAE1&displaylang=en

I'll keep you posted on my progress with ISAPI.

Author

Commented:
Why ISAPI Filters not wotking in Windows 7 x64 (IIS7)?
DLL Compiled for x64 target, but not working. No errors, warning, only nothing in browser(site works fine).

Author

Commented:
I had some problem with site / domain configuration, now fixed and working. I'm tested UpCase ISAPI filter from SDK.
Commented:
Working C code compiled as c++ code in visual studio 2008  :
#include <windows.h>
#include <httpfilt.h>

BOOL WINAPI __stdcall GetFilterVersion(HTTP_FILTER_VERSION *pVer)
{
        pVer->dwFlags = (SF_NOTIFY_NONSECURE_PORT | SF_NOTIFY_URL_MAP | SF_NOTIFY_SEND_RAW_DATA | 
                                         SF_NOTIFY_ORDER_DEFAULT | SF_STATUS_REQ_FINISHED | SF_NOTIFY_PREPROC_HEADERS);
        pVer->dwFilterVersion = HTTP_FILTER_REVISION;
        strcpy_s(pVer->lpszFilterDesc, sizeof(pVer->lpszFilterDesc), "Alternative Home Page");
        return TRUE;
}

DWORD WINAPI __stdcall HttpFilterProc(HTTP_FILTER_CONTEXT *pfc, DWORD NotificationType, VOID *pvData)
{
//CODE....
        return SF_STATUS_REQ_NEXT_NOTIFICATION;
}

Open in new window

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial