User:Herbythyme/monobook.js

// User:Jsimlo/shortcuts.js document.write(' '); function shortcutsInit { shortcutsAddLink ('Salt', 'WB:SALT'); shortcutsAddLink ('Checkuser', 'Special:Checkuser'); shortcutsAddLink ('Ipblocklist', 'Special:Ipblocklist'); shortcutsAddLink ('Cleanup', 'WB:WM'); shortcutsAddLink ('Templates', 'Wikibooks:Template messages'); shortcutsAddLink ('Unwatched', 'Special:Unwatchedpages'); shortcutsAddLink ('Watching', 'User:Herbythyme/eyeball'); shortcutsAddLink ('Prefix index', 'special:Prefixindex'); shortcutsAddLink ('Rights', 'Special:Userrights'); shortcutsAddLink ('Monobook', 'User:Herbythyme/monobook.js'); }

// User:Lupin/popups.js

mw.loader.load(            'https://en.wikipedia.org/w/index.php?title=User:Lupin/popups.js'             + '&action=raw&ctype=text/javascript&dontcountme=s'); popupAdminLinks=true

// User:Invitatious/unsigned2.js - unsigned comments script (enwiki) document.write(' ');

// install User:Cacycle/diff text diff code document.write(' ');

// install User:Cacycle/editor edit tool document.write(' ');

//

addOnloadHook(function{ var x; if (x=document.getElementById('wpAnonOnly')) {x.checked=false;} });

addOnloadHook(function{ var x; if (x=document.getElementById('wpCreateAccount')) {x.checked=true;} });

addOnloadHook(function{ var x; if (x=document.getElementById('wpEnableAutoblock')) {x.checked=false;} });

//

/////////////////////////////CLIENT SIDE CHECKUSER IP info retriever///////////////////////////// //security override HTTP request //ALSO, reduce IE security settings //For FF/NS, go enable, see "http://esw.w3.org/topic/SparqlCalendarDemoUsage#FAQ" //Basically, enable "signed.applets.codebase_principal_support" in about:config

$(WHOIScheck) function WHOIScheck { if (location.href.indexOf('Special:CheckUser') ==-1) return; var body=document.getElementById('bodyContent'); if (!body) return; addTab("javascript:CU_comprehensive", "WHOIS all IPs", "ca-checkall", "Check all IPs", ""); }

// function makeCURequestXML_DNS(type, url, parameters) {  if(window.XMLHttpRequest) { try {netscape.security.PrivilegeManager.enablePrivilege("UniversalBrowserRead"); } catch (e) {alert("Permission UniversalBrowserRead denied. Please enable 'signed.applets.codebase_principle_support' through 'about:config' in your browser."); } http_request = false; http_request = new XMLHttpRequest; if (!http_request) {alert('Cannot create XMLHTTP instance'); return false;} http_request.onreadystatechange = CU_comprehensive_check_WHOIS; http_request.open(type, url, true); http_request.send(parameters); } else if (window.ActiveXObject) {   try {http_request = new ActiveXObject("Msxml2.XMLHTTP");} catch (e) {     try {http_request = new ActiveXObject("Microsoft.XMLHTTP");} catch (e){} } if (!http_request) {showError(ERROR_XML);} http_request.onreadystatechange = CU_comprehensive_check_WHOIS; http_request.open(type, url, true); http_request.send(parameters); } } //

// function makeCURequestXML_WHOIS(type, url, parameters) {  if(window.XMLHttpRequest) { try {netscape.security.PrivilegeManager.enablePrivilege("UniversalBrowserRead"); } catch (e) {alert("Permission UniversalBrowserRead denied. Please enable 'signed.applets.codebase_principle_support' through 'about:config' in your browser."); } http_request = false; http_request = new XMLHttpRequest; if (!http_request) {alert('Cannot create XMLHTTP instance'); return false;} http_request.onreadystatechange = CU_comprehensive_check_parse; http_request.open(type, url, true); http_request.send(parameters); } else if (window.ActiveXObject) {   try {http_request = new ActiveXObject("Msxml2.XMLHTTP");} catch (e) {     try {http_request = new ActiveXObject("Microsoft.XMLHTTP");} catch (e){} } if (!http_request) {showError(ERROR_XML);} http_request.onreadystatechange = CU_comprehensive_check_parse; http_request.open(type, url, true); http_request.send(parameters); } } //

//IP/WHOIS for CU principle results// CU_li_index = 0; function CU_comprehensive { var results = document.getElementById('bodyContent').getElementsByTagName('ul')[0]; if (!results) {alert('There are no elements in this list.'); return;} if (!results.getElementsByTagName('li')[0]) {alert('There are no elements in this list.'); return;} var ls = results.getElementsByTagName('li'); if (!ls[0].getElementsByTagName('a')[0]) {alert('There are no expected elements in this list.'); return;} if (document.getElementById('contentSub').innerHTML.search(/Checking all IPs, please wait...|All data retrieved:/) != -1) {alert('Results already shown.'); return;} document.getElementById('contentSub').innerHTML += ' Checking all IPs, please wait...'; CU_comprehensive_check; }

