1
0
mirror of https://codeberg.org/nobody/LocalCDN.git synced 2025-06-05 21:49:31 +02:00

Block bad resources (#703)

This commit is contained in:
nobody
2021-09-29 06:50:53 +02:00
parent f4daff688f
commit e0f8719391
4 changed files with 31 additions and 0 deletions

View File

@@ -391,6 +391,20 @@ const MathJaxFiles = {
'jax/output/HTML-CSS/jax.js': true,
};
/**
* To block bad resources, e.g. fingerprint
*
* Necessary if the user has selected the option "Block requests for missing
* resources Advanced" option is not enabled.
*
* https://codeberg.org/nobody/LocalCDN/issues/703
*/
const BadResources = {
'cdn.jsdelivr.net/npm/@fingerprintjs/': true,
'cdnjs.cloudflare.com/ajax/libs/fingerprintjs/': true,
'cdnjs.cloudflare.com/ajax/libs/fingerprintjs2/': true,
'cdnjs.cloudflare.com/ajax/libs/ClientJS/': true,
};
// Supported charsets for TextDecoder()
// https://developer.mozilla.org/en-US/docs/Web/API/TextDecoder/TextDecoder