-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Add Ed25519 sign-verify example #247
Conversation
Thanks for the submission. This doesn't work for me using Chrome Canary / Beta:
I don't see any preferences / flags to enable. The following works in node: async function generateAndSignKey() {
const algorithm = { name: "Ed25519" };
const encoder = new TextEncoder();
const cryptoKey = await crypto.subtle.generateKey(
algorithm,
true,
["sign", "verify"]
);
console.log(
await crypto.subtle.sign(
algorithm,
cryptoKey.privateKey,
new Uint8Array([255])
)
);
}
generateAndSignKey(); With an exp warning:
|
Launch Chrome or Chromium with E.g., for testing
|
Confirmed this is working, also possible via |
Closed by mistake, please ignore |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Leaving a +1 on this, thank you!
Thanks a lot for your review @twiss, I've incorporated your feedback and I'm happy to merge in the current state unless you have any objections! |
Co-authored-by: Daniel Huigens <[email protected]>
See mdn/content#30886