How to change HTTP headers to static files served by JBoss
I have a web application (.war) that contains some static files (like MS text documents). When I try to download these files, JBoss automatically sets some HTTP headers in the response. Is there a way to tune JBoss (version 3.2.7) to set these headers to specific values (or omit them)? I'm especially interested in
Cache-Control: no cache
because it leads to some problems when uploading files over https using Internet Explorer (IE will refuse to save the file to disk).
Btw. this behavior can be changed by adding an entry to the Windows Registry:
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings]
"BypassSSLNoCacheCheck"=dword:00000001
but obviously I'm not going to ask clients to mess with their registry just to download the file.
Any suggestions are greatly appreciated.
+1
source to share