From 8dfc10ede948deafb5bb2e1f804476b2a34a13bf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tomasz=20Drwi=C4=99ga?= Date: Thu, 18 May 2017 14:50:17 +0200 Subject: [PATCH] [beta] Fix ethsign (#5600) * Fix ethsign in beta. * Fix tests. * Fix compilation. * CI fix remove kcov --- .gitlab-ci.yml | 2 +- Cargo.lock | 62 +++++++++++++++--------------- Cargo.toml | 2 +- dapps/Cargo.toml | 4 +- ethcore/res/ethereum/tests | 2 +- ethkey/src/brain.rs | 4 +- ipfs/Cargo.toml | 2 +- rpc/Cargo.toml | 8 ++-- rpc/src/v1/helpers/dispatch.rs | 11 ++---- rpc/src/v1/tests/mocked/eth.rs | 2 +- rpc/src/v1/tests/mocked/signing.rs | 2 +- rpc_client/Cargo.toml | 2 +- signer/Cargo.toml | 2 +- stratum/Cargo.toml | 6 +-- 14 files changed, 54 insertions(+), 57 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2b3c64d03..ef0e2e97a 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -557,7 +557,7 @@ test-rust-stable: - export RUST_FILES_MODIFIED=$(git --no-pager diff --name-only $CI_BUILD_REF^ $CI_BUILD_REF | grep -v -e ^js -e ^\\. -e ^LICENSE -e ^README.md -e ^appveyor.yml -e ^test.sh -e ^windows/ -e ^scripts/ -e^mac/ -e ^nsis/ | wc -l) script: - export RUST_BACKTRACE=1 - - if [ $RUST_FILES_MODIFIED -eq 0 ]; then echo "Skipping Rust tests since no Rust files modified."; else ./test.sh $CARGOFLAGS&&./scripts/cov.sh "$KCOV_CMD"; fi + - if [ $RUST_FILES_MODIFIED -eq 0 ]; then echo "Skipping Rust tests since no Rust files modified."; else ./test.sh $CARGOFLAGS; fi tags: - rust - rust-stable diff --git a/Cargo.lock b/Cargo.lock index 2430ad842..28d922178 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -29,7 +29,7 @@ dependencies = [ "fdlimit 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", "hyper 0.10.0-a.0 (git+https://github.com/ethcore/hyper)", "isatty 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", - "jsonrpc-core 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", + "jsonrpc-core 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", "log 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", "num_cpus 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)", "number_prefix 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)", @@ -448,8 +448,8 @@ dependencies = [ "fetch 0.1.0", "futures 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", "hyper 0.10.0-a.0 (git+https://github.com/ethcore/hyper)", - "jsonrpc-core 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", - "jsonrpc-http-server 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", + "jsonrpc-core 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", + "jsonrpc-http-server 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", "linked-hash-map 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", "mime 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", @@ -622,10 +622,10 @@ dependencies = [ "ethsync 1.6.0", "fetch 0.1.0", "futures 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", - "jsonrpc-core 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", - "jsonrpc-http-server 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", - "jsonrpc-ipc-server 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", - "jsonrpc-macros 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", + "jsonrpc-core 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", + "jsonrpc-http-server 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", + "jsonrpc-ipc-server 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", + "jsonrpc-macros 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", "log 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", "order-stat 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", "parity-reactor 0.1.0", @@ -668,7 +668,7 @@ dependencies = [ "ethcore-io 1.6.0", "ethcore-rpc 1.6.0", "ethcore-util 1.6.6", - "jsonrpc-core 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", + "jsonrpc-core 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", "log 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", "parity-dapps-glue 1.7.0 (registry+https://github.com/rust-lang/crates.io-index)", "parity-ui 1.6.0", @@ -688,9 +688,9 @@ dependencies = [ "ethcore-ipc-nano 1.6.0", "ethcore-util 1.6.6", "futures 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", - "jsonrpc-core 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", - "jsonrpc-macros 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", - "jsonrpc-tcp-server 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", + "jsonrpc-core 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", + "jsonrpc-macros 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", + "jsonrpc-tcp-server 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", "lazy_static 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", "mio 0.5.1 (git+https://github.com/ethcore/mio?branch=v0.5.x)", @@ -1086,7 +1086,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" [[package]] name = "jsonrpc-core" version = "6.0.0" -source = "git+https://github.com/ethcore/jsonrpc.git#86d7a89c85f324b5f6671315d9b71010ca995300" +source = "git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6#52062a2be5e45dfd7cece207fc3fd53fad434daf" dependencies = [ "futures 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1099,10 +1099,10 @@ dependencies = [ [[package]] name = "jsonrpc-http-server" version = "6.0.0" -source = "git+https://github.com/ethcore/jsonrpc.git#86d7a89c85f324b5f6671315d9b71010ca995300" +source = "git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6#52062a2be5e45dfd7cece207fc3fd53fad434daf" dependencies = [ "hyper 0.10.0-a.0 (git+https://github.com/ethcore/hyper)", - "jsonrpc-core 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", + "jsonrpc-core 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", "log 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", "tokio-core 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", "unicase 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1111,11 +1111,11 @@ dependencies = [ [[package]] name = "jsonrpc-ipc-server" version = "6.0.0" -source = "git+https://github.com/ethcore/jsonrpc.git#86d7a89c85f324b5f6671315d9b71010ca995300" +source = "git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6#52062a2be5e45dfd7cece207fc3fd53fad434daf" dependencies = [ "bytes 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)", "env_logger 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", - "jsonrpc-core 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", + "jsonrpc-core 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", "lazy_static 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", "mio 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1127,19 +1127,19 @@ dependencies = [ [[package]] name = "jsonrpc-macros" version = "6.0.0" -source = "git+https://github.com/ethcore/jsonrpc.git#86d7a89c85f324b5f6671315d9b71010ca995300" +source = "git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6#52062a2be5e45dfd7cece207fc3fd53fad434daf" dependencies = [ - "jsonrpc-core 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", + "jsonrpc-core 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", "serde 0.9.6 (registry+https://github.com/rust-lang/crates.io-index)", ] [[package]] name = "jsonrpc-tcp-server" version = "6.0.0" -source = "git+https://github.com/ethcore/jsonrpc.git#86d7a89c85f324b5f6671315d9b71010ca995300" +source = "git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6#52062a2be5e45dfd7cece207fc3fd53fad434daf" dependencies = [ "env_logger 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", - "jsonrpc-core 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", + "jsonrpc-core 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", "lazy_static 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", "rand 0.3.14 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1271,7 +1271,7 @@ dependencies = [ "log 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", "miow 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", "net2 0.2.23 (registry+https://github.com/rust-lang/crates.io-index)", - "nix 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", + "nix 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)", "slab 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", "time 0.1.35 (registry+https://github.com/rust-lang/crates.io-index)", "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1287,7 +1287,7 @@ dependencies = [ "log 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", "miow 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", "net2 0.2.23 (registry+https://github.com/rust-lang/crates.io-index)", - "nix 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", + "nix 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)", "slab 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", "time 0.1.35 (registry+https://github.com/rust-lang/crates.io-index)", "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1422,7 +1422,7 @@ dependencies = [ [[package]] name = "nix" -version = "0.5.0" +version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" dependencies = [ "bitflags 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1642,7 +1642,7 @@ dependencies = [ "ethcore 1.6.0", "ethcore-util 1.6.6", "hyper 0.10.0-a.0 (git+https://github.com/ethcore/hyper)", - "jsonrpc-http-server 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", + "jsonrpc-http-server 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", "mime 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", "multihash 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)", "rlp 0.1.0", @@ -1679,7 +1679,7 @@ dependencies = [ "ethcore-signer 1.6.0", "ethcore-util 1.6.6", "futures 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", - "jsonrpc-core 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)", + "jsonrpc-core 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)", "log 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", "rand 0.3.14 (registry+https://github.com/rust-lang/crates.io-index)", "serde 0.9.6 (registry+https://github.com/rust-lang/crates.io-index)", @@ -2663,11 +2663,11 @@ dependencies = [ "checksum isatty 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "7408a548dc0e406b7912d9f84c261cc533c1866e047644a811c133c56041ac0c" "checksum itertools 0.5.9 (registry+https://github.com/rust-lang/crates.io-index)" = "d95557e7ba6b71377b0f2c3b3ae96c53f1b75a926a6901a500f557a370af730a" "checksum itoa 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "91fd9dc2c587067de817fec4ad355e3818c3d893a78cab32a0a474c7a15bb8d5" -"checksum jsonrpc-core 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)" = "" -"checksum jsonrpc-http-server 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)" = "" -"checksum jsonrpc-ipc-server 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)" = "" -"checksum jsonrpc-macros 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)" = "" -"checksum jsonrpc-tcp-server 6.0.0 (git+https://github.com/ethcore/jsonrpc.git)" = "" +"checksum jsonrpc-core 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)" = "" +"checksum jsonrpc-http-server 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)" = "" +"checksum jsonrpc-ipc-server 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)" = "" +"checksum jsonrpc-macros 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)" = "" +"checksum jsonrpc-tcp-server 6.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.6)" = "" "checksum kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7507624b29483431c0ba2d82aece8ca6cdba9382bff4ddd0f7490560c056098d" "checksum language-tags 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "a91d884b6667cd606bb5a69aa0c99ba811a115fc68915e7056ec08a46e93199a" "checksum lazy_static 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "49247ec2a285bb3dcb23cbd9c35193c025e7251bfce77c1d5da97e6362dffe7f" @@ -2697,7 +2697,7 @@ dependencies = [ "checksum nanomsg-sys 0.5.0 (git+https://github.com/ethcore/nanomsg.rs.git?branch=parity-1.7)" = "" "checksum native-tls 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "aa4e52995154bb6f0b41e4379a279482c9387c1632e3798ba4e511ef8c54ee09" "checksum net2 0.2.23 (registry+https://github.com/rust-lang/crates.io-index)" = "6a816012ca11cb47009693c1e0c6130e26d39e4d97ee2a13c50e868ec83e3204" -"checksum nix 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)" = "f05c2fc965fc1cd6b73fa57fa7b89f288178737f2f3ce9e63e4a6a141189000e" +"checksum nix 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "bfb3ddedaa14746434a02041940495bf11325c22f6d36125d3bdd56090d50a79" "checksum nix 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7a7bb1da2be7da3cbffda73fc681d509ffd9e665af478d2bee1907cee0bc64b2" "checksum nix 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "a0d95c5fa8b641c10ad0b8887454ebaafa3c92b5cd5350f8fc693adafd178e7b" "checksum nodrop 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)" = "4d9a22dbcebdeef7bf275cbf444d6521d4e7a2fee187b72d80dba0817120dd8f" diff --git a/Cargo.toml b/Cargo.toml index ef73d6a8e..615534efc 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -25,7 +25,7 @@ app_dirs = "1.1.1" fdlimit = "0.1" hyper = { default-features = false, git = "https://github.com/ethcore/hyper" } ctrlc = { git = "https://github.com/ethcore/rust-ctrlc.git" } -jsonrpc-core = { git = "https://github.com/ethcore/jsonrpc.git" } +jsonrpc-core = { git = "https://github.com/paritytech/jsonrpc.git", branch = "parity-1.6" } ethsync = { path = "sync" } ethcore = { path = "ethcore" } ethcore-util = { path = "util" } diff --git a/dapps/Cargo.toml b/dapps/Cargo.toml index 4c7ce05e4..b5bfbcdbf 100644 --- a/dapps/Cargo.toml +++ b/dapps/Cargo.toml @@ -12,8 +12,8 @@ rand = "0.3" log = "0.3" env_logger = "0.3" futures = "0.1" -jsonrpc-core = { git = "https://github.com/ethcore/jsonrpc.git" } -jsonrpc-http-server = { git = "https://github.com/ethcore/jsonrpc.git" } +jsonrpc-core = { git = "https://github.com/paritytech/jsonrpc.git", branch = "parity-1.6" } +jsonrpc-http-server = { git = "https://github.com/paritytech/jsonrpc.git", branch = "parity-1.6" } hyper = { default-features = false, git = "https://github.com/ethcore/hyper" } unicase = "1.3" url = "1.0" diff --git a/ethcore/res/ethereum/tests b/ethcore/res/ethereum/tests index 9028c4801..ef191fdc6 160000 --- a/ethcore/res/ethereum/tests +++ b/ethcore/res/ethereum/tests @@ -1 +1 @@ -Subproject commit 9028c4801fd39fbb71a9796979182549a24e81c8 +Subproject commit ef191fdc61cf76cdb9cdc147465fb447304b0ed2 diff --git a/ethkey/src/brain.rs b/ethkey/src/brain.rs index 605c05f98..90410482e 100644 --- a/ethkey/src/brain.rs +++ b/ethkey/src/brain.rs @@ -57,8 +57,8 @@ mod tests { #[test] fn test_brain() { let words = "this is sparta!".to_owned(); - let first_keypair = Brain(words.clone()).generate().unwrap(); - let second_keypair = Brain(words.clone()).generate().unwrap(); + let first_keypair = Brain::new(words.clone()).generate().unwrap(); + let second_keypair = Brain::new(words.clone()).generate().unwrap(); assert_eq!(first_keypair.secret(), second_keypair.secret()); } } diff --git a/ipfs/Cargo.toml b/ipfs/Cargo.toml index 992ee0710..a41964cd4 100644 --- a/ipfs/Cargo.toml +++ b/ipfs/Cargo.toml @@ -8,7 +8,7 @@ authors = ["Parity Technologies "] [dependencies] ethcore = { path = "../ethcore" } ethcore-util = { path = "../util" } -jsonrpc-http-server = { git = "https://github.com/ethcore/jsonrpc.git" } +jsonrpc-http-server = { git = "https://github.com/paritytech/jsonrpc.git", branch = "parity-1.6" } rlp = { path = "../util/rlp" } mime = "0.2" hyper = { default-features = false, git = "https://github.com/ethcore/hyper" } diff --git a/rpc/Cargo.toml b/rpc/Cargo.toml index 91058b990..8a0a9e381 100644 --- a/rpc/Cargo.toml +++ b/rpc/Cargo.toml @@ -18,10 +18,10 @@ rustc-serialize = "0.3" time = "0.1" transient-hashmap = "0.1" order-stat = "0.1" -jsonrpc-core = { git = "https://github.com/ethcore/jsonrpc.git" } -jsonrpc-http-server = { git = "https://github.com/ethcore/jsonrpc.git" } -jsonrpc-ipc-server = { git = "https://github.com/ethcore/jsonrpc.git" } -jsonrpc-macros = { git = "https://github.com/ethcore/jsonrpc.git" } +jsonrpc-core = { git = "https://github.com/paritytech/jsonrpc.git", branch = "parity-1.6"} +jsonrpc-http-server = { git = "https://github.com/paritytech/jsonrpc.git", branch = "parity-1.6" } +jsonrpc-ipc-server = { git = "https://github.com/paritytech/jsonrpc.git", branch = "parity-1.6"} +jsonrpc-macros = { git = "https://github.com/paritytech/jsonrpc.git", branch = "parity-1.6" } ethcore-io = { path = "../util/io" } ethcore-ipc = { path = "../ipc/rpc" } ethcore-util = { path = "../util" } diff --git a/rpc/src/v1/helpers/dispatch.rs b/rpc/src/v1/helpers/dispatch.rs index 0bea7f9a1..b18152dc9 100644 --- a/rpc/src/v1/helpers/dispatch.rs +++ b/rpc/src/v1/helpers/dispatch.rs @@ -458,13 +458,10 @@ pub fn execute( message_data.append(&mut data); let res = signature(&accounts, address, message_data.sha3(), pass) .map(|result| result - .map(|rsv| { - let mut vrs = [0u8; 65]; - let rsv = rsv.as_ref(); - vrs[0] = rsv[64] + 27; - vrs[1..33].copy_from_slice(&rsv[0..32]); - vrs[33..65].copy_from_slice(&rsv[32..64]); - H520(vrs) + .map(|mut rsv| { + // Convert to electrum notation. + rsv[64] += 27; + H520(rsv.into()) }) .map(RpcH520::from) .map(ConfirmationResponse::Signature) diff --git a/rpc/src/v1/tests/mocked/eth.rs b/rpc/src/v1/tests/mocked/eth.rs index 2432b55e7..2732fe448 100644 --- a/rpc/src/v1/tests/mocked/eth.rs +++ b/rpc/src/v1/tests/mocked/eth.rs @@ -314,7 +314,7 @@ fn rpc_eth_sign() { ], "id": 1 }"#; - let res = r#"{"jsonrpc":"2.0","result":"0x1ba2870db1d0c26ef93c7b72d2a0830fa6b841e0593f7186bc6c7cc317af8cf3a42fda03bd589a49949aa05db83300cdb553116274518dbe9d90c65d0213f4af49","id":1}"#; + let res = r#"{"jsonrpc":"2.0","result":"0xa2870db1d0c26ef93c7b72d2a0830fa6b841e0593f7186bc6c7cc317af8cf3a42fda03bd589a49949aa05db83300cdb553116274518dbe9d90c65d0213f4af491b","id":1}"#; assert_eq!(tester.io.handle_request_sync(&req), Some(res.into())); } diff --git a/rpc/src/v1/tests/mocked/signing.rs b/rpc/src/v1/tests/mocked/signing.rs index 10611f139..c1646f344 100644 --- a/rpc/src/v1/tests/mocked/signing.rs +++ b/rpc/src/v1/tests/mocked/signing.rs @@ -212,7 +212,7 @@ fn should_sign_if_account_is_unlocked() { ], "id": 1 }"#; - let response = r#"{"jsonrpc":"2.0","result":"0x1bdb53b32e56cf3e9735377b7664d6de5a03e125b1bf8ec55715d253668b4238503b4ac931fe6af90add73e72a585e952665376b2b9afc5b6b239b7df74c734e12","id":1}"#; + let response = r#"{"jsonrpc":"2.0","result":"0xdb53b32e56cf3e9735377b7664d6de5a03e125b1bf8ec55715d253668b4238503b4ac931fe6af90add73e72a585e952665376b2b9afc5b6b239b7df74c734e121b","id":1}"#; assert_eq!(tester.io.handle_request_sync(&request), Some(response.to_owned())); assert_eq!(tester.signer.requests().len(), 0); } diff --git a/rpc_client/Cargo.toml b/rpc_client/Cargo.toml index 874d220ae..9ff21d876 100644 --- a/rpc_client/Cargo.toml +++ b/rpc_client/Cargo.toml @@ -14,7 +14,7 @@ serde = "0.9" serde_json = "0.9" tempdir = "0.3.5" url = "1.2.0" -jsonrpc-core = { git = "https://github.com/ethcore/jsonrpc.git" } +jsonrpc-core = { git = "https://github.com/paritytech/jsonrpc.git", branch = "parity-1.6" } ws = { git = "https://github.com/ethcore/ws-rs.git", branch = "mio-upstream-stable" } ethcore-rpc = { path = "../rpc" } ethcore-signer = { path = "../signer" } diff --git a/signer/Cargo.toml b/signer/Cargo.toml index 198999b8b..3ebc71c41 100644 --- a/signer/Cargo.toml +++ b/signer/Cargo.toml @@ -12,7 +12,7 @@ rustc_version = "0.1" [dependencies] rand = "0.3.14" -jsonrpc-core = { git = "https://github.com/ethcore/jsonrpc.git" } +jsonrpc-core = { git = "https://github.com/paritytech/jsonrpc.git", branch = "parity-1.6" } log = "0.3" env_logger = "0.3" parity-dapps-glue = { version = "1.7", optional = true } diff --git a/stratum/Cargo.toml b/stratum/Cargo.toml index 65b2c0e9c..1af70ca96 100644 --- a/stratum/Cargo.toml +++ b/stratum/Cargo.toml @@ -11,9 +11,9 @@ ethcore-ipc-codegen = { path = "../ipc/codegen" } [dependencies] log = "0.3" -jsonrpc-core = { git = "https://github.com/ethcore/jsonrpc.git" } -jsonrpc-macros = { git = "https://github.com/ethcore/jsonrpc.git" } -jsonrpc-tcp-server = { git = "https://github.com/ethcore/jsonrpc.git" } +jsonrpc-core = { git = "https://github.com/paritytech/jsonrpc.git", branch = "parity-1.6" } +jsonrpc-macros = { git = "https://github.com/paritytech/jsonrpc.git", branch = "parity-1.6" } +jsonrpc-tcp-server = { git = "https://github.com/paritytech/jsonrpc.git", branch = "parity-1.6" } mio = { git = "https://github.com/ethcore/mio", branch = "v0.5.x" } ethcore-util = { path = "../util" } ethcore-devtools = { path = "../devtools" }