Apache::RefererBlock - block request based upon referer header
In the configuration of your Apache add something like
PerlModule Apache::RefererBlock PerlFixupHandler Apache::RefererBlock PerlSetVar AllowedReferers "http://www.mydomain.com http://mydomain.com" PerlSetVar CheckMimeTypes "image/gif image/jpeg"
Apache::RefererBlock will examine each request. If the Mime type of the requested file is one of those listed in CheckMimeTypes, it will check the referer header. If the referer doesn't start with one of the strings listed in AllowedReferers, a "Forbidden" error will be returned.
Eric Cholet, cholet@logilune.com
To install Apache::RefererBlock, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Apache::RefererBlock
CPAN shell
perl -MCPAN -e shell install Apache::RefererBlock
For more information on module installation, please visit the detailed CPAN module installation guide.