9 Oct 2005

Voleurs de bandwidth

Posted by dumpendebat

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.

Subscribe to Comments

5 Responses to “Voleurs de bandwidth”

  1. 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!



  2. 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.



  3. En francais, “Bandwidth” est dit “Bande passante”.



  4. Merci. La prochaine fois, je dirai “Voleurs de la bande passante.”



  5. Good job.



Leave a Reply


  • Browse

  • Older DPF Archives

  • Post Categories

  • Twitter @dumpendebat

    • #Centrafrique: près de 600 militaires français déployés sur place - 04/12 http://t.co/z0ra7sXSx9
    • Dennis Rodman to return to #NorthKorea to train basketball team http://t.co/utExO7PvEt
    • #Mali, Tuaregs fault France on failing peace talks http://t.co/1ClMyaD6Jv
    • #Uganda Police Deny Detaining Kampala Leader, Family http://t.co/cWuaO86Hct
    • Armed militia attack Moyale, cut off link to #Ethiopia or #Kenya http://t.co/1wwRW2fYmQ
    • #Ethiopia: A Lifeline to the World (Birtukan Mideksa and Eskinder Nega) http://t.co/EfL5he8XEv
    • Amnesty urges #Ethiopia to release jailed journo Eskinder Nega http://t.co/rEACcqkrDc
    • RT @AAWaberi: #Djibouti #Paris #MAnif contre la dictature. Il reste quelques place ce weekend. Ne ratez pas la fête http://t.co/XKSfTzPGUp
    • Central African Republic: Where have all the people gone? http://t.co/moHMQmg5Kw #Centrafrique
    • Laurent Fabius: l'objectif en #Centrafrique est «d'assurer la sécurisation et la reconstruction» http://t.co/qGPzrp4N2U
  • Meta