Commit Graph

431 Commits

Author SHA1 Message Date
Domenico Rizzo
162c697248 [26488] - Moves drop logic to inner struct for GPUBindGroupLayout (#41984)
Moves the drop logic for `GPUBindGroupLayout` to an inner struct
`DroppableGPUBindGroupLayout`.

Testing: No tests added
Fixes: Partially #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2026-01-18 17:20:14 +00:00
Domenico Rizzo
0417968ee9 [26488] - Refactors GPUBindGroup drop implementation (#41977)
Moves the drop implementation for `GPUBindGroup` to a separate
`DroppableGPUBindGroup` struct.

Testing: No tests added
Fixes: partially #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2026-01-17 17:53:56 +00:00
Sam
89cfe15b3e script: use &mut CurrentRealm in cross_origin_has_own (#41955)
Testing: Just refactor, but covered by existing WPT tests.
Part of #40600

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
2026-01-16 11:05:26 +00:00
eri
9d35414386 devtools: Handle the setBreakpoint message. (#41925)
Listen for `setBreakpoint` on `debugger.js` and add the relevant WebIDLs
and Servo counterparts to trigger this event and notify SpiderMonkey.

Implement `find_source` for `SourceManager` and `find_offset` for
`SourceActor`.

Testing: Manual testing and `./mach test-devtools` (note, the latter
seems to have some failing tests, we are investigating this, but this
patch doesn't add any new failure).
Fixes: Part of #36027

---------

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
2026-01-16 10:17:55 +00:00
Domenico Rizzo
380884523a script: Move adapter dropping to a dedicated struct (#41911)
Moves the adapter dropping logic from the `GPUAdapter` struct to a new
`DroppableGPUAdapter` struct.

Testing: No tests added.
Fixes: Partially #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2026-01-15 07:13:52 +00:00
Sam
2def1fbdce script: &mut JSContext in cross_origin_own_property_keys and append_cross_origin_allowlisted_prop_keys (#41879)
Testing: Just refactor, but should be covered by WPT tests.
Fixes: #40600

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
2026-01-13 15:49:09 +00:00
Sam
5b11f7619e script: add &mut JSContext to codegened toJSON (#41878)
Testing: Just refactor, but should be covered by WPT tests
Part of #40600

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
2026-01-13 14:48:57 +00:00
WaterWhisperer
2a759ed6de Replace allow(crown::unrooted_must_root) with expect(crown::unrooted_must_root) (#41815)
Testing: `./mach build -d --use-crown` with no warnings
Fixes: #41761

Signed-off-by: WaterWhisperer <waterwhisperer24@qq.com>
2026-01-10 08:05:49 +00:00
WaterWhisperer
705e76d379 script: Set keepalive flag in Request's constructor (#41811)
Testing: 
- `./mach test-wpt
tests/wpt/tests/fetch/api/request/request-keepalive.any.js`
- `./mach test-wpt
tests/wpt/tests/fetch/api/request/request-keepalive-quota.html`

Fixes: #41724

Signed-off-by: WaterWhisperer <waterwhisperer24@qq.com>
2026-01-09 17:28:55 +00:00
Sam
5173ea12cd script: More &mut JSContext in codegen (#41808)
Reviewable per commit. First commit adds `&mut JSContext` to
`call_default_constructor`. Second commit adds `&mut JSContext` to
Interface, which in unfortunately required many changes (a lot of
passing `&mut JSContext` down).

Testing: Just a refactor, but should be covered by WPT
Part of #40600

---------

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
2026-01-09 14:50:54 +00:00
Sam
b1245dce4c script: Use &mut JSContext in html_constructor (#41782)
Testing: Just refactor, but should be covered by WPT.
Part of #40600

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
2026-01-08 21:09:48 +00:00
Domenico Rizzo
4d7e4a3b86 26488 - Moves CookieStore drop logic to a separate struct (#41783)
Refactors the `CookieStore` to use a separate `DroppableCookieStore`
struct for handling the drop logic.

Testing: No tests added
Fixes: Partially #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2026-01-08 21:06:17 +00:00
Narfinger
13c875eeea Base: Dependency cleanup (#41777)
Removing some unused dependencies in components.

Like a rainforest
the dependencies are growing,
we need a machete.

Testing: Full mach try run here:
https://github.com/Narfinger/servo/actions/runs/20823235587

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-01-08 17:32:35 +00:00
WaterWhisperer
56bc26a7cc script: Implement Origin API (#41712)
Testing: `./mach test-wpt /html/browsers/origin/api/`
Fixes: #41106

Signed-off-by: WaterWhisperer <waterwhisperer24@qq.com>
2026-01-08 15:35:39 +00:00
Sam
89067e5450 script: Pass &mut JSContext to tasks (#41756)
This change is reviewable per commits:
In first commit we added `&mut JSContext` to `run_box` (it is very hard
to bring `&mut JSContext` to `remove_script_and_layout_blocker`).
In second commit we pass `&mut JSContext` to `run_once`.
In third commit we added support for accepting `&mut JSContext` in
closures of `task!` macro and lastly we demo new macro invocations (to
ensure they actually compile)

Testing: Just refactor, but should be covered by WPT
Part of #40600

---------

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
2026-01-08 07:49:27 +00:00
Domenico Rizzo
2bcad737fa 26488 - Moves WebGLRenderingContext cleanup to a dedicated struct (#41717)
Refactors the WebGLRenderingContext to manage resource cleanup via a
dedicated `DroppableWebGLRenderingContext` struct.

Testing: This task is only a refactor, no tests added
Fixes: partially #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2026-01-07 04:24:17 +00:00
Tim van der Lippe
2988ba5a08 script: Ship navigator.sendBeacon (#41694)
With keep-alive requests implemented, this feature is now fully working.
Some tests still fail on
header parsing, which is #36801

Fixes #38302

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-01-05 20:17:50 +00:00
Kingsley Yung
259b3985ee script: Implement sign and verify operations of ML-DSA (#41676)
Finish adding ML-DSA support to WebCrypto API.

This patch implements the sign and verify operations of ML-DSA, with
`ml-dsa` crate.

Specification:
https://wicg.github.io/webcrypto-modern-algos/#ml-dsa-operations-sign
https://wicg.github.io/webcrypto-modern-algos/#ml-dsa-operations-verify

Testing: Pass some WPT tests that were expected to fail.
Fixes: Part of #41626

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-01-05 06:12:58 +00:00
Leo Ring
0832875414 Correct path to twin find_python() functions in servo and script_bindings build.rs (#41649)
Just fixed a discrepancy in comments I noticed, the files were moved
around in https://github.com/servo/servo/pull/35157

Signed-off-by: Leo Ring <leoring03@gmail.com>
2026-01-03 13:06:50 +00:00
aquaThirsty
d808cc15d0 change #[allow]s to #[expect]s (#41635)
Changed most #[allow]s to #[expect]s, mainly for
clippy::too_many_arguments

Removed unfulfilled expectations

This is my first opensource contribution, so please let me know if
anything should
be done differently.

Testing: Refactor
Part of: #40838

---------

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
Signed-off-by: TimurBora <timurborisov5561@gmail.com>
Co-authored-by: Tim van der Lippe <TimvdLippe@users.noreply.github.com>
2026-01-03 10:54:27 +00:00
Wayne Van Son
5b9263690d Refactor allow to expect (#41586)
Replace `allow` with `expect` lints for `unused`, `unsafe_code`,
`dead_code`, and `non_upper_case_globals`.

Testing: So far just check it compiled on `x86_64-linux` on NixOS. Need
to use the module `system.fontconfig.enable = true;` I think in my NixOS
config.
Part of: #40383 

Searching `allow\(.*\)` for `.rs` files shows the following. for
(total_results:total_files) went from `707:386` to `675:368`, a
reduction of `32:18`.

How many files is too many files per PR? I feel like the 20-30 I have is
too big.

---------

Signed-off-by: Wayne Van Son <waynevanson@gmail.com>
2026-01-01 13:40:20 +00:00
Kingsley Yung
96ddb0bbf0 script: Implement WebCrypto encapsulation and decapsulation with ML-KEM (#41617)
Complete the ML-KEM support in WebCrypto API, with the implementation of
the "encapsulate" and "decapsulate" operations of ML-KEM, as well as
four new methods `encapsulateKey`, `encapsulateBits`, `decapsulateKey`
and `decapsulateBits` of `SubtleCrypto`.

Specification:

https://wicg.github.io/webcrypto-modern-algos/#ml-kem-operations-encapsulate

https://wicg.github.io/webcrypto-modern-algos/#ml-kem-operations-decapsulate

https://wicg.github.io/webcrypto-modern-algos/#SubtleCrypto-method-encapsulateKey

https://wicg.github.io/webcrypto-modern-algos/#SubtleCrypto-method-encapsulateBits

https://wicg.github.io/webcrypto-modern-algos/#SubtleCrypto-method-decapsulateKey

https://wicg.github.io/webcrypto-modern-algos/#SubtleCrypto-method-decapsulateBits

Testing: Pass some WPT tests that were expected to fail.
Fixes: Part of #41473

---------

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-01-01 13:30:04 +00:00
Sam
d1ba789482 script: Obtain &mut JSContext at the start of the script and pass it down to msg handlers (#41564)
At the start of the script we create first (and only[^1]) safe
`JSContext`, from where we should pass it down to every code that needs
the cx. This PR brings it all the way down to message handlers. There is
clear separation between functions that use new model `&mut JSContext`
and the ones that use the old model (usually they take can_gc).

[^1]: Another place of construction are SM hooks (that pass us down raw
JSContext), but to reach that point we already needed to call another
function that takes `&mut JSContext`, so one can look at this case as
reentering/reborrowing (we derive new shorter `&mut JSContext` from the
old one).

Testing: This is just refactor, but should covered by WPT tests.
Part of #40600

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
2025-12-30 18:19:41 +00:00
Kingsley Yung
5d6d2c67bb script: Implement import key operation of ML-KEM (#41585)
Start adding ML-KEM support to WebCrypto API.
Specification: https://wicg.github.io/webcrypto-modern-algos/#ml-kem

This patch implements import key operation of ML-KEM, with `ml-kem`
crate.

Testing: Pass some WPT tests that were expected to fail.
Fixes: Part of #41473

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2025-12-30 11:46:10 +00:00
Sam
6e0e50505e script: Use more new JSContext/CurrentRealm in crossorigin codegen (#41537)
reviewable per commit

Testing: Should be covered by WPT tests.
try run: https://github.com/sagudev/servo/actions/runs/20540365373
Part of #40600

---------

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
2025-12-27 15:59:32 +00:00
Sam
600accba82 script: Support new context for promise and add some more helpers to ease migration (#41520)
This PR adds support for using new JSContext/CurrentRealm to promise and
adds some more helpers that will ease migration to new context model.
Second commit has another demo.

Testing: Covered by WPT
Part of #40600

---------

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
2025-12-27 13:11:37 +00:00
Martin Robinson
f418c1272f base: Move Unicode offset types to base (#41521)
This moves the Unicode offset types to the `base` crate and makes them
generally more usable throughout the Servo codebase. In addition, they
are renamed to use Rust naming and to be a bit more consistent:

 - `UTF8Bytes` -> `Utf8CodeUnitLength`
 - `UTF16CodeUnits` -> `Utf16CodeUnitLength`

There is also a bit more documentation explaining their use.

This is preparation for fixing issues with UTF-16 offsets in editable
text fields.

Testing: This does not change behavior so existing WPT tests should
suffice.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2025-12-25 14:48:40 +00:00
Sam
a41ed4ca24 script: Use more wrappers2 in maybe_cross_origin_set_rawcx (#41519)
This is companion PR to https://github.com/servo/mozjs/pull/680 but it
was originally written as part of #40716.

Testing: Covered by
`/webidl/ecmascript-binding/global-object-implicit-this-value-cross-realm.html`

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
2025-12-25 08:19:35 +00:00
Martin Robinson
273c1d54b7 Fix build of ./mach test-unit -p base (#41498)
`malloc_size_of` depends on `tendril` having the `encoding_rs` feature
turned on, but this was only turned on transitively via `html5ever` and
`script`/ `script_bindings` `tendril` dependencies. This change makes it
so that `malloc_size_of` depends directly on `tendril` and moves this
dependency to the root `Cargo.toml`.

Testing: This just fixes a particular build configuration.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2025-12-23 17:44:36 +00:00
Gregory Terzian
9cd480f7ee indexeddb: implement databases concept(detete and databases method) (#41322)
Moves the concept of databases closer to the 3.0 spec, by implementing
the delete functionality, and the method returning current databases to
script.

Testing: WPT tests with new passes
Fixes: The "Implement databases deletion and `databases`" item of
https://github.com/servo/servo/issues/40983

---------

Signed-off-by: gterzian <2792687+gterzian@users.noreply.github.com>
2025-12-23 14:09:48 +00:00
Steven Novaryo
b68d277c55 script: Add stub VisualViewport Interface (#41372)
Add placeholder implementation of DOM `VisualViewport` according to the
spec https://drafts.csswg.org/cssom-view/#visualviewport. This is the
first step of implementing the interface and syncing it with the
`PinchZoom` struct that we had in the `Embedder`.

Since this interface's is not accurate and couldn't fulfill it's
purpose, it would be gated behind a preference
`dom_visual_viewport_enabled` and would be open after the interface had
been integrated with `PinchZoom`, viewport resizing, and viewport
scroll.

Testing: Existing WPT Test.
Part of: #41341

---------

Signed-off-by: Jo Steven Novaryo <steven.novaryo@gmail.com>
2025-12-23 09:56:13 +00:00
WaterWhisperer
6623cc1dbb feat: gamepad feature flag (#41451)
Put the Gamepad API and its supporting infrastructure behind a `gamepad`
feature flag. This allows embedders to opt-out of gamepad support at
compile time to save on binary size and reduce dependencies.

Testing:
1. `./mach build -d` (Gamepad enabled by default)
2. `cargo build -p servoshell --no-default-features --features
"libservo/clipboard,js_jit,max_log_level,webgpu"` (Gamepad Disabled)
3. `cargo build -p servoshell --features "gamepad,webxr,..."` (Gamepad &
WebXR Enabled)

Fixes: #40897

Signed-off-by: WaterWhisperer <waterwhisperer24@qq.com>
2025-12-21 13:18:06 +00:00
Tim van der Lippe
5b6509f279 script: Implement customElementRegistry support for document.importNode (#41385)
This method now allows you to pass in a custom registry. The registry
isn't used yet for callers, since we don't support scoped registries.
However, as we now pass in the registry to `Node::clone`, we set the
registry when creating elements and cloning them.

As such, various tests start passing where we set the registry. Some
tests started failing, but they rely on scoped registries which we don't
support yet. These tests thus flipped: those that were erroneously
failing are now passing and vice versa.

Part of #34319

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2025-12-19 09:01:08 +00:00
Tim van der Lippe
3ac02bc6ac script: Mark fetch-later requests as keep-alive (#41345)
This implements the required plumbing for the keep-alive flag on
requests. The flag already exists on the request object, but now also
exists on the builder itself.

The flag is then passed into a canceller. While we could make canceller
optional, in many cases it isn't and would require a whole lot more
changes. To follow the spec more closely, opted to put the keep_alive
flag on the canceller as well.

Note that this doesn't pass any extra fetch-later tests since we are not
correctly unloading iframe documents. That will be fixed in a follow-up
PR.

Part of #41230

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2025-12-18 19:49:13 +00:00
Martin Robinson
75c6dc845f stylo: Enable vendor-prefixed properties (#41350)
This changes updates to the latest version of stylo which includes
vendor-prefixed properties such as `-moz-transform` and
`-webkit-transform`. This allows more web content to render properly.

Note: Unitless perspective is not supported as part of this yet, but
will be once https://phabricator.services.mozilla.com/D274128 is part
of our downstream version of Stylo.

Testing: There are tests for this change.
Fixes: #17635.
Fixes: #14941.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2025-12-17 19:08:43 +00:00
Kingsley Yung
0261ab1ef9 script: Implement encrypt/decrypt operations of RSA-OAEP (#41316)
Finish adding RSA-OAEP support to WebCrypto API, by implementing the
encrypt and decrypt operations of RSA-OAEP.

Testing: Pass some WPT tests that were expected to fail.
Fixes: Part of #41113

---------

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2025-12-17 11:21:31 +00:00
Kingsley Yung
706e06315d script: Implement sign/verify operations of RSA-PSS (#41287)
Finish adding RSA-PSS support to WebCrypto API, by implementing the sign
and verify operations of RSA-PSS.

Testing: Pass some WPT tests that were expected to fail.
Fixes: Part of #41113

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2025-12-15 16:54:44 +00:00
Kingsley Yung
84e8194434 script: Implement generate key operations of three RSA algorithms (#41240)
This patch implements generate key operations of three RSA algorithms
(RSASSA-PKCS1-v1_5, RSA-OAEP, RSA-OAEP), with `rsa` crate.

The three operations are very similar to each other, so we can implement
them as a single function, located at the sub-module `rsa_common`,
shared among the three RSA algorithms. The enum `RsaAlgorithm` is used
differentiate the behavior of a few steps (Step 1, 5, 13 and 18) that
are slightly different among the three RSA algorithms.

Testing: Pass some WPT tests that were expected to fail.
Fixes: Part of #41113

---------

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
Co-authored-by: Josh Matthews <josh@joshmatthews.net>
2025-12-13 05:10:34 +00:00
Josh Matthews
d86d2a90aa script: Use rooted typed arrays in generated code and buffer source APIs (#41228)
There are two flavours of the mozjs `TypedArray<T>` wrapper for typed
array objects: one stores a `Box<Heap<*mut JSObject>>`, while the other
just has a bare `*mut JSObject`. The second one must only be stored
inside the `CustomAutoRoot` rooting values, but we were using it in many
other places like WebIDL dictionaries without rooting it safely. These
changes make our typed array APIs always use
`RootedTraceableBox<TypedArray<T>>` with the `Box<Heap<*mut JSObject>>`
flavour, which ensures that the JS object stored inside the typed array
wrapper is always visible to the SpiderMonkey GC.

Testing: Adds a new test that crashes without these changes.
Fixes: #41206

---------

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2025-12-12 14:33:45 +00:00
Kingsley Yung
56d9e24bff script: Implement import key operation of RSA-PSS (#41157)
Start adding RSA-PSS support to WebCrypto API.

This patch implements import key operation of RSA-PSS, with `rsa` crate.

Testing:
- Pass some WPT tests that were expected to fail.
- Some new FAIL expectations are added. They were skipped by WPT when
the import key operation of RSA-PSS had not been implemented, and
requires other not-yet-implemented operations to pass.

Fixes: #34362, and part of #41113

---------

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2025-12-09 15:34:01 +00:00
Josh Matthews
d7234379dd script_bindings: Remove Drop impl exception for WebGLProgram. (#41124)
The handwritten Drop implementation was removed in #37622, so we can now
remove the exception for it.

Testing: Compile-time generated code can't be meaningfully tested.
Fixes: part of #26488

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2025-12-08 05:23:47 +00:00
Domenico Rizzo
34160f994c script: Move WebGLProgram Drop implementation to a member type (#37622)
Testing: No new tests introduced
Fixes: Partially #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2025-12-07 22:18:46 +00:00
Taym Haddadi
371e7fc9f6 Expose window.clientInformation as a navigator alias (#41111)
Expose window.clientInformation as a navigator alias.

Testing: clientInformation test expectations are updated. 
Fixes: https://github.com/servo/servo/issues/41089

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2025-12-07 12:25:10 +00:00
Anonmiraj
b207be05d9 change some allows to expects (#41040)
Changed some allow to expects and removed the unfulfilled expectations.

Testing: Refactor
Part of: #40383

Signed-off-by: anonmiraj <nabilmalek48@gmail.com>
2025-12-05 07:23:32 +00:00
Taym Haddadi
94e09277e2 Script Implement ReadableByteStreamTee (#35991)
<!-- Please describe your changes on the following line: -->


---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by
`[X]` when the step is complete, and replace `___` with appropriate
data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #35678

<!-- Either: -->
All stream tee tests are passing now.

<!-- Also, please make sure that "Allow edits from maintainers" checkbox
is checked, so that we can help you if you get stuck somewhere along the
way.-->

<!-- Pull requests that do not address these steps are welcome, but they
will require additional verification as part of the review process. -->

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2025-12-03 13:19:21 +00:00
Kingsley Yung
ff8211275d script: Implement encrypt/decrypt operation of ChaCha20-Poly1305 (#41003)
Finish adding ChaCha20-Poly1305 support to WebCrypto API.

This patch implements encrypt operation and decrypt operation of
ChaCha20-Poly1305, using the crate `chacha20poly1305` to support the
cryptographic calculation. The get key length operation of
ChaCha20-Poly1305 is also included in this patch.

Testing: Pass some WPT tests that were expected to fail.
Fixes: Part of #40687

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2025-12-02 07:42:51 +00:00
webbeef
414b25416f script: inline roots.swap_remove() (#40777)
This saves the work done by 'ptr::read()' that we don't use.

Testing: Green WPT run:
https://github.com/webbeef/servo/actions/runs/19560614891

Signed-off-by: webbeef <me@webbeef.org>
2025-11-30 18:20:53 +00:00
Kingsley Yung
a15861cb41 script: Finishing implementation of Argon2 in WebCrypto (#40936)
Finish adding Argon2 support to WebCrypto API, using the crate `argon2`
to support the cryptographic calculation.

This patch implements "derive bits" operation and the "get key length"
operation of Argon2. Actual error messages are also provided for the
existing "import key" operation of Argon2.

Testing: Pass some WPT tests that were expected to fail.
Fixes: Part of #40687

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2025-11-28 10:18:25 +00:00
Kingsley Yung
2982929210 script: Add new KeyFormat and KeyUsage for modern algorithms (#40857)
The specification of Modern Algorithms in the Web Cryptography API
(https://wicg.github.io/webcrypto-modern-algos/) adds new key formats
and key usages to support modern cryptographic algorithms.

This patch adds those new key formats and key usages, preparing for the
implementation of the new algorithms.

Testing: No behavioral changes in existing cryptographic algorithms.
Existing tests suffice.
Fixes: Part of #40687

---------

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2025-11-28 03:55:10 +00:00
Josh Matthews
c2bfb1c6c5 script_bindings: Disallow manual Drop implementations for DOM interfaces. (#40919)
This implements the solution from #26488 that prevents implementing Drop
manually for DOM interfaces, which is very easy to write in a way that
can cause memory safety errors during JS runtime teardown. Since we have
a bunch of pre-existing implementations that we are working on removing,
this PR adds an opt-out mechanism that those interfaces use.

Testing: Compile-time code generation; not possible to test.
Fixes: part of #26488

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2025-11-27 19:53:59 +00:00