Browse Source

Upload files to 'addons/code/bcma'

candy 6 months ago
parent
commit
37584bf659
  1. 6
      addons/code/bcma/cf.js
  2. 2
      addons/code/bcma/cg.html
  3. 3
      addons/code/bcma/cg.js
  4. 2
      addons/code/bcma/manifest.json

6
addons/code/bcma/cf.js

@ -1198,7 +1198,7 @@ browser.webRequest.onHeadersReceived.addListener(function (wr) {
if (my_action == 4) {
tell_me(my_nfo_alu, trans['eo']['cflrmi'], trans['eo']['redir'] + wr_hostname);
return {
redirectUrl: my_customurl.replace('%%URL%%', wr.url)
redirectUrl: my_customurl.replace('%%URL%%', wr.url).replace('%%ERL%%', encodeURIComponent(wr.url))
};
}
}
@ -1259,7 +1259,7 @@ browser.webRequest.onBeforeRequest.addListener(function (wr) {
if (my_action == 4) {
tell_me(my_nfo_alu, trans['eo']['cflrmi'], trans['eo']['redir'] + wr_hostname);
return {
redirectUrl: my_customurl.replace('%%URL%%', wr.url)
redirectUrl: my_customurl.replace('%%URL%%', wr.url).replace('%%ERL%%', encodeURIComponent(wr.url))
};
}
}
@ -1341,7 +1341,7 @@ browser.runtime.onMessage.addListener(function (a, b, c) {
});
}
if (a[0] == 'au') {
my_customurl = (/^http(|s):\/\/([a-z0-9.-]{4,})\/(.*)%%URL%%(.*)$/.test(a[1])) ? a[1] : def_customurl;
my_customurl = (/^http(|s):\/\/([a-z0-9.-]{4,})\/(.*)%%(U|E)RL%%/.test(a[1])) ? a[1] : def_customurl;
browser.storage.local.set({
'customurl': my_customurl
});

2
addons/code/bcma/cg.html

@ -15,6 +15,8 @@
&nbsp;<br>&nbsp;<br>
<b>&#128391; <span transk="uralturl"></span></b><br>
<span transk="ururepl"></span><br>
<span>%%URL%% <i>https://mia.ekzemplo.net/</i><br>
%%ERL%% <i>https%3A%2F%2Fmia.ekzemplo.net%2F</i><br></span>
<input type="text" id="vau" spellcheck="false" value="" placeholder="ekz. https://mia.ekzemplo.net/proxy?url=%%URL%%">
<button type="button" id="aus"> <span transk="apply"></span> </button>
&nbsp;<br>&nbsp;<br>

3
addons/code/bcma/cg.js

@ -54,6 +54,9 @@ document.addEventListener('DOMContentLoaded', () => {
}
});
document.getElementById('aus').addEventListener('click', function () {
if (!/^http(|s):\/\/([a-z0-9.-]{4,})\/(.*)%%(U|E)RL%%/.test(document.getElementById('vau').value)) {
document.getElementById('vau').value = '';
}
browser.runtime.sendMessage(['au', document.getElementById('vau').value]);
});
document.getElementById('exp').addEventListener('click', () => {

2
addons/code/bcma/manifest.json

@ -2,7 +2,7 @@
"manifest_version": 2,
"name": "Bloku Cloudflaron MITM-Atakon",
"description": "Submetiĝu al tutmonda gvatado aŭ rezistu",
"version": "1.0.5.6",
"version": "1.0.6",
"homepage_url": "http://crimeflare.eu.org/",
"author": "Crimeflare #Addon",
"permissions": [

Loading…
Cancel
Save