Closed Bug 1608440 Opened 4 years ago Closed 4 years ago

Firefox UI freeze when Web Worker loads large script

Categories

(Core :: DOM: Workers, defect, P2)

74 Branch
x86_64
Windows 10
defect

Tracking

()

RESOLVED FIXED
Tracking Status
firefox74 --- wontfix
firefox75 --- wontfix
firefox76 --- fixed
firefox77 --- fixed
firefox78 --- fixed

People

(Reporter: claas, Unassigned)

References

()

Details

This behavior could be abused by malicious sites to freeze Firefox indefinitely (by loading the large script in a loop).

Steps to reproduce the behavior:

  1. See repository: https://github.com/caugner/vue-ffmpeg-worker-firefox-freeze
  2. git clone https://github.com/caugner/vue-ffmpeg-worker-firefox-freeze
  3. cd vue-ffmpeg-worker-firefox-freeze
  4. yarn install
  5. yarn serve
  6. Open http://localhost:8080 in Firefox.
  7. Notice how the UI freezes (the website itself does not always freeze).

See also: https://github.com/ffmpegjs/ffmpeg.js/issues/19

Note that Chrome does not behave this way.

PS: The relevant JS code is in App.vue and Worker.js at commit ae36e0a: https://github.com/caugner/vue-ffmpeg-worker-firefox-freeze/commit/ae36e0a86aedc49a0065cf64d3325c5047699029#diff-ea994a51b0d9884f4fc046eca11a5c99

Priority: -- → P2

Here's a direct link to reproduce the Firefox UI freeze: https://caugner.github.io/vue-ffmpeg-worker-firefox-freeze/

Firefox Profiler: https://perfht.ml/2Xy4kMq

Note the 6.8s event processing delay at the top. That's the freeze.

I cannot reproduce the freeze in Firefox 78.0a1 (2020-05-05) (64-Bit).

I cannot reproduce the freeze in Firefox 76.0 either, so I assume that the issue has been fixed.

Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.