0
0
mirror of https://codeberg.org/crimeflare/cloudflare-tor synced 2024-12-23 16:10:35 +00:00

Upload files to 'addons/urejectFX'

This commit is contained in:
letssync 2020-07-31 01:17:43 +02:00
parent f892548d62
commit 495fdbe73e
4 changed files with 110 additions and 0 deletions

34
addons/urejectFX/bg.js Normal file
View File

@ -0,0 +1,34 @@
let history = {};
browser.webRequest.onResponseStarted.addListener(i => {
if ([403, 406, 410, 429, 451, 462].includes(i.statusCode)) {
let iFQDN = (new URL(i.url)).hostname;
if (['searxes.eu.org', 'ansero.eu.org', 'ss.wodferndripvpe6ib4uz4rtngrnzichnirgn7t5x64gxcyroopbhsuqd.onion', 'searxes.wodferndripvpe6ib4uz4rtngrnzichnirgn7t5x64gxcyroopbhsuqd.onion', 'ansero.wodferndripvpe6ib4uz4rtngrnzichnirgn7t5x64gxcyroopbhsuqd.onion'].includes(iFQDN)) {
return;
}
let iServer = '?';
i.responseHeaders.forEach(x => {
if (x.name == 'Server' || x.name == 'server') {
iServer = x.value;
}
});
history[iFQDN] = [i.url, iServer, i.statusCode, (new Date()).toUTCString()];
}
return;
}, {
urls: ['http://*/*', 'https://*/*'],
types: ['main_frame']
}, ['responseHeaders']);
browser.runtime.onMessage.addListener((request, sender, sendResponse) => {
if (request && sender) {
if (request == 'get') {
sendResponse(history);
}
if (request == 'clear') {
history = {};
sendResponse(true);
}
}
});
browser.browserAction.onClicked.addListener(() => {
browser.runtime.openOptionsPage();
});

20
addons/urejectFX/log.html Normal file
View File

@ -0,0 +1,20 @@
<html>
<head>
<meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate">
<meta http-equiv="content-type" content="text/html;charset=UTF-8">
<title>&#128221;</title>
</head>
<body style="display:none">
<br><br>
<b>Detaloj</b><br>
<table style="width:90%" border=1>
<tbody></tbody>
</table>
<br>
<input id="clear" type="button" value=" Malplenigu liston "><br>
<br><br>
<b>Nur FQDN</b><br>
<textarea id="export" cols=60 rows=20 readonly></textarea>
<script src="log.js"></script>
</body>
</html>

18
addons/urejectFX/log.js Normal file
View File

@ -0,0 +1,18 @@
function newrow(w) {
let tt = document.getElementsByTagName('tbody')[0];
let tr = tt.insertRow(tt.rows.length);
tr.innerHTML = w;
}
newrow('<tr><td><b>FQDN</b></td><td><b>Servilo</b></td><td><b>Stato</b></td><td><b>Kie</b></td><td><b>Kiam</b></td></tr>');
browser.runtime.sendMessage('get').then(g => {
for (let k in g) {
newrow('<tr><td>' + k + '</td><td>' + g[k][1] + '</td><td>' + g[k][2] + '</td><td><a href="' + g[k][0] + '" rel="noreferrer noopener" target="_blank"> &#128279; </a></td><td>' + g[k][3] + '</td></tr>');
document.getElementById('export').innerHTML += k + "\n";
}
});
document.body.style.display = 'block';
document.getElementById('clear').addEventListener('click', () => {
browser.runtime.sendMessage('clear').then(() => {
location.reload(true);
});
});

View File

@ -0,0 +1,38 @@
{
"manifest_version": 2,
"name": "Kiu retejo malakceptis min?",
"description": "Via retejo malakceptis min, sed mi scias ke mi fartos bone.",
"version": "1.0.2",
"homepage_url": "https://ss.wodferndripvpe6ib4uz4rtngrnzichnirgn7t5x64gxcyroopbhsuqd.onion/",
"author": "Ss",
"permissions": [
"webRequest",
"<all_urls>"
],
"icons": {
"72": "icons/72.png"
},
"background": {
"scripts": [
"bg.js"
]
},
"options_ui": {
"browser_style": false,
"open_in_tab": true,
"page": "log.html"
},
"browser_action": {
"browser_style": true,
"default_icon": {
"72": "icons/72.png"
}
},
"applications": {
"gecko": {
"id": "urejectme@searxes.eu.org",
"strict_min_version": "60.0",
"update_url": "https://api.wodferndripvpe6ib4uz4rtngrnzichnirgn7t5x64gxcyroopbhsuqd.onion/_/addon.php?for=ureject"
}
}
}