Commit Graph

6 Commits

Author SHA1 Message Date
samkim-crypto 6a9a89064b
[clap-v3-utils] Deprecate signer source validation (#33802)
* make `SignerSource` implement `Clone`

* add `SignerSourceParserBuilder`

* deprecate `is_keypair`

* deprecate `is_keypair_or_ask_keyword`

* deprecate `is_prompt_signer_source`

* deprecate `is_pubkey_or_keypair`, `is_valid_pubkey`, and `is_valid_signer`

* deprecate `is_pubkey`

* bump deprecation version to 1.17.2

* temporarily allow deprecation for build

* Apply suggestions from code review

Co-authored-by: Tyera <teulberg@gmail.com>

* fix typo `SignerSourceParseBuilder` --> `SignerSourceParserBuilder`

* add `allow_` prefix to `SignerSourceParserBuilder` fields

* remove `SignerSourceParserBuilder::new()` and replace it with `Default`

* Update keygen/src/keygen.rs

Co-authored-by: Trent Nelson <trent.a.b.nelson@gmail.com>

* update deprecated version to `1.18.0`

---------

Co-authored-by: Tyera <teulberg@gmail.com>
Co-authored-by: Trent Nelson <trent.a.b.nelson@gmail.com>
2024-01-06 08:19:54 +09:00
samkim-crypto 1452ed7044
[zk-token-sdk] Make `ElGamalKeypair` fields private (#32190)
* make `ElGamalKeypair` fields private

* update the rest of `zk-token-sdk` for the visibility update

* update `zk-token-proof-tests` for the visibility update

* update `zk-keygen` for the visibility update

* update `zk-token-proof` benches for the updated visibility

* cargo fmt

* rename `ElGamalKeypair::new` to `ElGamalKeypair::new_for_tests`
2023-06-22 10:28:13 +09:00
steviez 03e0a9e106
Fixed typo: worskapce ==> workspace (#31790) 2023-05-24 05:27:46 +00:00
samkim-crypto daebea0f33
[zk-keygen] Add `pubkey` and `recover` commands (#31740)
* add `pubkey` command

* add `recover` command

* add simple sanity tests for `pubkey` command

* remove short opt for `force`

* implement `FromStr` for `KeyType`

* increase scope for keypair name

* remove `--outfile` option for `pubkey` command

* make `--type` opt into a positional argument

* cargo sort
2023-05-24 07:22:53 +09:00
samkim-crypto 065a81e560
[zk-keygen] import `SeedDerivable` trait (#31738)
import `SeedDerivable` trait
2023-05-21 21:33:23 +09:00
samkim-crypto fd69ae77ff
[zk-keygen] create cli utility and add `new` command (#31641)
* create `solana-zk-keygen` cli util

* add `new` key generation command

* add basic tests

* add Cargo.toml for `zk-keygen`

* replace `KeyType::Symmetric` to `KeyType::Aes128` and update crate description

* remove shortopts for key type

* use stderr for status update

* add clap `debug_assert` tests

* drop all shortopts

* drop unnecessary tests

* remove config file args since it is not needed

* Update zk-keygen/src/main.rs

Co-authored-by: Trent Nelson <trent.a.b.nelson@gmail.com>

* clippy

* add shortopt for `outfile`

* move `silent` match to outer scope

* change `--key-type` arg to `--type`

* Update zk-keygen/Cargo.toml

Co-authored-by: Tyera <teulberg@gmail.com>

---------

Co-authored-by: Trent Nelson <trent.a.b.nelson@gmail.com>
Co-authored-by: Tyera <teulberg@gmail.com>
2023-05-21 11:29:27 +09:00