nixCraft Linux Sys Admin Blog |
| Lighttpd mod_rewrite Hotlink Protection To Display Image Message Posted: 12 Jun 2008 11:19 AM CDT Many of our regular readers like to know more about lighttpd hotlink protection using mod_rewrite. Lighttpd can use HTTP referer to detect hotlink and can be configured to partially protect hosted media from inline linking, usually by not serving the media or by serving a different file. Lighttpd anti hotlinking configuration - redirect to another mediaOpen lighttpd.conf configuration file: $HTTP["referer"] =~ ".*BADDOMAIN\.com.*|.*IMAGESUCKERDOMAIN\.com.*|.*blogspot\.com.*" { url.rewrite = ("(?i)(/.*\.(jpe?g|png))$" => "/hotlink.png" ) } So if anyone from *.blogspot.com linked www.cyberciti.biz/image.png it will be replaced with www.cyberciti.biz/hotlink.png. I've written small script to detect excessive hotlink from log file and ban all those domains. Most types of electronic media can be redirected this way, including video files, music files, and animations etc. Related: Apache web server user can stop lechers using mod_rewrite / .htaccess rules. Related Posts:
© Lighttpd mod_rewrite Hotlink Protection To Display Image Message - nixCraft - Support nixCraft when you shop at amazon. Thanks! |
| Download of the day: Opera Browser Software 9.50 Posted: 12 Jun 2008 10:57 AM CDT Opera browser software version 9.50 has been released and available for download. From the release note:
Personally, I'm more interested in Opera Dragonfly upcoming developer tool, which makes developing using Opera easier than ever, both on your computer and mobile phone.. It includes:
See complete feature list here online: Download Opera 9.50
Related Posts:
© Download of the day: Opera Browser Software 9.50 - nixCraft - Support nixCraft when you shop at amazon. Thanks! |
| Posted: 12 Jun 2008 12:13 PM CDT Can you explain DNS name resolution concept? Why I need to set DNS resolution for my Windows or Linux server? How do I setup DNS name resolution under Linux / UNIX server system? Answer to "DNS Name Resolution" Copyright © nixCraft. All Rights Reserved. Support nixCraft when you shop at amazon. Thanks! |
| You are subscribed to email updates from nixCraft Linux Sys Admin Blog To stop receiving these emails, you may unsubscribe now. | Email Delivery powered by FeedBurner |
| Inbox too full? | |
| If you prefer to unsubscribe via postal mail, write to: nixCraft Linux Sys Admin Blog, c/o FeedBurner, 20 W Kinzie, 9th Floor, Chicago IL USA 60610 | |
No comments:
Post a Comment