Connecting Tech Pros Worldwide Help | Site Map

Prevent client image caching

=?Utf-8?B?SmVmZiBCZWVt?=
Guest
 
Posts: n/a
#1: May 5 '07
I'm working on a litigation web app where users will review images of case
documents. One of the requirements is that we either prevent the images from
being cached on the clients machine (in temp directory or anywhere else) or
we encrypt the images somehow. I'm guessing that encryption will not work,
but is there a way to prevent caching?

Also, is there a way to prevent printing on a current page? We're already
not showing the menu or toolbar, but is there any way to disable hotkeys
(Shift+P)?

Thanks in advance,

J. Beem
Alexey Smirnov
Guest
 
Posts: n/a
#2: May 5 '07

re: Prevent client image caching


On May 5, 10:02 pm, Jeff Beem <JeffB...@discussions.microsoft.com>
wrote:
Quote:
I'm working on a litigation web app where users will review images of case
documents. One of the requirements is that we either prevent the images from
being cached on the clients machine (in temp directory or anywhere else) or
we encrypt the images somehow. I'm guessing that encryption will not work,
but is there a way to prevent caching?
>
Also, is there a way to prevent printing on a current page? We're already
not showing the menu or toolbar, but is there any way to disable hotkeys
(Shift+P)?
>
Thanks in advance,
>
J. Beem
http://.....gif?random_num would probably help

gover
Guest
 
Posts: n/a
#3: May 6 '07

re: Prevent client image caching


There arre HTTP Headers that can be used to prevent caching, You could also
use some css classes to hide data when a page was printed via the browsers
print function.
However,you cant stop the user from preesing the windows printscreen button
to get an image of whats on the sceen..
"Jeff Beem" <JeffBeem@discussions.microsoft.comwrote in message
news:5C67A962-FB09-400B-8275-6F0861F1DC09@microsoft.com...
Quote:
I'm working on a litigation web app where users will review images of case
documents. One of the requirements is that we either prevent the images
from
being cached on the clients machine (in temp directory or anywhere else)
or
we encrypt the images somehow. I'm guessing that encryption will not
work,
but is there a way to prevent caching?
>
Also, is there a way to prevent printing on a current page? We're already
not showing the menu or toolbar, but is there any way to disable hotkeys
(Shift+P)?
>
Thanks in advance,
>
J. Beem

Eliyahu Goldin
Guest
 
Posts: n/a
#4: May 6 '07

re: Prevent client image caching


Yes, it will.

If you make image urls on server side, you can use Random class.

If you make them on client side, you can use (new Date()).getMilliseconds()
as a sort of a random numer generator.

--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
http://msmvps.com/blogs/egoldin
http://usableasp.net


"Alexey Smirnov" <alexey.smirnov@gmail.comwrote in message
news:1178397882.357422.146670@h2g2000hsg.googlegro ups.com...
Quote:
On May 5, 10:02 pm, Jeff Beem <JeffB...@discussions.microsoft.com>
wrote:
Quote:
>I'm working on a litigation web app where users will review images of
>case
>documents. One of the requirements is that we either prevent the images
>from
>being cached on the clients machine (in temp directory or anywhere else)
>or
>we encrypt the images somehow. I'm guessing that encryption will not
>work,
>but is there a way to prevent caching?
>>
>Also, is there a way to prevent printing on a current page? We're
>already
>not showing the menu or toolbar, but is there any way to disable hotkeys
>(Shift+P)?
>>
>Thanks in advance,
>>
>J. Beem
>
http://.....gif?random_num would probably help
>

=?Utf-8?B?UGV0ZXIgQnJvbWJlcmcgW0MjIE1WUF0=?=
Guest
 
Posts: n/a
#5: May 6 '07

re: Prevent client image caching


Unfortunately, I have found that (at least with Internet Exploder) virtually
every combination of no-cache headers and random querystrings on the image
url still result in the image going into the Temporary Internet Files folder
immediately upon the page having completed loading.

While it may disappear later after the browser is closed, there is nothing
to stop a user from choosing Tools/Internet Options /Settings /View Files to
be able to copy this image out of the folder and save it somewhere else.

Try some combinations and let us know if I am correct in this.

Peter

--
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short urls & more: http://ittyurl.net




"Jeff Beem" wrote:
Quote:
I'm working on a litigation web app where users will review images of case
documents. One of the requirements is that we either prevent the images from
being cached on the clients machine (in temp directory or anywhere else) or
we encrypt the images somehow. I'm guessing that encryption will not work,
but is there a way to prevent caching?
>
Also, is there a way to prevent printing on a current page? We're already
not showing the menu or toolbar, but is there any way to disable hotkeys
(Shift+P)?
>
Thanks in advance,
>
J. Beem
MasterGaurav \(www.edujini-labs.com\)
Guest
 
