Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Several crypto APIs incorrectly have have ArrayBuffer input types instead of BufferSource #2549

Open
brettwillis opened this issue Aug 19, 2024 · 0 comments
Assignees
Labels
types Related to @cloudflare/workers-types

Comments

@brettwillis
Copy link

Just to name the examples that I've encountered:

  • SubtleCryptoEncryptAlgorithm.iv
  • SubtleCryptoEncryptAlgorithm.counter
  • SubtleCryptoGenerateKeyAlgorithm.publicExponent

I suspect there could be many other instances too.

These have the ArrayBuffer type which is incorrectly too restrictive when they should have the BufferSource type (which accepts ArrayBuffer, TypedArrays and DataView as per the spec).

@brettwillis brettwillis added the types Related to @cloudflare/workers-types label Aug 19, 2024
@github-project-automation github-project-automation bot moved this to Untriaged in workers-sdk Aug 19, 2024
@andyjessop andyjessop removed this from workers-sdk Aug 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
types Related to @cloudflare/workers-types
Projects
None yet
Development

No branches or pull requests

2 participants