I use Brilliant Gallery with private files in Drupal, and some of my files were not loading correctly. The problem was related to the code which checked the dimensions and used exact path if the image is "small enough", instead of getting them from image.php. In case of private files, such url could not be served directly, causing missing images.
I added code to image.php to copy image as is, without resizing and caching, so "small enough" images are not resized (as before) but this way they display ok in private filesystem environment. This could also be used for downloading original image (if only I knew how to hack 'download' link into lightbox overbrowser!).
I also added permission check to image.php so that a user which does not have 'access brilliant_gallery' permission would not be able to see the images at all.
The patches are against development snapshot version in download area, not against HEAD. I apologize if the code is not up to standards, I am a total Drupal/PHP noob.
| Comment | File | Size | Author |
|---|---|---|---|
| image.php_.patch | 3.56 KB | vadim.bich | |
| brilliant_gallery.patch | 3.11 KB | vadim.bich |