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

feat(ext/crypto): add x25519 and Ed25519 CFRG curves #14119

Merged
merged 21 commits into from
Sep 27, 2022

Conversation

littledivy
Copy link
Member

@littledivy littledivy commented Mar 25, 2022

Implements Curve25519 from https://github.com/WICG/webcrypto-secure-curves

We will probably have to rollout our own Curve448, there is no ring, RustCrypto OR rust-dalek crate for that. Left that for now.

@stale
Copy link

stale bot commented Jun 4, 2022

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Jun 4, 2022
@stale stale bot closed this Jun 11, 2022
@littledivy littledivy removed the stale label Jun 11, 2022
@littledivy littledivy reopened this Jun 11, 2022
@stale
Copy link

stale bot commented Sep 20, 2022

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Sep 20, 2022
@littledivy
Copy link
Member Author

Not stale!

@stale stale bot removed the stale label Sep 21, 2022
@littledivy littledivy mentioned this pull request Sep 21, 2022
@littledivy littledivy changed the title [wip] feat(ext/crypto): implement "WebCrypto Secure Curves" feat(ext/crypto): implement "WebCrypto Secure Curves" Sep 21, 2022
@littledivy littledivy marked this pull request as ready for review September 22, 2022 10:12
@littledivy littledivy changed the title feat(ext/crypto): implement "WebCrypto Secure Curves" feat(ext/crypto): add x25519 and Ed25519 CFRG curves Sep 22, 2022
Copy link
Contributor

@panva panva left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am stoked to see this. Do you plan for X448 and Ed448 as well?

Copy link
Member

@ry ry left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🙌

@littledivy
Copy link
Member Author

Do you plan for X448 and Ed448 as well?

Yes, planned but we'll have to evaluate existing Rust crates that do curve448 - I couldn't find a 'widely-used' crate. That said it shouldn't be too hard to write our own.

@littledivy littledivy merged commit f02f242 into denoland:main Sep 27, 2022
@panva
Copy link
Contributor

panva commented Sep 29, 2022

@littledivy I'm finding it hard to navigate what has been implemented here. I'm able to generate both key types. Despite import code being added for both I can import neither one (Ed says the algorithm is unrecognized, X says the key data is invalid). X export seems to be omitted despite being the same as Ed wrt to the key material. Ed signatures fail to validate.

@littledivy
Copy link
Member Author

Yikes! Seems like I didn't push all changes from my local branch :(

cjihrig added a commit to cjihrig/deno that referenced this pull request Sep 30, 2022
When storing public and private keys in the key store, use
a different handle for each key so that they can be looked up
in the future.

Refs: denoland#14119
Refs: denoland/std#2631
@panva
Copy link
Contributor

panva commented Sep 30, 2022

@littledivy I hope it's not lost ;)

cjihrig added a commit that referenced this pull request Sep 30, 2022
When storing public and private keys in the key store, use a different
handle for each key so that they can be looked up in the future.

Refs: #14119
Refs: denoland/std#2631
@twiss twiss mentioned this pull request Feb 19, 2024
8 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants