9 Oct 2005
Voleurs de bandwidth
That’s supposed to mean “bandwidth thieves.” (S’il y a un lecteur francophone qui pourrait me donner la traduction française du mot anglais “bandwidth,” je serais content de savoir ce que c’est.) I’ve been having a problem with “hot-linking” recently.
I started seeing heavy traffic in my HTTP logfiles coming out of various Internet forums and message boards, the guiltiest party of all being this one, apparently some francophone psychology discussion group. Scroll down on the page there and you’ll see where some kind soul offered to “preparer le petit dej pour tout a l’heure,” which “preparation” seems to have consisted of searching Google Images for pictures of various breakfast-type foodstuffs, copying the image files’ URLs, and hot-linking those images right onto that wretched forum. (It did look like a tasty breakfast, I’ll admit.) Somehow, Dum Pendebat Filius had become the #1 result on Google Images for “croissant” (and “hammer and sickle” as well!).
So, every time someone looked at that forum post, my server was getting a request for an image file (a picture of a delicious-looking croissant, which originally appeared in a post about the Flight 93 Memorial).
You see, what good little boys and girls do when they want to post pictures on their websites is to upload those images to their own servers, or to some third-party site that offers free storage space for this purpose. Bad boys and girls just steal someone else’s bandwidth by linking directly to the image files on someone else’s site, without permission. This is a big no-no on these Internets.
Happily, my webhost allows me to configure my own .htaccess file. This allows me to deny incoming requests for image files and return an error code (403 Forbidden) instead of serving up my image files to anyone who wants them.
I was getting hit by that French psychology group; some Italian message board was draining my meagre resources with requests for that hammer-and-sickle; even the “St. Louis Today” message board was hitting me with image-file requests. When I first saw the high number of hits, I thought I had found a brief moment of Internet fame. But, alas, it was just bandwidth thieves hot-linking to my image files, thanks to my sudden and brief popularity on Google Images.
My original plan was to force a URL redirection so that hot-linkers would not get the picture they wanted, but would instead get a picture of a cartoon character “flipping the bird,” but I couldn’t manage to get the rewrite rules to work (I thought I had some skills with Apache HTTP Server, but I guess I’m still an amateur). So I settled for returning “403 Forbidden” instead.
If you want to block hot-linkers on your own website (and you have access to your .htaccess file), you might find these resources useful, like I did:
- Altlab.com has a brief explanation, and a tool you can use to test your site’s hotlinking protection.
- Apache’s mod_rewrite reference.
- Selective hotlinking protection through .htaccess, by Underscorebleach.net.
I have to confess that I have been guilty of bandwidth theft in the past. I’ve linked to your .mp3 files from a site I have access to for reminding my students of homework assignments. I couldn’t upload files but I could link to them. Foolishly, I didn’t know I was doing anything wrong until I was eventually “flamed” by an angry blogger to whom I also occasionally linked.
My bad. A little bit of knowledge of html is often not better than none at all.
Je ne sais pas le dire en français, aber es tut mir leid!
RP
October 9th, 2005 at 20:20permalink
I don’t mind with the MP3s, since I put them there for public consumption, and they get taken down after a few days anyways. And certainly I don’t mind from someone who knows me in “real life.” But I don’t want somebody using an image hosted on my server as their personal “avatar” on some message board so that I get to serve up a 25KB GIF image every time someone reads a message on that forum.
dumpendebat
October 9th, 2005 at 20:33permalink
En francais, “Bandwidth” est dit “Bande passante”.
Benoit
October 10th, 2005 at 10:42permalink
Merci. La prochaine fois, je dirai “Voleurs de la bande passante.”
dumpendebat
October 11th, 2005 at 09:49permalink
Good job.
Few
August 7th, 2006 at 19:32permalink