Skip to content
This repository has been archived by the owner on Jan 4, 2023. It is now read-only.

Commit

Permalink
feat: support wasm32 target
Browse files Browse the repository at this point in the history
  • Loading branch information
Br1ght0ne committed May 28, 2022
1 parent eb482b5 commit e3bd608
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,18 +14,25 @@ description = "Fuel cryptographic primitives."
borrown = "0.1"
fuel-types = { version = "0.5", default-features = false }
lazy_static = { version = "1.4", optional = true }
serde = { version = "1.0", default-features = false, features = ["derive"], optional = true }
sha2 = { version = "0.9", default-features = false }

[target.'cfg(target_arch = "wasm32")'.dependencies]
# the deterministic arguments of the signature (key, nonce, message), as defined in the RFC-6979
rand = { version = "0.8", default-features = false, features = ["alloc"], optional = true }
secp256k1 = { version = "0.20", default-features = false, features = [ "alloc", "rand", "recovery" ], optional = true }

[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
rand = { version = "0.8", default-features = false, features = ["std_rng"], optional = true }
# `rand-std` is used to further protect the blinders from side-channel attacks and won't compromise
# the deterministic arguments of the signature (key, nonce, message), as defined in the RFC-6979
secp256k1 = { version = "0.20", features = [ "rand-std", "recovery" ], optional = true }
serde = { version = "1.0", default-features = false, features = ["derive"], optional = true }
sha2 = { version = "0.9", default-features = false }

[dev-dependencies]
bincode = { version = "1.3", default-features = false }
criterion = "0.3"
fuel-crypto = { path = ".", default-features = false, features = ["random"] }
k256 = { version = "0.10", features = [ "ecdsa" ] }
k256 = { version = "0.10", default-features = false, features = [ "ecdsa" ] }
rand = { version = "0.8", default-features = false, features = ["std_rng"] }
sha2 = "0.9"

Expand Down

0 comments on commit e3bd608

Please sign in to comment.