Author Topic: hotlinking again  (Read 1807 times)

0 Members and 1 Guest are viewing this topic.

Offline weathergirl

  • Forecaster
  • *****
  • Posts: 677
    • Beamsville Weather Station
hotlinking again
« on: July 12, 2011, 05:55:13 PM »
I've found more sites hotlinking to my images, but I'm having a heck of a time getting my .htaccess file to work. I don't think I'm entering the urls to the sites properly.  These are the sites:

http://www.bardininstalaciones.com.ar/nwm-map-of-lincoln-ontario.php

http://largeformat.printerfarm.com/rwf-radar-weather-maps-ontario.php

http://abi99.robu18.de/ktt-radar-weather-maps-ontario

http://bek.minoqlo.com/temperaturein-lincoln.php

http://www.nyttisland.is/Vedurfar/

The second link actually has EC radar images from Ken's site, as well as another site in Ontario.

Ann-Marie
Beamsville, Ontario, Canada

Offline neondesert

  • Forecaster
  • *****
  • Posts: 628
    • http://www.neondesertweather.com
Re: hotlinking again
« Reply #1 on: July 12, 2011, 06:16:43 PM »
Are you trying to block their IP in .htaccess ?

If so, you would use the following syntax:

Code: [Select]
order allow,deny
deny from 192.168.44.201
deny from 224.39.163.12
deny from 172.16.7.92
allow from all

If you want to block a range of IP's then use:

Code: [Select]
order allow,deny
deny from 192.168.
deny from 10.0.0.
allow from all

Don't know if your ISP allows you access to cPanel.  If it does you can use the cPanel interface to setup
.htaccess to stop hotlinking or to ban IP addresses.

Even simpler, just slightly change the filename of image they are linking to if you can.  ;)
Larry
"But it's a DRY Heat!"


Offline Bushman

  • Forecaster
  • *****
  • Posts: 7549
    • Eagle Bay Weather
Re: hotlinking again
« Reply #2 on: July 12, 2011, 06:20:18 PM »
Looking at some of those sites, why would you care?  They are bots.
Need low cost IP monitoring?  http://wirelesstag.net/wta.aspx?link=NisJxz6FhUa4V67/cwCRWA or PM me for 50% off Wirelesstags!!

Offline weathergirl

  • Forecaster
  • *****
  • Posts: 677
    • Beamsville Weather Station
Re: hotlinking again
« Reply #3 on: July 12, 2011, 06:21:44 PM »
Thanks. So, I don't have to worry much about bandwidth then?
Ann-Marie
Beamsville, Ontario, Canada

Offline moto51

  • Senior Member
  • **
  • Posts: 67
    • Jubilee Weather
Re: hotlinking again
« Reply #4 on: August 07, 2011, 12:22:52 AM »
I have had little success with .htaccess hot linking but the cPanel protection is great, i've put an image up on tinypic so that it comes up with a nice big warning that will kill their viewers load times whenever they hotline to my websites.

Offline TNETWeather

  • Kevin Reed (KrelvinAZ)
  • Senior Contributor
  • ****
  • Posts: 193
  • Davis Vantage Pro2+ with full FARS
Re: hotlinking again
« Reply #5 on: August 07, 2011, 09:53:40 PM »
Hot link protection works best by checking the referrer, not the IP that is actually getting the data since they are only following the link they got when they visited the page that is hot linking your data.

This way if 100 more sites start to do it, the same rules in effect block them as well.

For this to work properly, you have to have the unauth image has to be outside of the area you are protecting.

As an example... on one of my weather sites, I have static created content (updated by cron once a minute) that is in a directory called grlevel3

So, IN that directory /grlevel3 , I have an .htaccess that includes:

RewriteEngine on
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^.*.myvzw.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.tnetweather.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.grlevelx.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://test02.tnet.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://cumulus2.tnet.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://grlevelx.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://test04.tnet.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://cumulus.tnetweather.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://weatherbus.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.weatherbus.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://weather-watch.com/.*$  [NC]
RewriteCond %{HTTP_REFERER} !^http://www.weather-watch.com/.*$  [NC]
RewriteRule .*\.(gif|GIF|jpg|JPG|png|PNG)$ http://www.tnetweather.com/images/UNAUTHWEATHER.gif [R]


The entries up to the last one are the sites that I allow to hotlink.  Most of them primarily because I have used them in forums that are weather related and I want them to be allowed.

The last entry points to the image that provides the unauth image.  It protects any image, jpg, gif, png located in that directory or lower.  The block image In this case, it looks like:

 


If someone goes directly to the image, they will see it just fine, same as if they are referred by any of the allowed sites.  If they go to another site which links to content there, it shows up in the visitors browser.
All you need is Time, Aptitude and Desire ... and you can build just about anything...