2

I'm using the latest version of Firefox with Ghostery and Adblock plus installed. This website somehow prevents navigation away from it. How does it do this and how can it be protected against?

I can't even close the browser now.

http://www.imagesnake.com/ad.html I didn't realize it at first as I was using Adblock Plus but the site causes popups containing pornography.

  • You shouldn't just paste a link to the malicious website that can be clicked on too easily, paste it as plaintext. – user10008 Aug 24 '14 at 19:57
  • @user10008 I did, it automatically is linked to – Celeritas Aug 24 '14 at 19:58
  • post a link as hxxp://whatever.com, that's becoming more standard. – Matthew Peters Aug 25 '14 at 17:54
5

I did visit the page (from a safe place!) and it's triggering the beforeunload event to change the URL, like this:

var exit=true;
var temp_url = document.location.href;
var url_pieces = new Array();
url_pieces = temp_url.split("/");
var goto_url = 'http://www.imagesnake.com/ad.html' ;
window.onbeforeunload = function () {   
if(exit==true){ 
    location.replace(goto_url);   
    return "   Special Offer: Free Porn Videos ";
}
}

I did this with Chrome, and got the "Page is asking if you want to leave..." dialog, and was able to close the page. I can guess that, depending on the browser, one might not be able to get out.

There may be other tricks in the plethora of JavaScript the page loads. This is the one that stood out for me, based on the browser dialog.

  • Which url is the relevant javascript on? – user10008 Aug 25 '14 at 4:57
  • That's interesting, I wonder what is it about Firefox that it can't leave the page even by trying to close the browser. – Celeritas Aug 25 '14 at 9:00
  • @user10008 the non-pornographic one – Celeritas Aug 25 '14 at 9:00
  • I'll try to test with FF, but will have to set up a VM with which to do so, so probably tomorrow. – Bob Brown Aug 25 '14 at 13:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.