Trace What URLs You Have Visited With JavaScript

Philipp Lenssen —”This looks like a bit of a privacy hole in browsers. Using JavaScript which reads out link style attributes, a page can determine which URLs in a given URL list have been visited.” For example, in the CSS you can define visited links to have larger padding than non-visited links, and now you […]

Share online:

Philipp Lenssen —”This looks like a bit of a privacy hole in browsers. Using JavaScript which reads out link style attributes, a page can determine which URLs in a given URL list have been visited.”

For example, in the CSS you can define visited links to have larger padding than non-visited links, and now you can iterate through the list of links and check against the “offsetHeight" value... if it’s the higher value, the URL was visited.

Naturally, this information can now be transmitted to the server using AJAX or a form submit. I wrote a very small test case (works in IE and FF) based on findings by Scott Schiller.

Micro Persuasion | Google Blogoscoped

Trace What URLs You Have Visited

About The Author

Deepak Gupta is a IT & Web Consultant. He is the founder and CEO of diTii.com & DIT Technologies, where he’s engaged in providing Technology Consultancy, Design and Development of Desktop, Web and Mobile applications using various tools and softwares. Sign-up for the Email for daily updates. Google+ Profile.