views:

477

answers:

1

I am using Appweb server (mini http server) and facing an issue while opening a webpage using https. The page is getting truncated and when looked at HTTP response headers found that webserver is sending response in chunks (Transfer-Encoding set) and that is the root cause. It seems to be a bug in webserver.

I built webserver again disabling Http chunking support and found that the page is loading fine. This page is being loaded inside an iframe.

I don't want to disable Http chunking for all webpages as it may have degrade some performance for other pages. So, I want to know if there is a way to set the custom request headers for the page that is being loaded in an iframe so that i will send http chunking not supported for that webpage alone.

Thanks, Naga Kiran

A: 

Unless you're distributing the browser, you won't be able to dictate when IE/Firefox/Safari/etc. set the TE header. You may be able to register a callback in your webserver's request handler before headers are processed, and remove the TE header, but...

Unfortunately, the TE: client header only has to appear in requests that also have the Connect: header, which are usually only at the beginning and end of the pipeline (see rfc2616), which means that if a browser is already reusing the connection for the page you don't want chunked, then you're out of luck.

A hack: you may consider embedding a second instance of the webserver that has chunking disabled and serve only the problem page from there. Obviously this requires running the server on a different vhost or port.

It's most ideal if your vendor can just fix the bug, but I know you don't get to pick the timing on that :-)

webmarc