Skip to content

Add Keypair::from_bytes()#20

Open
json420 wants to merge 10 commits into
Argyle-Software:masterfrom
json420:master
Open

Add Keypair::from_bytes()#20
json420 wants to merge 10 commits into
Argyle-Software:masterfrom
json420:master

Conversation

@json420
Copy link
Copy Markdown

@json420 json420 commented Feb 9, 2025

I'd like to add a Keypair::from_bytes() method modeled after ed25519_dalek::SigningKey::from_bytes():

https://docs.rs/ed25519-dalek/latest/ed25519_dalek/struct.SigningKey.html#method.from_bytes

This seems to be pretty standard API for most Public Key crypto libraries. Very useful for Know Answer Tests at the protocol level. Can be handy when integrating with specialized random number hardware. And in my particular case, I really need to provide the entropy because I'm doing application level entropy accumulation at each signature (and switching to a new keypair at each signature):

https://github.com/zebrafactory/zebrachain

I've tested this on Pop!_OS against Rust nightly, beta, and stable. It's also been tested via my GitHub test runs for ZebraChain against Rust stable on Ubuntu, MacOS, and Windows.

Thanks for your great pure Rust implementations of Dilithium and sphincsplus!

Have an awesome day!

@json420
Copy link
Copy Markdown
Author

json420 commented Feb 9, 2025

Oh, sorry about the noise in Cargo.toml. The change was needed to get it working on recent cargo versions.

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.

1 participant