Repository navigation
CryptoKey string tag imprecise for detection #45987
Description
Activity
- added a commit that references this issue
on Dec 27, 2022 Pull request welcome, but...
We do WPT conformance testing so this is probably not a spec requirement. It'd be best to update upstream WPT first before making changes to node. There's a CryptoKey validator you could add a check to.
Thanks for the info. IIRC, there are some separate WebIDL-based tests in WPT which might cover class string (string tag) checks for interfaces (and these tests weren't always contained in the same part of the directory structure).
As far as a spec basis for this, there is some mention of class strings in https://webidl.spec.whatwg.org/ , though I only see it mentioned there for interface prototypes, not necessarily interface objects. I wonder if it is implied elsewhere within WebIDL though.
- addedcryptoIssues and PRs related to the crypto subsystem.Issues and PRs related to the crypto subsystem.
on Jan 1, 2023 - addedwebcryptoIssues and PRs related to the Web Crypto API.Issues and PRs related to the Web Crypto API.
on Jan 1, 2023 - added a commit that references this issue
on Jan 1, 2023 I am not sure about this being a spec requirement too but if all existing implementations adhere, I don't see the point of not adding this to Node.js and WPT.
PR for the WPT repository web-platform-tests/wpt#37716.
- added 4 commits that reference this issue
on Jan 1, 2023 - added a commit that references this issue
on Jan 18, 2023 - added a commit that references this issue
on Jan 18, 2023 - added a commit that references this issue
on Jan 20, 2023 - added 3 commits that reference this issue
on Jan 26, 2023
Version
v18.12.1
Platform
Darwin MacBook-Air-2.local 22.2.0 Darwin Kernel Version 22.2.0: Fri Nov 11 02:04:44 PST 2022; root:xnu-8792.61.2~4/RELEASE_ARM64_T8103 arm64
Subsystem
No response
What steps will reproduce the bug?
How often does it reproduce? Is there a required condition?
Always
What is the expected behavior?
On the browser, this logs
CryptoKeyand allows for detection of object type and we expect it here.What do you see instead?
ObjectAdditional information
This can be readily remedied by adding Symbol.toStringTag to the CryptoKey class returning the value, "CryptoKey".