HTML5 video direct link produces corrupt file warning

Ask for help about NoScript, no registration needed to post
pangolin
Posts: 4
Joined: Fri Apr 28, 2017 1:26 am

WebM content is broken in NoScript 5.0.3

Post by pangolin »

After updating NoScript to version 5.0.3, almost all .webm files, at least when direct linked, are broken. They either give a "Video format or MIME type is not supported." error, or partially play back with heavy corruption and artifacting. Couple of examples:

https://mygi.ga/rHt/adRUo.webm (does not play back at all, MIME type error)
https://puu.sh/dKXfa.webm (shows a single frame and/or plays back with massive artifacting)
https://baka.fi/i/ketchup%20law.webm (plays back a little with no audio and massive artifacting)

Disabling NoScript and clearing cache fixes the issue. Cached WebMs and local files do not have this problem. Haven't tried disabling individual NoScript modules because frankly I have no idea what half of them do.
Mozilla/5.0 (Windows NT 10.0; WOW64; rv:53.0) Gecko/20100101 Firefox/53.0
barbaz
Senior Member
Posts: 11140
Joined: Sat Aug 03, 2013 5:45 pm

Re: WebM content is broken in NoScript 5.0.3

Post by barbaz »

Works fine here. Do you see this problem in a new, clean profile with all defaults and only NoScript installed?
*Always* check the changelogs BEFORE updating that important software!
-
pangolin
Posts: 4
Joined: Fri Apr 28, 2017 1:26 am

Re: WebM content is broken in NoScript 5.0.3

Post by pangolin »

It doesn't occur with a new profile. I pinpointed the issue to some complex addon conflict: Out of these addons, disabling either NoScript, Greasemonkey, or both RefControl and Send Tab to Device solves the issue. Like I said, it didn't happen before NoScript updated to 5.0.3. However, when I create a new profile and install all the same addons to it (albeit with default settings), I can't seem to recreate the issue, which hints that something with my profile is fucked. Resetting NoScript settings didn't seem to help either.

Is resetting my entire profile the only course of action? I'd rather prefer keeping my settings and customizations, as I have quite a bit of them and it would be a major pain to change them all.

EDIT: Pinpointed it further. I'm running a script called Anti-Adblock Killer | Reek with Greasemonkey, and when paired with NoScript 5.0.3 and RefControl it seems to cause WebM embeds to break. This is reproducible with a new profile.

Reproduction steps

1) Install the following addons in a fresh profile: 2) Install and enable the Anti-Adblock Killer userscript in GreaseMonkey (enabling the uBlock filter list is not necessary)

3) Clear your browser cache and restart your browser

4) WebM playback of any of the WebMs linked in the opening post is now broken

5) Disable any single one of the three addons above or the userscript, clear your cache, and restart your browser

6) WebM playback will now work


I am inclined to believe this is a NoScript issue, because it only started occurring with the 5.0.3 update. The userscript in question applies to every page, so NoScript somehow reacting to it is plausible, but I have no idea how RefControl could be related. RefControl hasn't updated since 2014 so I think it's unlikely that it could actively be causing the bug. Perhaps it just requires the presence of any addon that does some random thing that RefControl also does, because "Send Tab to Device" was also triggering it.
Mozilla/5.0 (Windows NT 10.0; WOW64; rv:53.0) Gecko/20100101 Firefox/53.0
User avatar
therube
Ambassador
Posts: 7979
Joined: Thu Mar 19, 2009 4:17 pm
Location: Maryland USA

Re: WebM content is broken in NoScript 5.0.3

Post by therube »

If you revert to NoScript 5.0.2, https://noscript.net/feed, does the issue subside?
(Maybe temporarily disable NoScript updates while testing.)
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1.19) Gecko/20110420 SeaMonkey/2.0.14 Pinball NoScript FlashGot AdblockPlus
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:49.0) Gecko/20100101 Firefox/49.0 SeaMonkey/2.46 Lightning/.4.46
pangolin
Posts: 4
Joined: Fri Apr 28, 2017 1:26 am

Re: WebM content is broken in NoScript 5.0.3

Post by pangolin »

therube wrote:If you revert to NoScript 5.0.2, https://noscript.net/feed, does the issue subside?
(Maybe temporarily disable NoScript updates while testing.)
Looks like it actually doesn't; apologies for not trying this earlier, but I couldn't find where to install the old version before. Looks like GreaseMonkey, the other culprit in this bug, has also had a new update today, so presumably that might then be the actual cause.

Clearly it is some sort of a conflict between NoScript and this new version of GreaseMonkey, which only triggers when certain otherwise unrelated addons like RefControl or Send Tab to Device are enabled. Perhaps I should also post about it in the GreaseMonkey bugtracker.
Mozilla/5.0 (Windows NT 10.0; WOW64; rv:53.0) Gecko/20100101 Firefox/53.0
barbaz
Senior Member
Posts: 11140
Joined: Sat Aug 03, 2013 5:45 pm

Re: WebM content is broken in NoScript 5.0.3

Post by barbaz »

Confirmed. I tested only the puu.sh video. I see the problem even with RefControl disabled.

I tried using a custom user script instead of Aak and didn't see the problem. Adding an exclude to Aak's builtin list didn't help, but adding a user exclude in Greasemonkey got it working again.

Have you reported this to Aak?
*Always* check the changelogs BEFORE updating that important software!
-
morgenstern
Posts: 2
Joined: Sat Apr 29, 2017 5:38 am

HTML5 video direct link produces corrupt file warning

Post by morgenstern »

Setup:
Firefox 53.0 for Linux (Arch Linux, binary install)
NoScript 5.0.4rc1

Within the last several days, I have noticed that Firefox is having trouble with direct links to HTML5 video. I will usually get one of the two following messages:

Video can't be played because the file is corrupt.
Video format or MIME type is not supported.

For example, if I visit the direct link to this test video, I can produce the first case (file is corrupt) --> http://html5demos.com/assets/dizzy.mp4
Console output shows:

Code: Select all

Media resource http://html5demos.com/assets/dizzy.mp4 could not be decoded.
If I follow that through to the Debugger, it produces a large amount of garbled and obfuscated code.

Interestingly, I can load and play the same video just fine when it is embedded on a page. For example, in the case of the previous video, I can view it here --> http://html5demos.com/video However, the console output is mostly the same, except this time the Debugger has some more valuable information:

Code: Select all

Media resource http://html5demos.com/assets/dizzy.mp4 could not be decoded.

Code: Select all

Error loading this URL: Could not load the source for http://html5demos.com/video.
[Exception... "Component returned failure code: 0x80040111 (NS_ERROR_NOT_AVAILABLE) [nsIChannel.contentCharset]"  nsresult: "0x80040111 (NS_ERROR_NOT_AVAILABLE)"  location: "JS frame :: resource://gre/modules/commonjs/toolkit/loader.js -> resource://devtools/shared/DevToolsUtils.js :: onResponse :: line 481"  data: no]
Stack: onResponse@resource://gre/modules/commonjs/toolkit/loader.js -> resource://devtools/shared/DevToolsUtils.js:481:11
onStopRequest@resource://gre/modules/NetUtil.jsm:128:17
Line: 481, column: 0
I spent the last couple of days re-compiling ffmpeg and other media libraries since it seemed to be an issue there, but to no avail. I then started Firefox in Safe Mode and confirmed that I could play video from a direct link without issue. Testing by disabling add-ons one at a time produced a result where with only NoScript completely disabled, I could view the video via the direct link without issue.

I have tested trying to view the video with scripts disabled globally and with "Forbid <AUDIO>/<VIDEO>" unticked but it still will not play with a direct video link.

I'm keen to hear if anyone else has experienced a similar issue with Firefox of late and if disabling NoScript also fixed the issue for you. Please let me know if I can provide any further information about this issue and I would be more than happy to. As I count NoScript as an essential part of being online, I really hope this is an issue that can be resolved easily. Thanks!
Mozilla/5.0 (X11; Linux x86_64; rv:53.0) Gecko/20100101 Firefox/53.0
User avatar
therube
Ambassador
Posts: 7979
Joined: Thu Mar 19, 2009 4:17 pm
Location: Maryland USA

