Discussion:
Permissions
Rene Joergensen
19 years ago
Permalink
Hi,

When the GalleryCacheDir is created, it's created with 0755. Which means
that even if an area of your gallery needs authentication, people with
access to the server, can retrieve the images from the cache.

A small patch to fix the problem:

--- Gallery.pm.org 2006-04-25 01:52:56.274489480 +0200
+++ Gallery.pm 2006-04-25 01:53:46.394890090 +0200
@@ -814,13 +814,13 @@

unless (-d $dir) {

- unless (mkdir($dir, 0755)) {
+ unless (mkdir($dir, 0700)) {
my $parent = $dir;
$parent =~ s/\/[^\/]*$//;

mkdirhier($parent);

- mkdir($dir, 0755);
+ mkdir($dir, 0700);
}
}
}
--
-René
Loading...