Welcome to madhatt.com

A Simple website from a computer geek in Colorado with dreams of moving to Alaska

My Travels Photo Gallery

Protecting your original images in Coppermine Photo Gallery

Below is a simple script I wrote that protect my original images from being copied by some lazy ass.


What does this mean?

Well, When Coppermine Photo Gallery works with new images I have it set up to watermark the image.  This is done so people can't simple copy my images.  The problem with this is that it's very easy to determine the URL to the original image that contains no water mark.  So mr lazy guy could just link directly to the deep URL of the original file and bypass all my hard work.


So using the script below we simple remove the permissions needed to read the original photos.


echo "Please enter permission level "
read input_variable
find /location/of/your/gallery -name 'orig_*' -exec chmod $input_variable {} \;


What the script will do is find all the files that match orign_* which is what Copermine uses to designate the original file.  Once it finds these files it will chmod them to the permissions that you entered into the script.