-
Notifications
You must be signed in to change notification settings - Fork 75
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: add support for OS specific keychains #1703
base: main
Are you sure you want to change the base?
Changes from 29 commits
8c06970
883cb8c
eb70734
d4e2500
3ee20b8
1a24c00
4a0c900
755c318
dd07bf7
f042d19
9cf5916
cd515d3
276558d
20c651b
66d1bfc
8b9763e
fdefa2a
36559ea
f98b709
0f3106b
e120595
c4d6f99
c7e2cbc
57ba3a4
0814e4b
74fa05b
7ff1f6a
f263d8d
e2b7342
dabbb27
d9131b4
3ad6b9b
9d02b01
4bddd24
a72276d
65284cc
e9f86e7
4288630
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
use soroban_cli::signer::keyring::StellarEntry; | ||
|
||
fn main() { | ||
let entry = StellarEntry::new("test").unwrap(); | ||
if let Ok(key) = entry.get_public_key() { | ||
println!("{key}"); | ||
return; | ||
}; | ||
|
||
let secret = soroban_cli::config::secret::Secret::from_seed(None).unwrap(); | ||
let pub_key = secret.public_key(None).unwrap(); | ||
let key_pair = secret.key_pair(None).unwrap(); | ||
entry.set_password(key_pair.as_bytes()).unwrap(); | ||
let pub_key_2 = entry.get_public_key().unwrap(); | ||
assert_eq!(pub_key, pub_key_2); | ||
println!("{pub_key} == {pub_key_2}"); | ||
} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is this used anywhere? I made this when initially testing it out locally. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ah, yep, great catch! this can be removed |
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.
The keyring crate requires this pkg as a dependency, so I am including it on several of these linux workflows. I just wanted to point this out as a dependency and see if there is any other way I should handle this.