Page 1 of 1

Local rust docs not loading when Noscript active

Posted: Mon Feb 16, 2026 1:50 am
by phyzome
I'm using NoScript 13.5.12 on Firefox 140.7.0esr and I'm unable to run scripts on *some* local files. So far I've only observed it in Rust (programming language) docs -- I generate the docs locally, and open them in the browser, but the search and settings features don't work. If I disable Noscript, they work. (file: is marked trusted, of course.) This was working a couple months ago, but I hadn't used docs since then so I'm not sure when things broke.

These is what I see in the console:

Code: Select all

Freezing file:///home/phyzome/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/share/doc/rust/html/std/index.html <html lang="en"></html>
DocumentFreezer.js:142:15

Uncaught ReferenceError: getVar is not defined
    <anonymous> file:///home/phyzome/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/share/doc/rust/html/static.files/main-a410ff4d.js:1
main-a410ff4d.js:1:917

Unfreezing file:///home/phyzome/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/share/doc/rust/html/std/index.html off-document 
<html lang="en">...
DocumentFreezer.js:167:17

Uncaught SyntaxError: redeclaration of const MAIN_ID
    <anonymous> file:///home/phyzome/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/share/doc/rust/html/static.files/main-a410ff4d.js:1
main-a410ff4d.js:1:1
What's *really* weird is that when I created a new Firefox profile and loaded the docs, it worked fine, but when I then installed Noscript in that new profile and toggle file: permissions on and off, scripts in the file only worked when file: was disallowed. However, I couldn't reproduce that in yet another blank profile. :shock:

So I feel like something is off with how file: docs are being handled?

Re: Local rust docs not loading when Noscript active

Posted: Mon Feb 16, 2026 1:58 am
by phyzome
(Still trying to figure out how to provide a reasonable copy of these files so someone else can reproduce this -- but the docs weigh in at 725 MB across 50,000 files... I'll see if I can get something smaller!

But yes, this involves local files loading other local files. No errors in the network tab, though.)

Re: Local rust docs not loading when Noscript active

Posted: Mon Feb 16, 2026 2:07 am
by phyzome
OK, managed to make a relatively small repro case: https://lab.brainonfire.net/testcase/no ... 260215.zip (1.6 MB)

Re: Local rust docs not loading when Noscript active

Posted: Mon Feb 16, 2026 2:30 pm
by barbaz
Locally-installed Rust documentation works for me (but I'm on Firefox 147.0.4). Try setting file: to CUSTOM and enable all capabilities shown...
phyzome wrote: Mon Feb 16, 2026 1:58 am this involves local files loading other local files
... especially, make sure the local-file-specific "x-load" capability is enabled

Re: Local rust docs not loading when Noscript active

Posted: Mon Feb 16, 2026 3:16 pm
by phyzome
When I click custom, all the capabilities are already checked. But I don't see x-load as an option.

Image

Re: Local rust docs not loading when Noscript active

Posted: Mon Feb 16, 2026 3:33 pm
by barbaz
Do you see it when editing CUSTOM permissions for file: in NoScript Options > Per-site Permissions?

Re: Local rust docs not loading when Noscript active

Posted: Mon Feb 16, 2026 3:47 pm
by phyzome
Yes! I've now enabled it.

When I reopen the page and open CUSTOM for file:, I now see x-load for file:. It's still not working, though.

(I don't see x-load in the list when I select the full URL in the dropdown, so I also made sure to click Reset when that was selected, and to ensure there wasn't a per-site permission saved for the full URL.)

Re: Local rust docs not loading when Noscript active

Posted: Mon Feb 16, 2026 6:41 pm
by barbaz
With Firefox 140.7.0esr in a VM I reproduced this twice when starting Firefox from terminal with the Rust documentation page as a command-line argument (i.e. Firefox was not already running, as opposed to having already opened Firefox first and then dragging in the Rust documentation file). Force-reload the Rust documentation page with Ctrl+Shift+R got it working correctly. Then I could not reproduce it again, even though Firefox was being run in a disposable sandbox that got dumped on quit, where the Rust documentation was never loaded at all in the unsandboxed Firefox profile.