Posts: n/a
#6: May 6 '07

re: Prevent client image caching


Unfortunately, I have found that (at least with Internet Exploder)
Quote:
virtually
every combination of no-cache headers and random querystrings on the image
url still result in the image going into the Temporary Internet Files
folder
immediately upon the page having completed loading.
I second.
The only way out it http://someserver.com/image.jpg?{DateTime.Now.Ticks}

just to fool the browser that it's a new image...


--
Happy Hacking,
Gaurav Vaish | www.mastergaurav.com
www.edujini-labs.com
http://eduzine.edujini-labs.com
-----------------------------------------


=?Utf-8?B?UGV0ZXIgQnJvbWJlcmcgW0MjIE1WUF0=?=
Guest
 
Posts: n/a
#7: May 6 '07

re: Prevent client image caching


Correct, but even in that case if you open the temporary files folder you can
see the image there along with the ?xxxxx querystring item from the url. The
idea here from the OP is "How to completely prevent" an image in a web page
from EVER getting into the cache folder.
Peter

--
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short urls & more: http://ittyurl.net




"MasterGaurav (www.edujini-labs.com)" wrote:
Quote:
Quote:
Unfortunately, I have found that (at least with Internet Exploder)
virtually
every combination of no-cache headers and random querystrings on the image
url still result in the image going into the Temporary Internet Files
folder
immediately upon the page having completed loading.
>
I second.
The only way out it http://someserver.com/image.jpg?{DateTime.Now.Ticks}
>
just to fool the browser that it's a new image...
>
>
--
Happy Hacking,
Gaurav Vaish | www.mastergaurav.com
www.edujini-labs.com
http://eduzine.edujini-labs.com
-----------------------------------------
>
>
>
Alexey Smirnov
Guest
 
Posts: n/a
#8: May 6 '07

re: Prevent client image caching


On May 6, 5:20 pm, Peter Bromberg [C# MVP]
<pbromb...@yahoo.yabbadabbadoo.comwrote:
Quote:
Correct, but even in that case if you open the temporary files folder you can
see the image there along with the ?xxxxx querystring item from the url. The
idea here from the OP is "How to completely prevent" an image in a web page
from EVER getting into the cache folder.
Peter
>
--
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short urls & more: http://ittyurl.net
>
>
>
"MasterGaurav (www.edujini-labs.com)" wrote:
Quote:
Quote:
Unfortunately, I have found that (at least with Internet Exploder)
virtually
every combination of no-cache headers and random querystrings on the image
url still result in the image going into the Temporary Internet Files
folder
immediately upon the page having completed loading.
>
Quote:
I second.
The only way out ithttp://someserver.com/image.jpg?{DateTime.Now.Ticks}
>
Quote:
just to fool the browser that it's a new image...
>
Quote:
--
Happy Hacking,
Gaurav Vaish |www.mastergaurav.com
www.edujini-labs.com
http://eduzine.edujini-labs.com
------------------------------------------ Hide quoted text -
>
- Show quoted text -
Jeff, sorry, I got it wrong the last time, and "?something" seems to
be a bad idea.

Maybe a Flash movie designed to show images could help?

Tigger
Guest
 
Posts: n/a
#9: May 8 '07

re: Prevent client image caching


On May 6, 5:02 am, Jeff Beem <JeffB...@discussions.microsoft.com>
wrote:
Quote:
I'm working on a litigation web app where users will review images of case
documents. One of the requirements is that we either prevent the images from
being cached on the clients machine (in temp directory or anywhere else) or
we encrypt the images somehow. I'm guessing that encryption will not work,
but is there a way to prevent caching?
>
Also, is there a way to prevent printing on a current page? We're already
not showing the menu or toolbar, but is there any way to disable hotkeys
(Shift+P)?
>
Thanks in advance,
>
J. Beem
Is it the caching thats the problem or the fact the client can get a
copy of the image for their own use?

Tigger

MasterGaurav \(www.edujini-labs.com\)
Guest
 
Posts: n/a
#10: May 8 '07

re: Prevent client image caching


Correct, but even in that case if you open the temporary files folder you
Quote:
can
see the image there along with the ?xxxxx querystring item from the url.
The
idea here from the OP is "How to completely prevent" an image in a web
page
from EVER getting into the cache folder.
Peter
You can never prevent the browser's caching through "server".
I can always set the option for cache to "Never look on network" and always
work with cached image.

Yes... one option, as what Alexey suggests is to use Flash or ActiveX or for
that matter... any plug-in.


--
Happy Hacking,
Gaurav Vaish | www.mastergaurav.com
www.edujini-labs.com
http://eduzine.edujini-labs.com
-----------------------------------------


Closed Thread