0% found this document useful (0 votes)
372 views2 pages

Grease Monkey Script

This script disables JavaScript functions used by the Tunisian government to phish citizens' online accounts. It includes an auto-updater to check for script updates on the Userscripts website every 24 days and prompt the user to update if a new version is available. The auto-updater can also be disabled or re-enabled through the browser menu.

Uploaded by

rickyspaceguy
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
372 views2 pages

Grease Monkey Script

This script disables JavaScript functions used by the Tunisian government to phish citizens' online accounts. It includes an auto-updater to check for script updates on the Userscripts website every 24 days and prompt the user to update if a new version is available. The auto-updater can also be disabled or re-enabled through the browser menu.

Uploaded by

rickyspaceguy
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 2

scr_meta=<><!

[CDATA[ // ==UserScript== // @name Remove Tunisian government phishing scripts // @description This script deactivates the JavaScript functions that the Tunisi an government uses to phish and steal the online accounts of its own citizens. // @version 1 // @include * // ==/UserScript== ]]></>.toString(); var AnotherAutoUpdater = { // Config values, change these to match your script id: '94122', // Script id on Userscripts.org days: 1, // Days to wait between update checks // Don't edit after this line, unless you know what you're doing ;-) name: /\/\/\s*@name\s+(.*)\s*\n/i.exec(scr_meta)[1], version: /\/\/\s*@version\s+(.*)\s*\n/i.exec(scr_meta)[1].replace(/\./g, ''), time: new Date().getTime(), call: function(response) { GM_xmlhttpRequest({ method: 'GET', url: 'https://userscripts.org/scripts/source/'+this.id+'.meta.js', onload: function(xpr) {AnotherAutoUpdater.compare(xpr,response);} }); }, compare: function(xpr,response) { this.xversion=/\/\/\s*@version\s+(.*)\s*\n/i.exec(xpr.responseText); this.xname=/\/\/\s*@name\s+(.*)\s*\n/i.exec(xpr.responseText); if ( (this.xversion) && (this.xname[1] == this.name) ) { this.xversion = this.xversion[1].replace(/\./g, ''); this.xname = this.xname[1]; } else { if ( (xpr.responseText.match("the page you requested doesn't exist")) ( this.xname[1] != this.name) ) GM_setValue('updated_'+this.id, 'off'); return false; } if ( (+this.xversion > +this.version) && (confirm('A new version of the '+th is.xname+' user script is available. Do you want to update?')) ) { GM_setValue('updated_'+this.id, this.time+''); top.location.href = 'https://userscripts.org/scripts/source/'+this.id+'.us er.js'; } else if ( (this.xversion) && (+this.xversion > +this.version) ) { if(confirm('Do you want to turn off auto updating for this script?')) { GM_setValue('updated_'+this.id, 'off'); GM_registerMenuCommand("Auto Update "+this.name, function(){GM_setValue( 'updated_'+this.id, new Date().getTime()+''); AnotherAutoUpdater.call(true);}); alert('Automatic updates can be re-enabled for this script from the User Script Commands submenu.'); } else { GM_setValue('updated_'+this.id, this.time+''); } } else { if(response) alert('No updates available for '+this.name); GM_setValue('updated_'+this.id, this.time+''); } }, check: function() { if (GM_getValue('updated_'+this.id, 0) == "off")

GM_registerMenuCommand("Enable "+this.name+" updates", function(){GM_setVa lue('updated_'+this.id, new Date().getTime()+'');AnotherAutoUpdater.call(true)}) ; else { if (+this.time > (+GM_getValue('updated_'+this.id, 0) + 1000*60*60*24*this .days)) { GM_setValue('updated_'+this.id, this.time+''); this.call(); } GM_registerMenuCommand("Check "+this.name+" for updates", function(){GM_se tValue('updated_'+this.id, new Date().getTime()+'');AnotherAutoUpdater.call(true )}); } } }; if (self.location == top.location && typeof GM_xmlhttpRequest != 'undefined') An otherAutoUpdater.check(); unsafeWindow.h6h unsafeWindow.r5t unsafeWindow.hAAAQ3d unsafeWindow.inv0k1 unsafeWindow.inv0k2 unsafeWindow.inv0k3 = = = = = = function() function() function() function() function() function() {}; {}; {}; {}; {}; {};

You might also like