Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Obfuscating email in html

I'm currently developing a website, into which I've included a filter that attempts to obfuscate any e-mail addresses present in the webpages it serves.

As it is now, it converts the addresses into images.

I've also seen a few other methods in use; some split the address into characters and use generated javascript to include it in the final document, but that requires javascript, so it's not that useful in my opinion. The upside is it can be used to create a working mailto-link.

Another method, quite similar to the above, uses hex-notation to markup the e-mail address. I'm not really convinced it will thwart any serious harvesters though.

Others utilize the human brains' ability to understand language, and will either replace characters like the @-symbol with words, or separate the host and the username etc.

My question now is, how reliable is my method, of using generated images (whose filename do not give the address away) against scrapers, when I'm not using any distortion on the text in the images? Should I prefer a different method?

And as a continuation: if I wan't a fallback method, just in case the image creation should fail for some reason, which would be the smartest way to go?

like image 246
nikc.org Avatar asked Feb 08 '10 16:02

nikc.org


3 Answers

Here you'll find many ways of obfuscating emails, and their effectiveness.

Hope it helps!

like image 66
Pablo Fernandez Avatar answered Oct 13 '22 11:10

Pablo Fernandez


My question now is, how reliable is my method, of using generated images (whose filename do not give the address away) against scrapers, when I'm not using any distortion on the text in the images?

I don't have any data to back that up, but I would say: Quite reliable. Harvesters can get millions of addresses using "conventional" means; I don't think it's economically feasible for them to do image processing just to get a handful more.

And as a continuation: if I wan't a fallback method, just in case the image creation should fail for some reason, which would be the smartest way to go?

Use a good spam filter. :-) No, seriously, it's really hard keeping a mail address hidden from harvesters.

like image 44
Heinzi Avatar answered Oct 13 '22 12:10

Heinzi


one possibility is to continue using the image, but replace it with text and a mailto link if javascript is enabled.

like image 30
cobbal Avatar answered Oct 13 '22 12:10

cobbal