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

[crypto] Ad-hoc deserialization from ssh-keygen armored files #19

Closed
huitseeker opened this issue Jul 21, 2022 · 5 comments
Closed

[crypto] Ad-hoc deserialization from ssh-keygen armored files #19

huitseeker opened this issue Jul 21, 2022 · 5 comments
Assignees

Comments

@huitseeker
Copy link
Contributor

For genesis, we have node runners that like to generate their keypair (EdDSA) from the ssh-keygen tool (a well-trusted implementation).

We would like to be able to import and deserialize an EdDSA keypair as generated from ssk-keygen, which means interpreting the armored format for the private key. We would add this functionality as a simple pub function in out ed25519.rs, which would be integrated in our tooling Sui-side.

The rust crate rust-sshkeys provides a lot of tooling for reading the ssh pem files, but unfortunately, at the moment, only reads Pubkeys (whereas we would like to generate a keypair, hence reading private keys).

@joyqvq joyqvq self-assigned this Jul 21, 2022
@joyqvq
Copy link
Collaborator

joyqvq commented Jul 26, 2022

do we want to support passphrase protected keys? if so, this may be a bit of more work. also there seems to be few versions of the PEM format, may be a bigger scope to support all of them.

I started on a branch armored-key and plan to use https://github.com/Leo1003/rust-osshkeys and realized few missing features and there isn't a matured library to support this. i may need to patch the library - documenting my progress here

@huitseeker
Copy link
Contributor Author

I think at this stage the goal is to let folks use a tool they like and trust to generate their key. The goal is to first support one of the ways to generate a key with ssh-keygen (e.g. with no passphrase, one format only). We can leave the extension of that core of functionality for a second iteration.

@huitseeker huitseeker transferred this issue from MystenLabs/narwhal Aug 23, 2022
@kchalkias
Copy link
Collaborator

cc: @huitseeker and @joyqvq is this still an active issue?

@joyqvq
Copy link
Collaborator

joyqvq commented Sep 23, 2022

this is still useful. let me revisit this next week.

@joyqvq
Copy link
Collaborator

joyqvq commented May 9, 2023

@joyqvq joyqvq closed this as completed May 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants