Jump to content

Embedding MJPGs causes problems in firefox

Go to solution Solved by colonel_mortis,

The protocol that backs this, multipart/x-mixed-replace, seems to not work so great with the forum software. That protocol is only used for a few very esoteric applications though, and it seems to behave better with the next major version of the forum software (although I have no ETA for when we will pick that up - almost certainly not this year), so it doesn't seem worth reporting to try to get it fixed.

 

(The specific bug is that onLoad is being called multiple times, once per frame, which causes the requests to blow up)

Browser, version and OS: 

Firefox 136.0.1 Ubuntu 24.04.2 LTS, doesn't happen in Chromium 134.0.6998.35 

 

Steps to reproduce/what were you doing before it happened?

Paste link with mjpeg, example link with spaces added - https://kaffee.hnf.de /mjpg /video.mjpg

 

(Mortis note: Please don't try this, it does bad things!)

 

What happened?

Link embeds, says it couldn't embed it, nginx 429 then a bunch of cloudflare checks appear before it fails completely. In chromium it embeds properly, but when looking at a post after making it doesn't actually show the mjpg in either browser.

 

What did you expect to happen?

For it not to behave as it did and just leave the link as it is seeing as they can't even be displayed even when they can embed properly in another browser.

 

Screenshots of the issue, if applicable: 

image.png.9e45ebc4053b1c26031be242348715a3.png

Edited by colonel_mortis
Please don't try this
Link to comment
https://linustechtips.com/topic/1605545-embedding-mjpgs-causes-problems-in-firefox/
Share on other sites

Link to post
Share on other sites

14 minutes ago, whispous said:

Are you having the same issue with much more common video extensions, like mp4?

MP4 doesn't seem to embed. Everything else like jpeg, webm and youtube links work fine. That mjpg is also used as a live video feed if it bears any relevance.

Link to post
Share on other sites

On 3/16/2025 at 3:35 PM, AndrewAsd said:

Browser, version and OS: 

Firefox 136.0.1 Ubuntu 24.04.2 LTS, doesn't happen in Chromium 134.0.6998.35 

 

Steps to reproduce/what were you doing before it happened?

Paste link with mjpeg, example link with spaces added - https://kaffee.hnf.de /mjpg /video.mjpg

 

(Mortis note: Please don't try this, it does bad things!)

 

What happened?

Link embeds, says it couldn't embed it, nginx 429 then a bunch of cloudflare checks appear before it fails completely. In chromium it embeds properly, but when looking at a post after making it doesn't actually show the mjpg in either browser.

 

What did you expect to happen?

For it not to behave as it did and just leave the link as it is seeing as they can't even be displayed even when they can embed properly in another browser.

 

Screenshots of the issue, if applicable: 

image.png.9e45ebc4053b1c26031be242348715a3.png

I see you have UBlock Origin. Is that causing the issue?

If that is the problem, it would also potentially explain why Chromium would work, since Chrome doesn't support UBlock origin anymore.

Quote
Quote
Quote

By reading this, you're entering a contract that says you have to visit my profile.

 

 

Link to post
Share on other sites

11 hours ago, GoStormPlays said:

I see you have UBlock Origin. Is that causing the issue?

If that is the problem, it would also potentially explain why Chromium would work, since Chrome doesn't support UBlock origin anymore.

Happens in a private tab with the adblocker disabled, but with slightly different behaviour. Either way it shouldn't behave like this even without the adblocker and an adblocker shouldn't really interfere in any meaningfull way with what happens.

Link to post
Share on other sites

1 hour ago, SteveHeist said:

Opening the embed directly, it seems to have done something funny in Firefox 136.0.2 also - I would find it hard to believe that a perfect black strip with a little bit of video feed down the left hand side is "intended behavior".

It is the intended behaviour, it's the same in chrome as well. This is a coffee pot in a museum behind a panel glass that's being livestreamed and from what I can tell that black bar looks to be covering the glass panel so people can't be seen through, you can see one of the corners of the glass in the bottom left.

image.png.c27faa718be8940161cae3cb3fbe0126.png

Link to post
Share on other sites

The protocol that backs this, multipart/x-mixed-replace, seems to not work so great with the forum software. That protocol is only used for a few very esoteric applications though, and it seems to behave better with the next major version of the forum software (although I have no ETA for when we will pick that up - almost certainly not this year), so it doesn't seem worth reporting to try to get it fixed.

 

(The specific bug is that onLoad is being called multiple times, once per frame, which causes the requests to blow up)

HTTP/2 203

Link to post
Share on other sites

On 3/30/2025 at 6:16 PM, colonel_mortis said:

The protocol that backs this, multipart/x-mixed-replace, seems to not work so great with the forum software. That protocol is only used for a few very esoteric applications though, and it seems to behave better with the next major version of the forum software (although I have no ETA for when we will pick that up - almost certainly not this year), so it doesn't seem worth reporting to try to get it fixed.

 

(The specific bug is that onLoad is being called multiple times, once per frame, which causes the requests to blow up)

Makes sense. Is it possible to disable embedding of the specific format to stop this from happening?

Link to post
Share on other sites

1 hour ago, AndrewAsd said:

Makes sense. Is it possible to disable embedding of the specific format to stop this from happening?

Not very easily without the involvement of the forum software devs, although given how rare the format is I'm not too worried about that.

HTTP/2 203

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×