http://drupal.org/node/303419 From: andrew morton Incorrect exipration headers with private file transfers --- modules/image/image.module | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git modules/image/image.module modules/image/image.module index 7b53073..1b17339 100644 --- modules/image/image.module +++ modules/image/image.module @@ -207,6 +207,8 @@ function image_file_download($filepath) { return array( 'Content-Type' => $info['mime_type'], 'Content-Length' => $info['file_size'], + 'Expires' => gmdate('D, d M Y H:i:s', time() + 1209600) .' GMT', + 'Cache-Control' => 'max-age=1209600, private, must-revalidate', ); } } @@ -577,7 +579,7 @@ function image_style_url($style_name, $path) { // Set a cache entry to grant access to this style/image path. This will be // checked by image_style_generate(). cache_set('access:' . $style_name . ':' . md5($path), 1, 'cache_image', REQUEST_TIME + 600); - + $scheme = file_uri_scheme($path); $target = file_uri_target($path);