-
Notifications
You must be signed in to change notification settings - Fork 261
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add
subxt_signer
crate for native & WASM compatible signing (#1016)
* Add and use subxt-signer crate for WASM compatible signing * cargo fmt * dev keypairs already references * WIP fix various breakages * re-jig features to be simpler and various test fixes etc * doc and web fix * fix various bits and pieces * fix a test I broke * dev-deps can't be linked to in docs, hrmph * cargo fmt * another doc link * document the subxt_signer crate more thoroughly * move feature flag for consistency * more docs, no default subxt feature flag on signer, update release instrs * Add missing license header * unwrap_inner => into_inner * extend a test a little to better check derive junctions * note more clearly that the crypto bits come from sp_core::crypto
- Loading branch information
Showing
52 changed files
with
1,388 additions
and
302 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
[package] | ||
name = "subxt-signer" | ||
version.workspace = true | ||
authors.workspace = true | ||
edition.workspace = true | ||
rust-version.workspace = true | ||
publish = true | ||
|
||
license.workspace = true | ||
readme = "README.md" | ||
repository.workspace = true | ||
documentation.workspace = true | ||
homepage.workspace = true | ||
description = "Sign extrinsics to be submitted by Subxt" | ||
keywords = ["parity", "subxt", "extrinsic", "signer"] | ||
|
||
[features] | ||
default = [] | ||
|
||
# Make the keypair algorithms here compatible with Subxt's Signer trait, | ||
# so that they can be used to sign transactions for compatible chains. | ||
subxt = ["dep:subxt"] | ||
|
||
# The getrandom package is used via schnorrkel. We need to enable the JS | ||
# feature on it if compiling for the web. | ||
web = ["getrandom/js"] | ||
|
||
[dependencies] | ||
regex = { workspace = true } | ||
subxt = { workspace = true, optional = true } | ||
hex = { workspace = true } | ||
codec = { package = "parity-scale-codec", workspace = true, features = ["derive"] } | ||
sp-core-hashing = { workspace = true } | ||
thiserror = { workspace = true } | ||
pbkdf2 = { workspace = true } | ||
sha2 = { workspace = true } | ||
hmac = { workspace = true } | ||
zeroize = { workspace = true } | ||
bip39 = { workspace = true } | ||
schnorrkel = { workspace = true } | ||
secrecy = { workspace = true } | ||
|
||
# We only pull this in to enable the JS flag for schnorrkel to use. | ||
getrandom = { workspace = true, optional = true } | ||
|
||
[dev-dependencies] | ||
sp-core = { workspace = true, features = ["std"] } | ||
sp-keyring = { workspace = true } |
Oops, something went wrong.