Hotlinking

| | Comments (12) | TrackBacks (2)

I have two sites consistently hotlinking to me: xanga.com and myspace.com. If you post pictures or graphics, you are undoubtedly having this problem with these two sites, too. I noticed one of them a while back when I had a bit of a spike in bandwidth use and discovered that xanga actually promotes the practice. Iím not really close to my bandwidth limit but I just donít care for this. The users at both sites appear to be mostly teenagers and internet novices. They do this because theyíve been told its ok or they think everything on the internet is theirs for the taking. Iíve tried a few things to prevent it and my host is still trying a few things but our efforts have so far been futile. We're still working on it so things may get wonky around here with permission errors from time to time.

Quote of the Day
I was going to order a drink, but now Iíd feel cheap.
Margherita Fox

Blog of the day here.

Quote from said blog: "Of course, my teenage component is fascinated with anything that screams into the atmosphere at 29,000mph (8mps) and can survive the sort of decelerations involved."

2 TrackBacks

Listed below are links to blogs that reference this entry: Hotlinking.

TrackBack URL for this entry: http://01f3666.netsolhost.com/cgi-bin/mt/rf20908-tb.cgi/119

» Friday fluff (January 20, 2006) from CrabAppleLane Blog

I like the road warriors to advance in this weekís NFL playoffs, Steelers and Panthers. Itís because of the two Jakes. Jake Delhomme is a big game player. Jake Plummer isnít. My guess is Champ Bailey will be assigned to Steve Smith this weekend. It won... Read More

» Blogging today from CrabAppleLane Blog

This article today at MSNBC.COM reminded me that I havenít checked my referrer logs lately. Iíve had some trouble with myspace.com users hotlinking to images at the blogs here. That activity is annoying to me but not much more than that. The death thre... Read More

12 Comments

kim said:

I've had this problem, too. Xanga is the worst! I researched how to block things using an .htaccess file. I never could get it to do exactly what I wanted, but through trial and error I ended up with a solution.

Kem White said:

Uh, not to appear ignorant, but how do I tell if I have hotlinking to my site?
K-

Rob said:

You have a solution for dummies, Kim? I'm interested.

Kem,

In my referrer logs, I have the following line:

http://profile.myspace.com/index.cfm?fuseaction=user.viewprofile&friendID=2189800 -> /roblog/archives/51604aa.jpg

Rob said:

Oh, Kem

The first part is the offending site, the second part is the image file. If you go to the site, my image (A raccoon, I think) is showing on their site. They didn't take that picture, they didn't pay to store it, and its not their bandwidth. It's wrong all around.

Check your referrer logs.

Kem White said:

OK, where are my referer logs? My ISP admin page doesn't have anything like that.
K-

Rob said:

You probably have to get to them from your site via your ftp program. They're in a separate folder on my site. Probably yours, too. If you still can't find them, ask your host, IVC.

Light & Dark said:

Rob:

Easiest way is just to use the htaccess file to enforce the requirement that image files (.jpg, .gif, .png) can only be referred (linked) from pages within your own domain. (unless you have images that need to available for hotlinking.) Anything linking to one of the specified file formats from outside crabapplelane.net will just get an error.

This is very basic stuff, unless your host has a particularily unusual installation. On hosts using cPanel for the admin panel, it's even a one-button click. Your host SHOULD know how to do this with their eyes closed and one server tied behind their back! ;)

Here's the code to put in your .htaccess file in the root directory:


RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://crabapplelane.net/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://crabapplelane.net$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.crabapplelane.net/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.crabapplelane.net$ [NC]
RewriteRule .*\.(jpg|jpeg|gif|png|bmp)$ [R,NC]


If you want, you can even force all outside referrers to such restricted images to redirect to another file - like a nasty replacement image if you're feeling vindictive, or to a copyright education page, or whatever you want. If you want to do that, lemme know & I'll give you the adjusted code.

Paul

Rob said:

Appreciate it, Paul, but that didn't work, either. Every solution so far has worked beautifully on a site that I wanted to allow hotlinking on, however. Nothing short of full password protection has stopped myspace.com from hotlinking successfully. If I could just block them and xanga.com, I'd be a happy camper. One Movable Type user complained that he was over his bandwidth limit and locked out from his site because of myspace. I'm not quite that desperate. Yet.

cul said:

Hey there, thanx for the "site of the day" linkage.

re the hotlinking dilemma: One thing I do is to bother renaming the file being hotlinked to (cumbersome, I know) and at the same time send a standard email to the offender educating them about the theft of bandwidth issue and that they are more than welcome to download the pic for themselves and then upload it to their server. I've found that every person I've contacted about it apologizes and stops.

Rob said:

You're welcome and thanks, cul. I've renamed the files a few times but sending an email to all of the offenders is a bit too much right now. There are just too many and I would rather that they didn't know that I know. I don't want to antagonize a bunch of teenagers.

kim said:

I use what Paul suggested, Rob. :\

Light & Dark said:

Rob, if that code doesn't work, I suspect your .htaccess file may not be working at all. (perhaps due to missing Apache modules on the server?) Who are you using for hosting?

There's also a way to code it to specifically exclude certain domains. When I've got a bit more time tonight, I'll look up the exact syntax and post it for you to try.

P.

Leave a comment

About this Entry

This page contains a single entry by Rob published on January 17, 2006 5:37 AM.

The Big Sleep was the previous entry in this blog.

Luck of the Irish is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.

Powered by Movable Type 4.1