try { hrefHash = searchshield.avgCallFunc(this.doc, 'GetHash', inHref); } catch (e){} var newNode = { element: inElement, href: inHref, hash: hrefHash, search: this.searchHash }; this.links.push(newNode); return newNode;}// process the search result page after all search engines have been addedsearchshield.Search.prototype.process = function(doc){ // only process when searchshield is enabled if (!searchshield.enabled(doc)) return; this.doc = doc; this.href = this.doc.location.href; this.uri = searchshield.parseLink(this.href); try { this.searchHash = searchshield.avgCallFunc(this.doc, 'GetHash', this.href); // get any previously active engine this.engine = this.engineList[this.searchHash.toString()]; } catch (e) {} /* Process Steps: 1. Add all supported search engines 2. Identify the active search engine 3. Get all document links and add AVG images */ // STEP 1 - Add all supported search engines if (!this.engines) { var aEng = xplSearch.getSearchNames(); var aEngLen = aEng.length; for (var i=0; i < aEngLen; i++) { xplSearch.addEngine(new searchshield[aEng[i]+'SearchEngine'](this)); } } // search the engines if we didn't find one if (!this.engine) { // STEP 2 - Identify the active search engine var engLen = this.engines.length; for (var i = 0; i < engLen; i++) { if (this.engines[i].validSearch()) { this.engine = this.engines[i]; break; } } // create a new engine instance to store this.engineList[this.searchHash.toString()] = this.engine; // init this search, if < 1 either an error or disabled //var sdkInit = 0; //try { // sdkInit = xpl_sdk.SXPL_InitSearch(this.href); //} //catch(e){} //if (sdkInit < 1) // return false; } // return immediately if there is not an active search engine if (!this.engine) return false; try { // base url to check for icons this.checkUrl = searchshield.avgCallFunc(this.doc, 'GetIconUrl', '1'); // check if using linked or local icons this.useLocalImgs = !searchshield.getUrlContents(this.checkUrl); // get the clock url this.clockUrl = searchshield.avgCallFunc(this.doc, 'GetIconUrl', '0'); } catch(e){} // STEP 3 - Get all document links and add AVG images var alltags = this.doc.getElementsByTagName("*"); // this method works for IE, FF and Chrome for (var i=0; i < alltags.length; i++) { // ignore verdicts if (alltags[i].id && (alltags[i].id.indexOf("LXPLSS_") != -1)) continue; //should the link be included? Make sure includeLink always returns an href else FALSE, var href = this.engine.includeLink(alltags[i]); if (!href) continue; var newNode = this.addLink(alltags[i], href); this.engine.addImage(newNode, this.clockUrl, false); } return (this.links ? this.links.length : false);};//////////////// SEARCH //////////////////////////////// SEARCH ENGINE ////////////////// Interface for a SearchEngine objectsearchshield.SearchEngine = function(search){ this.search = search; this.type = 'standard'; this.processFrames = false; this.new_links = true; this.onlyPrimaries = true; this.inline = { clockImage: "linkscanner://clock12.png", image: [ "linkscanner://safe12.png", "linkscanner://caution12.png", "linkscanner://warning12.png", "linkscanner://blocked12.png" ], color: { classname: ["green","yellow","orange","red"], border: ["#00A120", "#EAA500", "#F57301", "#D20003"], background: ["#C3E5CA", "#FEEFAE", "#FFD3B0", "#F5D4C1"] } }; this.filter_urls = [ "ad.doubleclick.net", "ads1.revenue.net", "aslads.ask.com", "bluestreak.com", "clickbacktrack.net", "clickbank.net", "clickboothlnk.com", "clickmanager.com", "clickserve.cc-dt.com", "dartsearch.net", "clicktraxmedia.com", "clk.atdmt.com", "dpi-digialphoto.com", "feedpoint.net", "hypertracker.com", "jdoqocy.com", "kqzyfj.com", "m1428.ic-live.com", "mediaplex.com", "mr.mdmngr.com", "n339.asp-cc.com", "offeredby.net", "offerweb.com", "pinktrax.com", "pinktrax.com", "pixel1523.everesttech.net", "qckjmp.com", "r.rd06.com", "revenuewire.net", "s0b.bluestreak.com", "s2.srtk.net", "servedby.advertising.com", "store.yahoo.com", "tf8.cpcmanager.com", "thetoptracker.com", "track.searchignite.com", "tracking.searchmarketing.com", "www.dpbolvw.net", "www.rkdms.com", "www.yellowbookleads.com" ]; this.shortened_urls = [ "3.ly", "bit.ly", "is.gd", "tr.im", "short.to", "tiny.cc", "tinyurl.com", "lnk.ms", "msplinks.com", "t.co", "qr.net" ]; this.showCleanVerdicts = true; this.showLowRiskVerdicts = true; this.showMedRiskVerdicts = true; this.VeriSignSplit = searchshield.VERISIGN_SPLIT_NOTEST;};searchshield.SearchEngine.prototype.flyoverExists = function (doc){ return !!doc.getElementById("XPLSS_Flyover");};searchshield.SearchEngine.prototype.inlineExists = function (doc){ return !!doc.getElementById("XPLSS_InlineFlyover");};searchshield.SearchEngine.prototype.validSearch = function(href) { return false; };searchshield.SearchEngine.prototype.includeLink = function(link) { return false; };searchshield.SearchEngine.prototype.insertNodes = function(node, doc){ var element = node.element; var parentNode =