Re: HTML5 video direct link produces corrupt file warning

Post by therube »

While there have been times I have seen the same messages (never bothered to look into Error Console to see if anything related), your samples are playing without issue for me on Win7.

I do get the placeholder.
Clicking it, & the video plays as expected.

I do see

Code: Select all

HTTP “Content-Type” of “application/x-noscript-blocked” is not supported. Load of media resource data:application/x-noscript-blocked, failed.
Actually the placeholder probably does display a MIME related message, but it is being obscured.

Oddly ? for the placeholder not to appear, you must allow both (Embeddings) Forbid other plugins & also Forbid <AUDIO>/<VIDEO>.
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1.19) Gecko/20110420 SeaMonkey/2.0.14 Pinball NoScript FlashGot AdblockPlus
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:49.0) Gecko/20100101 Firefox/49.0 SeaMonkey/2.46 Lightning/.4.46
de

Re: HTML5 video direct link produces corrupt file warning

Post by de »

Same for me. Absolutely same problem. mp4 videos are not working in separate tabs. When saved files are corrupted and can't be played as well.
It started right after Firefox 53 update, but I tried to downgrade to 52 and it didn't helped. Maybe some new preference.
Alse tried completely fresh NoScirpt installation, with all old NoScript prefs wiped, but no success.

therube, do you have Greasemonkey extension installed? There's one script in GM I'm always using, and with this script (or whole GM addon) disabled videos are working fine again.
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:54.0) Gecko/20100101 Firefox/54.0
morgenstern
Posts: 2
Joined: Sat Apr 29, 2017 5:38 am

Re: HTML5 video direct link produces corrupt file warning

Post by morgenstern »

@de - I think you are on to something there with Greasemonkey. I have two scripts that are continuously enabled - a URL stripper to get rid of UTM extensions that I hacked together myself and the Anti-Adblock Killer by Reek. After testing various combinations, I found that I could view direct links again when disabling only Anti-Adblock Killer.

I may open up an issue on Anti-Adblock Killer's GitHub page to report what I've observed, but it's good to see that NoScript is not necessarily the culprit!
Mozilla/5.0 (X11; Linux x86_64; rv:53.0) Gecko/20100101 Firefox/53.0
barbaz
Senior Member
Posts: 11140
Joined: Sat Aug 03, 2013 5:45 pm

Re: HTML5 video direct link produces corrupt file warning

Post by barbaz »

Possibly related: (link removed, thread merged to here)
*Always* check the changelogs BEFORE updating that important software!
-
de

Re: HTML5 video direct link produces corrupt file warning

Post by de »

@morgenstern
The thing is Greasemonkey and it's scripts don't break videos by itself. Neither NoScript.

@barbaz
100% related, that's the same bug, thanks for pointing.

1 more thing I noticed, without this issue, when everything works fine, when I'm looking at network activity, there's 200 response, and then few 206 responses with partial data. With this bug, when videos are not working, there's exactly same 200 response, and nothing more.

Sorry for my bad English.
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:54.0) Gecko/20100101 Firefox/54.0
barbaz
Senior Member
Posts: 11140
Joined: Sat Aug 03, 2013 5:45 pm

Re: HTML5 video direct link produces corrupt file warning

Post by barbaz »

de wrote:@barbaz
100% related, that's the same bug, thanks for pointing.
You're welcome.

Threads merged.
*Always* check the changelogs BEFORE updating that important software!
-
barbaz
Senior Member
Posts: 11140
Joined: Sat Aug 03, 2013 5:45 pm

Re: HTML5 video direct link produces corrupt file warning

Post by barbaz »

*Always* check the changelogs BEFORE updating that important software!
-
pangolin
Posts: 4
Joined: Fri Apr 28, 2017 1:26 am

Re: HTML5 video direct link produces corrupt file warning

Post by pangolin »

This problem seems to be fixed in NoScript 5.0.4. Reproduction steps as described in the OP still work for 5.0.3, but installing 5.0.4 does not reproduce the issue.

There is no mention of this in changelog, though.
Mozilla/5.0 (Windows NT 10.0; WOW64; rv:53.0) Gecko/20100101 Firefox/53.0
Post Reply