function CU_comprehensive_check { var list = document.getElementById('bodyContent').getElementsByTagName('ul')[0]; if (list.getElementsByTagName('li')[CU_li_index] && list.getElementsByTagName('li')[CU_li_index].getElementsByTagName('a')[0]) { var link = list.getElementsByTagName('li')[CU_li_index].getElementsByTagName('a')[0].href; var name = list.getElementsByTagName('li')[CU_li_index].getElementsByTagName('a')[0].innerHTML; if (name.search(/^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/) !=-1) {   var URL = 'http://www.dnsstuff.com/tools/ipall.ch?domain=' + name; CU_comprehensive_check_DNS(URL); } else {CU_li_index+=1; CU_comprehensive_check;} } else if (list.getElementsByTagName('li')[CU_li_index]) {CU_li_index+=1; CU_comprehensive_check;} else { document.getElementById('contentSub').innerHTML = ' All data retrieved: DNS/WHOIS scan completed. '; } }

function CU_comprehensive_check_DNS(URL) { var list = document.getElementById('bodyContent').getElementsByTagName('ul')[0]; var name = list.getElementsByTagName('li')[CU_li_index].getElementsByTagName('a')[0].innerHTML; document.getElementById('contentSub').innerHTML = ' Retrieving DNS XML page data for ' + name + '... '; makeCURequestXML_DNS("GET",URL,null); }

function CU_comprehensive_check_WHOIS { if (http_request.readyState != 4) return; xml_DNS_user_CU = http_request.responseText; var list = document.getElementById('bodyContent').getElementsByTagName('ul')[0]; var name = list.getElementsByTagName('li')[CU_li_index].getElementsByTagName('a')[0].innerHTML; var URL = 'http://www.dnsstuff.com/tools/whois.ch?ip=' + name; document.getElementById('contentSub').innerHTML = ' Retrieving WHOIS XML page data for ' + name + '... '; makeCURequestXML_WHOIS("GET",URL,null); }

function CU_comprehensive_check_parse { if (http_request.readyState != 4) return; xml_WHOIS_user_CU = http_request.responseText; var list = document.getElementById('bodyContent').getElementsByTagName('ul')[0]; var name = list.getElementsByTagName('li')[CU_li_index].getElementsByTagName('a')[0].innerHTML; document.getElementById('contentSub').innerHTML = ' Parsing WHOIS XML page data for ' + name + '... '; //WHOIS //xml_WHOIS_user_CU = http_request.responseXML; if (xml_WHOIS_user_CU.indexOf(' Whois Record ') !=-1) {xml_WHOIS_user_CU = http_request.responseText.split(' Whois Record ')[1];} else if (xml_WHOIS_user_CU.indexOf('Whois Record') !=-1) {xml_WHOIS_user_CU = http_request.responseText.split('Whois Record')[1];} if (xml_WHOIS_user_CU.indexOf('') != -1) {xml_WHOIS_user_CU = xml_WHOIS_user_CU.split('')[1].split(' ')[0];} //parse WHOIS results var OrgName=''; var Address=''; var City=''; var StateProv=''; var Country=''; var CIDR=''; if (xml_WHOIS_user_CU.indexOf('OrgName:') !=-1) {OrgName = xml_WHOIS_user_CU.split('OrgName:')[1].split('\n')[0].split('\r')[0].split(']')[0] + ', ';} if (xml_WHOIS_user_CU.indexOf('Address:') !=-1) {Address = xml_WHOIS_user_CU.split('Address:')[1].split('\n')[0].split('\r')[0].split(']')[0] + ', ';} if (xml_WHOIS_user_CU.indexOf('City:') !=-1) {City = ' ' + xml_WHOIS_user_CU.split('City:')[1].split('\n')[0].split('\r')[0].split(']')[0] + ' ' + ', ';} if (xml_WHOIS_user_CU.indexOf('StateProv:') !=-1) {StateProv = xml_WHOIS_user_CU.split('StateProv:')[1].split('\n')[0].split('\r')[0].split(']')[0] + ', ';} if (xml_WHOIS_user_CU.indexOf('OrgName:') !=-1) {Country = xml_WHOIS_user_CU.split('Country:')[1].split('\n')[0].split('\r')[0].split(']')[0] + ', ';} if (xml_WHOIS_user_CU.indexOf('CIDR:') !=-1) {CIDR = xml_WHOIS_user_CU.split('CIDR:')[1].split('\n')[0].split('\r')[0].split(']')[0];} if (xml_WHOIS_user_CU.search(/(OrgName|Address|City|StateProv|Country):/) ==-1 && xml_WHOIS_user_CU.indexOf(' ') != -1) {OrgName = xml_WHOIS_user_CU.split(' ')[1].split(' ')[0] + ', ';} var output_IP_info = ' ' + OrgName + ' ' + Address + City + ' ' + StateProv + ' ' + ' + Country + '; if (CIDR !='') output_IP_info += ' CIDR: ' + CIDR; //parse DNS items document.getElementById('contentSub').innerHTML = ' Parsing DNS XML page data for ' + name + '... '; if (xml_DNS_user_CU.indexOf('') != -1) {xml_DNS_user_CU = xml_DNS_user_CU.split('')[1].split('')[0];} var rev_DNS_info = ''; if (xml_DNS_user_CU.indexOf('Reverse DNS:') !=-1) {rev_DNS_info = ' ' + xml_DNS_user_CU.split('Reverse DNS:')[1].split('\n')[0].split('\r')[0] + ' ';} output_IP_info += ' DNS :' + rev_DNS_info; output_IP_info = output_IP_info.replace(/Internet Assigned Numbers Authority/,'IANA'); list.getElementsByTagName('li')[CU_li_index].innerHTML += ' ' + output_IP_info + ' '; // CU_li_index += 1; CU_comprehensive_check; } //////////////