简体   繁体   中英

IIS ISAPI Extension + How to Modify HTTP response body

On IIS6, I know ISAPI filter can easily do this, but I am trying to do the same in an ISAPI Extension.

I would like to let IIS handle a request, but be able to Append some string to the response.

Is there a callback that would let me modify the http response before it's sent?

Such as:

Client request: index.html ISAPI extension gets called, and forward the request to IIS with: HSE_REQ_EXEC_URL ISAPI entension gets called again, with the response, modify it, and send it.

Just can't seem to find any ServerSupportFunction that does that:(

Thanks you

You can't. You need to use an output (send_raw_data) filter.

Well, OK, there's a sneaky way to simulate this, but it has perf implications - you can manually request the document from the server using winhttp or something. Tons of code to get it right, though.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM