Tuesday 19 March 2013

Building Better IIS Servers using ISAPI Filters

What are they used for?

ISAPI Filters are simply DLLs (ISAPI stands for Internet Server API - Microsoft's answer to CGI applications).

How are they written?

ISAPI Filters are used to modify and expand the functionality of IIS. Both ISAPI filters and extensions are developed in C++.

How do they work?

Suppose you have an HTTP transaction between the browser and IIS. Several events may be generated in this process. Some of the these events may be subscribed to by "filters". Filters will be applied in the order of priority. If the event relates to the filter, IIS knows that it has to invoke the HttpFilterProc entry point. The filter can then do some custom processing.

Notable Examples

ASP technology is implemented as an ISAPI filter (DLL that gets loaded up into the same memory space as IIS).

Related Tangent: What EXACTLY do we mean by CGI? CGI stands for Common Gateway Interface. It's a method for for web server software to delegate generation of web content to executable files. A variation called FastCGI is implemented by a number of web servers such as Apache, Cherokee and IIS.

No comments: