} return false;};searchshield.DiggSearchEngine.prototype.includeLink = function(tag){ var outHref = false; var findStr = ""; if ((tag.parentNode) && (tag.parentNode.className.toLowerCase() == "digg-count")) { return false; } if (searchshield.DoesURLContain(tag.href, this.search.uri.host)) { if (tag.className && tag.className.indexOf('source') != -1) { findStr = "/search?q=site:"; var urlPos = tag.href.indexOf(findStr); if (urlPos != -1) { urlPos += 15; outHref = tag.href.substring(urlPos); return outHref; } } } return false;};searchshield.DiggSearchEngine.prototype.addImage = function(node, image, hidden){ // remove style that is set when alt image is applied this.addAnchorStyle = { background: "none" }; var parent = searchshield.SearchEngine.prototype.addImage; return parent.call(this, node, image, hidden);};/////////////// DIGG SEARCH ENGINE ////////////////////////////// SLASHDOT SEARCH ENGINE ///////////////searchshield.SlashdotSearchEngine = function(search){ searchshield.SearchEngine.call(this, search); this.showCleanVerdicts = false; this.new_links = false; this.type = 'inline';};searchshield.SlashdotSearchEngine.prototype = new searchshield.SearchEngine();searchshield.SlashdotSearchEngine.prototype.constructor = searchshield.SlashdotSearchEngine;searchshield.SlashdotSearchEngine.prototype.name = "slashdot";searchshield.SlashdotSearchEngine.prototype.validSearch = function(href){ var uri; if (typeof(this.search) === 'undefined' || null === this.search) uri = searchshield.parseLink(href); else uri = this.search.uri; if(!uri || !uri.host) return false; var domain= uri.host; // re stitch the uri path and query elements // to use existing logic var path = uri.path + uri.delimiter + uri.query; if (domain.indexOf("slashdot.org") != -1) { return true; } return false;};searchshield.SlashdotSearchEngine.prototype.includeLink = function(tag){ if (searchshield.DoesURLContain(tag.href, this.search.uri.host)) return false; if ( tag.href.indexOf("mailto:") != -1 ) return false; if ( tag.href.indexOf("slashdot.org") != -1 ) return false; if (tag.parentNode && (tag.parentNode.tagName == "DIV")) { if (tag.parentNode.id.indexOf("text-") != -1) { return tag.href; } } else if ( tag.parentNode && tag.parentNode.parentNode && tag.parentNode.parentNode.tagName == "DIV" ) { if ( tag.parentNode.parentNode.id.indexOf("text-") != -1 ) { return tag.href; } } return false;};searchshield.SlashdotSearchEngine.prototype.addImage = function(node, image, hidden){ var doc = this.search.doc; this.init_inline_ratings(doc); this.show_inline_ratings(doc, node, image);};/////////////// SLASHDOT SEARCH ENGINE ////////////////////////////// TWITTER SEARCH ENGINE ///////////////searchshield.TwitterSearchEngine = function(search){ searchshield.SearchEngine.call(this, search); this.showCleanVerdicts = false; this.new_links = false; this.type = 'inline';};searchshield.TwitterSearchEngine.prototype = new searchshield.SearchEngine();searchshield.TwitterSearchEngine.prototype.constructor = searchshield.TwitterSearchEngine;searchshield.TwitterSearchEngine.prototype.name = "twitter";searchshield.TwitterSearchEngine.prototype.twitter_filter_urls = ["twitpic.com", "twitterfeed.com", "twitter.peoplebrowsr.com"];searchshield.TwitterSearchEngine.prototype.validSearch = function(href){ var uri; if (typeof(this.search) === 'undefined' || null === this.search) uri = searchshield.parseLink(href); else uri = this.search.uri; if(!uri || !uri.host) return false; var domain= uri.host; if (domain.indexOf("twitter.com") != -1) { return true; } return false;};searchshield.TwitterSearchEngine.prototype.includeLink = function(tag){ if (tag.className == 'twitter-timeline-link') { // can't pass the tag's href if domain is t.co cause then new posts // will not get an immediate verdict even if it has a dangerous link if (tag.href.indexOf('/t.co/') != -1) { // the tag's inner text may be truncated and end in the // unicode suspension character (i.e., ...) and it cannot // be used. if (tag.innerText.charCodeAt(tag.innerText.length-1) == 8230) { // older posts may not always have data-expanded-url var destUrl = tag.getAttribute('data-expanded-url'); if (!!destUrl) return destUrl; var finalUrl = searchshield.avgCallFunc(document, 'GetFinalUrl', tag.href); return finalUrl; } return searchshield.checkUrl(tag.innerText); } return tag.href; } return false;};searchshield.TwitterSearchEngine.prototype.addImage = function(node, image, hidden){ var doc = this.search.doc; this.init_inline_ratings(doc); this.show_inline_ratings(doc, node, image);};/////////////// TWITTER SEARCH ENGINE ////////////////////////////// GMAIL SEARCH ENGINE ///////////////searchshield.GMailSearchEngine = function(search){ searchshield.SearchEngine.call(this, search); this.processFrames = true; this.showCleanVerdicts = false; this.type = 'inline';};searchshield.GMailSearchEngine.prototype = new searchshield.SearchEngine();searchshield.GMailSearchEngine.prototype.constructor = searchshield.GMailSearchEngine;searchshield.GMailSearchEngine.prototype.name = "gmail"; // the name by which the search engine is known (always lowercase)searchshield.GMailSearchEngine.prototype.validSearch = function(href){ var uri; if (typeof(this.search) === 'undefined' || null === this.search) uri = searchshield.parseLink(href); else uri = this.search.uri; if(!uri || !uri.host) return false; var domain = uri.host; // re stitch the uri path and query elements