Closed Bug 2077437 Opened 1 month ago Closed 1 month ago

[wpt-sync] Sync PR 63191 - webcodecs: Validate constructor arguments before transferring buffers

Categories

(Core :: Audio/Video: Web Codecs, task, P4)

task

Tracking

()

RESOLVED FIXED
160 Branch
Tracking Status
firefox160 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Attachments

(2 files)

Sync web-platform-tests PR 63191 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/63191
Details from upstream follow.

Eugene Zemtsov <eugene@chromium.org> wrote:

webcodecs: Validate constructor arguments before transferring buffers

Ensure WebCodecs constructors (AudioData, ImageDecoder, VideoFrame,
EncodedVideoChunk, and EncodedAudioChunk) validate all init parameters
before calling TransferArrayBufferForSpan(), so that throwing
constructors do not detach ArrayBuffers in init.transfer.

Also throw TypeError instead of NotSupportedError in AudioData when
sampleRate \<= 0 per the WebCodecs spec.

Bug: 562608155
Change-Id: Id73764813bc917c617143c41aee3b2ec00ee9f18
Reviewed-on: https://chromium-review.googlesource.com/8497290
WPT-Export-Revision: b4ba2dcf7c6a69b9fb67fba940536cab27c6b25b

Component: web-platform-tests → Audio/Video: Web Codecs
Product: Testing → Core
Whiteboard: [wptsync downstream] → [wptsync downstream error]
Whiteboard: [wptsync downstream error] → [wptsync downstream]
Attached file Notable wpt changes —

CI Results

Ran 9 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 258 tests and 6 subtests

Status Summary

Firefox

OK : 4[GitHub] 175[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview] 239[Gecko-linux2204-64-wayland-debug, Gecko-linux2204-64-wayland-opt, Gecko-linux2404-64-debug, Gecko-linux2404-64-opt] 241[Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt]
PASS : 64[GitHub] 1630[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview] 2248[Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt] 2342[Gecko-linux2204-64-wayland-debug, Gecko-linux2204-64-wayland-opt, Gecko-linux2404-64-debug, Gecko-linux2404-64-opt]
FAIL : 8[GitHub] 349[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview] 360[Gecko-linux2204-64-wayland-debug, Gecko-linux2204-64-wayland-opt, Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt]
PRECONDITION_FAILED: 23[Gecko-linux2204-64-wayland-debug, Gecko-linux2204-64-wayland-opt, Gecko-linux2404-64-debug, Gecko-linux2404-64-opt] 121[Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt] 517[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview]
ERROR : 4[Gecko-linux2204-64-wayland-debug, Gecko-linux2204-64-wayland-opt, Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt] 12[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview]
NOTRUN : 40

Chrome

OK : 4
PASS : 64
FAIL : 8

Safari

OK : 4
PASS : 50
FAIL : 22

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

Details

(See attachment for full changes)

Attached file Notable wpt changes —

CI Results

Ran 9 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 258 tests and 6 subtests

Status Summary

Firefox

OK : 4[GitHub] 175[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview] 239[Gecko-linux2204-64-wayland-debug, Gecko-linux2204-64-wayland-opt, Gecko-linux2404-64-debug, Gecko-linux2404-64-opt] 241[Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt]
PASS : 64[GitHub] 1630[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview] 2248[Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt] 2342[Gecko-linux2204-64-wayland-debug, Gecko-linux2204-64-wayland-opt, Gecko-linux2404-64-debug, Gecko-linux2404-64-opt]
FAIL : 8[GitHub] 349[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview] 360[Gecko-linux2204-64-wayland-debug, Gecko-linux2204-64-wayland-opt, Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt]
PRECONDITION_FAILED: 23[Gecko-linux2204-64-wayland-debug, Gecko-linux2204-64-wayland-opt, Gecko-linux2404-64-debug, Gecko-linux2404-64-opt] 121[Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt] 517[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview]
ERROR : 4[Gecko-linux2204-64-wayland-debug, Gecko-linux2204-64-wayland-opt, Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt] 12[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview]
NOTRUN : 40

Chrome

OK : 4
PASS : 64
FAIL : 8

Safari

OK : 4
PASS : 50
FAIL : 22

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

Details

(See attachment for full changes)

Pushed by wptsync@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/e544862d82d7 https://hg.mozilla.org/integration/autoland/rev/aeae056f24f6 [wpt PR 63191] - webcodecs: Validate constructor arguments before transferring buffers, a=testonly
Status: NEW → RESOLVED
Closed: 1 month ago
Resolution: --- → FIXED
Target Milestone: --- → 160 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: