views:

878

answers:

2

Hi,

I desperately need help with this one. I have a classic ASP website in IIS 5, where I need to stream pdf to users. I am using ADODB.Stream to generate chunks of binary data and using response.BinaryWrite to stream it to client. Now problem is that there is a known feature in IE which sets the Response CacheControl header to "no-cache" by default for SSL (https) sites. Hence I am getting the standard error:

"Internet Explorer cannot download File.doc from ServerName.

Internet Explorer was not able to open this Internet Site. The requested site is either unavailable or cannot be found. Please try again later."

I have set Response.CacheControl = "private,must-revalidate,max-age=3600" before streaming, but it still give the error.

Note: The same code works perfectly in all other browsers like firefox and netscape.I am using LiveHttpHeaders in firefox to see that Response.CacheControl is automatically set correctly in firefox. Unfortunately i cannot install Fiddler on my machine, but i am guessing problem is due to IIS default header CacheControl = "no-cache" for https

I have unchecked the "Do not save encrypted pages to disk" option in IE.

I need a way around this since the option has to be made available very soon to users over the internet with existing technology :(

A: 

You might be able to get away with dropping support for Internet Explorer 5.5 as it has less than .5% of the market. It so low they stopped tracking it on in jun 08'

Byron Whitlock
But how to make it work in ie 6/7/8 or does this problem not occur in higher versions?
NeoBieKid
Try IE 6 and let us know.
Jeremy Stein
Sorry, but do not have IE6 installed in test pc (not under my control). However found this link http://support.microsoft.com/kb/323308It says won't work with IE 6 sp 1, and instead to use a 'HREF' which it seems would require 'http' link - hence useless..did older web sites in classic asp never offer https file download?!!! cannot be - so dere must be a way
NeoBieKid
A: 

Start here: http://blogs.msdn.com/ieinternals/archive/2009/10/02/Internet-Explorer-cannot-download-over-HTTPS-when-no-cache.aspx to see a fuller discussion of this issue. It's quite likely that you're sending one or more headers that forbid caching.

The statement...

there is a known feature in IE which sets the Response CacheControl header to "no-cache" by default for SSL (https) sites

... is incorrect. Did you mean to say "IIS"? Which version? I've never heard of such a feature.

I don't know why you can't use Fiddler on the machine in question?

EricLaw -MSFT-
Hi Eric, thx for the very useful blog..and yes, i meant 'IIS' instead of 'IE'..thx for spotting d error.The version of IIS is 5.0. About Fiddler, it is asking for .NET framework which is missing in my pc, and it is going to take a while for me to get the approval for its installation (dats how my company works).In the meantime i had hoped to use some oder tool, but have not been much successful...will try to get Fiddler working as it seems to be d only hope now!
NeoBieKid
btw, my operating system is Win 2000, in case it helps.
NeoBieKid
If you can't use fiddler, there are older http sniffers like proxomitron.
Dzejms