Open gr2m opened 3 weeks ago
The payload verification is currently implemented using node's built-in crypto module: https://github.com/copilot-extensions/preview-sdk.js/blob/06310d78c9b994ddbdec9f88f404d882b599d820/index.js#L17-L19
crypto
But all modern JS run time environments now have the global crypto API which is WebCrypto - including Node.js.
For compatibility with @octokit which aims to be as universal as possible, we should implement that method using WebCrypto.
the global crypto API which is WebCrypto - including Node.js.
For reference: Node.js v22.9.0 Docs: Web Crypto API
The payload verification is currently implemented using node's built-in
crypto
module: https://github.com/copilot-extensions/preview-sdk.js/blob/06310d78c9b994ddbdec9f88f404d882b599d820/index.js#L17-L19But all modern JS run time environments now have the global
crypto
API which is WebCrypto - including Node.js.For compatibility with @octokit which aims to be as universal as possible, we should implement that method using WebCrypto.