diff --git a/.github/workflows/clippy-lint.yaml b/.github/workflows/clippy-lint.yaml index fa2c45fac..d33410bfc 100644 --- a/.github/workflows/clippy-lint.yaml +++ b/.github/workflows/clippy-lint.yaml @@ -35,8 +35,8 @@ jobs: - name: Run Clippy on different workspaces and crates run: | cargo clippy --manifest-path=benches/Cargo.toml -- -D warnings -A dead-code - cargo clippy --manifest-path=common/Cargo.toml -- -D warnings -A dead-code - cargo clippy --manifest-path=protocols/Cargo.toml -- -D warnings -A dead-code - cargo clippy --manifest-path=roles/Cargo.toml -- -D warnings -A dead-code + cargo clippy --manifest-path=stratum-common/Cargo.toml -- -D warnings -A dead-code + cargo clippy --manifest-path=stratum-protocols/Cargo.toml -- -D warnings -A dead-code + cargo clippy --manifest-path=stratum-roles/Cargo.toml -- -D warnings -A dead-code cargo clippy --manifest-path=utils/Cargo.toml -- -D warnings -A dead-code cargo clippy --manifest-path=utils/message-generator/Cargo.toml -- -D warnings -A dead-code diff --git a/.github/workflows/fmt.yaml b/.github/workflows/fmt.yaml index b0b3ecc18..25ebcfbdc 100644 --- a/.github/workflows/fmt.yaml +++ b/.github/workflows/fmt.yaml @@ -35,8 +35,8 @@ jobs: - name: Run fmt in different workspaces and crates run: | cargo fmt --all --manifest-path=benches/Cargo.toml -- --check - cargo fmt --all --manifest-path=common/Cargo.toml -- --check - cargo fmt --all --manifest-path=protocols/Cargo.toml -- --check - cargo fmt --all --manifest-path=roles/Cargo.toml -- --check + cargo fmt --all --manifest-path=stratum-common/Cargo.toml -- --check + cargo fmt --all --manifest-path=stratum-protocols/Cargo.toml -- --check + cargo fmt --all --manifest-path=stratum-roles/Cargo.toml -- --check cargo fmt --all --manifest-path=utils/Cargo.toml -- --check cargo fmt --all --manifest-path=utils/message-generator/Cargo.toml -- --check diff --git a/.github/workflows/release-libs.yaml b/.github/workflows/release-libs.yaml index 24e925196..1cdd9f0e6 100644 --- a/.github/workflows/release-libs.yaml +++ b/.github/workflows/release-libs.yaml @@ -42,77 +42,77 @@ jobs: - name: Publish crate no_serde_sv2_derive_codec continue-on-error: true run: | - cd protocols/v2/binary-sv2/no-serde-sv2/derive_codec + cd stratum-protocols/v2/binary-sv2/no-serde-sv2/derive_codec cargo publish - name: Publish crate no_serde_sv2_codec continue-on-error: true run: | - cd protocols/v2/binary-sv2/no-serde-sv2/codec + cd stratum-protocols/v2/binary-sv2/no-serde-sv2/codec cargo publish - name: Publish crate serde_sv2 continue-on-error: true run: | - cd protocols/v2/binary-sv2/serde-sv2 + cd stratum-protocols/v2/binary-sv2/serde-sv2 cargo publish - name: Publish crate binary_sv2 continue-on-error: true run: | - cd protocols/v2/binary-sv2/binary-sv2 + cd stratum-protocols/v2/binary-sv2/binary-sv2 cargo publish - name: Publish crate const_sv2 continue-on-error: true run: | - cd protocols/v2/const-sv2 + cd stratum-protocols/v2/const-sv2 cargo publish - name: Publish crate framing_sv2 continue-on-error: true run: | - cd protocols/v2/framing-sv2 + cd stratum-protocols/v2/framing-sv2 cargo publish - name: Publish crate noise_sv2 continue-on-error: true run: | - cd protocols/v2/noise-sv2 + cd stratum-protocols/v2/noise-sv2 cargo publish - name: Publish crate codec_sv2 continue-on-error: true run: | - cd protocols/v2/codec-sv2 + cd stratum-protocols/v2/codec-sv2 cargo publish - name: Publish crate common_messages continue-on-error: true run: | - cd protocols/v2/subprotocols/common-messages + cd stratum-protocols/v2/subprotocols/common-messages cargo publish - name: Publish crate job_declaration continue-on-error: true run: | - cd protocols/v2/subprotocols/job-declaration + cd stratum-protocols/v2/subprotocols/job-declaration cargo publish - name: Publish crate mining continue-on-error: true run: | - cd protocols/v2/subprotocols/mining + cd stratum-protocols/v2/subprotocols/mining cargo publish - name: Publish crate template_distribution continue-on-error: true run: | - cd protocols/v2/subprotocols/template-distribution + cd stratum-protocols/v2/subprotocols/template-distribution cargo publish - name: Publish crate sv2_ffi continue-on-error: true run: | - cd protocols/v2/sv2-ffi + cd stratum-protocols/v2/sv2-ffi cargo publish --all-features - name: Publish crate roles_logic_sv2 continue-on-error: true run: | - cd protocols/v2/roles-logic-sv2 + cd stratum-protocols/v2/roles-logic-sv2 cargo publish - name: Publish crate v1 continue-on-error: true run: | - cd protocols/v1 + cd stratum-protocols/v1 cargo publish - name: Publish crate bip32-key-derivation continue-on-error: true @@ -132,35 +132,35 @@ jobs: - name: Publish crate network_helpers_sv2 continue-on-error: true run: | - cd roles/roles-utils/network-helpers + cd stratum-roles/roles-utils/network-helpers cargo publish - name: Publish crate rpc_sv2 continue-on-error: true run: | - cd roles/roles-utils/rpc + cd stratum-roles/roles-utils/rpc cargo publish - name: Publish crate jd_client continue-on-error: true run: | - cd roles/jd-client + cd stratum-roles/jd-client cargo publish - name: Publish crate jd_server continue-on-error: true run: | - cd roles/jd-server + cd stratum-roles/jd-server cargo publish - name: Publish crate mining_proxy_sv2 continue-on-error: true run: | - cd roles/mining-proxy + cd stratum-roles/mining-proxy cargo publish - name: Publish crate pool_sv2 continue-on-error: true run: | - cd roles/pool + cd stratum-roles/pool cargo publish - name: Publish crate translator_sv2 continue-on-error: true run: | - cd roles/translator - cargo publish \ No newline at end of file + cd stratum-roles/translator + cargo publish diff --git a/.github/workflows/rust-msrv.yaml b/.github/workflows/rust-msrv.yaml index 3384e4a2f..c367adc69 100644 --- a/.github/workflows/rust-msrv.yaml +++ b/.github/workflows/rust-msrv.yaml @@ -30,8 +30,8 @@ jobs: - name: Build Benches run: cargo build --manifest-path=benches/Cargo.toml - name: Build Protocols - run: cargo build --manifest-path=protocols/Cargo.toml + run: cargo build --manifest-path=stratum-protocols/Cargo.toml - name: Build Roles - run: cargo build --manifest-path=roles/Cargo.toml + run: cargo build --manifest-path=stratum-roles/Cargo.toml - name: Build Utils run: cargo build --manifest-path=utils/Cargo.toml diff --git a/.github/workflows/semver-check.yaml b/.github/workflows/semver-check.yaml index 9a2a45ad3..4e4284140 100644 --- a/.github/workflows/semver-check.yaml +++ b/.github/workflows/semver-check.yaml @@ -54,60 +54,60 @@ jobs: working-directory: utils/buffer run: cargo semver-checks - - name: Run semver checks for protocols/v2/binary-sv2/no-serde-sv2/codec - working-directory: protocols/v2/binary-sv2/no-serde-sv2/codec + - name: Run semver checks for stratum-protocols/v2/binary-sv2/no-serde-sv2/codec + working-directory: stratum-protocols/v2/binary-sv2/no-serde-sv2/codec run: cargo semver-checks - - name: Run semver checks for protocols/v2/binary-sv2/serde-sv2 - working-directory: protocols/v2/binary-sv2/serde-sv2 + - name: Run semver checks for stratum-protocols/v2/binary-sv2/serde-sv2 + working-directory: stratum-protocols/v2/binary-sv2/serde-sv2 run: cargo semver-checks - - name: Run semver checks for protocols/v2/binary-sv2/binary-sv2 - working-directory: protocols/v2/binary-sv2/binary-sv2 + - name: Run semver checks for stratum-protocols/v2/binary-sv2/binary-sv2 + working-directory: stratum-protocols/v2/binary-sv2/binary-sv2 run: cargo semver-checks - - name: Run semver checks for protocols/v2/const-sv2 - working-directory: protocols/v2/const-sv2 + - name: Run semver checks for stratum-protocols/v2/const-sv2 + working-directory: stratum-protocols/v2/const-sv2 run: cargo semver-checks - - name: Run semver checks for protocols/v2/framing-sv2 - working-directory: protocols/v2/framing-sv2 + - name: Run semver checks for stratum-protocols/v2/framing-sv2 + working-directory: stratum-protocols/v2/framing-sv2 run: cargo semver-checks - - name: Run semver checks for protocols/v2/noise-sv2 - working-directory: protocols/v2/noise-sv2 + - name: Run semver checks for stratum-protocols/v2/noise-sv2 + working-directory: stratum-protocols/v2/noise-sv2 run: cargo semver-checks - - name: Run semver checks for protocols/v2/codec-sv2 - working-directory: protocols/v2/codec-sv2 + - name: Run semver checks for stratum-protocols/v2/codec-sv2 + working-directory: stratum-protocols/v2/codec-sv2 run: cargo semver-checks - - name: Run semver checks for protocols/v2/subprotocols/common-messages - working-directory: protocols/v2/subprotocols/common-messages + - name: Run semver checks for stratum-protocols/v2/subprotocols/common-messages + working-directory: stratum-protocols/v2/subprotocols/common-messages run: cargo semver-checks - - name: Run semver checks for protocols/v2/subprotocols/job-declaration - working-directory: protocols/v2/subprotocols/job-declaration + - name: Run semver checks for stratum-protocols/v2/subprotocols/job-declaration + working-directory: stratum-protocols/v2/subprotocols/job-declaration run: cargo semver-checks - - name: Run semver checks for protocols/v2/subprotocols/mining - working-directory: protocols/v2/subprotocols/mining + - name: Run semver checks for stratum-protocols/v2/subprotocols/mining + working-directory: stratum-protocols/v2/subprotocols/mining run: cargo semver-checks - - name: Run semver checks for protocols/v2/subprotocols/template-distribution - working-directory: protocols/v2/subprotocols/template-distribution + - name: Run semver checks for stratum-protocols/v2/subprotocols/template-distribution + working-directory: stratum-protocols/v2/subprotocols/template-distribution run: cargo semver-checks - - name: Run semver checks for protocols/v2/sv2-ffi - working-directory: protocols/v2/sv2-ffi + - name: Run semver checks for stratum-protocols/v2/sv2-ffi + working-directory: stratum-protocols/v2/sv2-ffi run: cargo semver-checks - - name: Run semver checks for protocols/v2/roles-logic-sv2 - working-directory: protocols/v2/roles-logic-sv2 + - name: Run semver checks for stratum-protocols/v2/roles-logic-sv2 + working-directory: stratum-protocols/v2/roles-logic-sv2 run: cargo semver-checks --default-features - - name: Run semver checks for protocols/v1 - working-directory: protocols/v1 + - name: Run semver checks for stratum-protocols/v1 + working-directory: stratum-protocols/v1 run: cargo semver-checks - name: Run semver checks for utils/bip32-key-derivation @@ -122,10 +122,10 @@ jobs: working-directory: utils/key-utils run: cargo semver-checks - - name: Run semver checks for roles/roles-utils/network-helpers - working-directory: roles/roles-utils/network-helpers + - name: Run semver checks for stratum-roles/roles-utils/network-helpers + working-directory: stratum-roles/roles-utils/network-helpers run: cargo semver-checks - - name: Run semver checks for roles/roles-utils/rpc - working-directory: roles/roles-utils/rpc - run: cargo semver-checks \ No newline at end of file + - name: Run semver checks for stratum-roles/roles-utils/rpc + working-directory: stratum-roles/roles-utils/rpc + run: cargo semver-checks diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 5b669ebc0..44fe711f3 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -35,9 +35,9 @@ jobs: - name: Build run: | cargo build --manifest-path=benches/Cargo.toml - cargo build --manifest-path=common/Cargo.toml - cargo build --manifest-path=protocols/Cargo.toml - cargo build --manifest-path=roles/Cargo.toml + cargo build --manifest-path=stratum-common/Cargo.toml + cargo build --manifest-path=stratum-protocols/Cargo.toml + cargo build --manifest-path=stratum-roles/Cargo.toml cargo build --manifest-path=utils/Cargo.toml - name: Run sv1-client-and-server example @@ -75,14 +75,14 @@ jobs: - name: Test run: | cargo test --manifest-path=benches/Cargo.toml - cargo test --manifest-path=common/Cargo.toml - cargo test --manifest-path=protocols/Cargo.toml - cargo test --manifest-path=roles/Cargo.toml + cargo test --manifest-path=stratum-common/Cargo.toml + cargo test --manifest-path=stratum-protocols/Cargo.toml + cargo test --manifest-path=stratum-roles/Cargo.toml cargo test --manifest-path=utils/Cargo.toml - name: Property based testing run: | - cargo test --manifest-path=protocols/Cargo.toml --features prop_test + cargo test --manifest-path=stratum-protocols/Cargo.toml --features prop_test - name: Run ping-pong-with-noise example run: | diff --git a/roles/Cargo.lock b/Cargo.lock similarity index 74% rename from roles/Cargo.lock rename to Cargo.lock index d46de28ea..0ccf8b498 100644 --- a/roles/Cargo.lock +++ b/Cargo.lock @@ -4,9 +4,9 @@ version = 3 [[package]] name = "addr2line" -version = "0.21.0" +version = "0.22.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a30b2e23b9e17a9f90641c7ab1549cd9b44f296d3ccbf309d2863cfe398a0cb" +checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" dependencies = [ "gimli", ] @@ -52,6 +52,12 @@ dependencies = [ "subtle", ] +[[package]] +name = "ahash" +version = "0.3.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e8fd72866655d1904d6b0997d0b07ba561047d070fbe29de039031c641b61217" + [[package]] name = "ahash" version = "0.7.8" @@ -72,11 +78,17 @@ dependencies = [ "memchr", ] +[[package]] +name = "anes" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4b46cbb362ab8752921c97e041f5e366ee6297bd428a31275b9fcf1e380f7299" + [[package]] name = "anstream" -version = "0.6.14" +version = "0.6.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" +checksum = "64e15c1ab1f89faffbf04a634d5e1962e9074f2741eef6d97f3c4e322426d526" dependencies = [ "anstyle", "anstyle-parse", @@ -89,33 +101,33 @@ dependencies = [ [[package]] name = "anstyle" -version = "1.0.7" +version = "1.0.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" +checksum = "1bec1de6f59aedf83baf9ff929c98f2ad654b97c9510f4e70cf6f661d49fd5b1" [[package]] name = "anstyle-parse" -version = "0.2.4" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" +checksum = "eb47de1e80c2b463c735db5b217a0ddc39d612e7ac9e2e96a5aed1f57616c1cb" dependencies = [ "utf8parse", ] [[package]] name = "anstyle-query" -version = "1.0.3" +version = "1.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a64c907d4e79225ac72e2a354c9ce84d50ebb4586dee56c82b3ee73004f537f5" +checksum = "6d36fc52c7f6c869915e99412912f22093507da8d9e942ceaf66fe4b7c14422a" dependencies = [ "windows-sys 0.52.0", ] [[package]] name = "anstyle-wincon" -version = "3.0.3" +version = "3.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" +checksum = "5bf74e1b6e971609db8ca7a9ce79fd5768ab6ae46441c572e46cf596f59e57f8" dependencies = [ "anstyle", "windows-sys 0.52.0", @@ -144,22 +156,21 @@ dependencies = [ [[package]] name = "async-channel" -version = "2.2.1" +version = "2.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "136d4d23bcc79e27423727b36823d86233aad06dfea531837b038394d11e9928" +checksum = "89b47800b0be77592da0afd425cc03468052844aff33b84e33cc696f64e77b6a" dependencies = [ "concurrent-queue", - "event-listener 5.3.0", - "event-listener-strategy 0.5.2", + "event-listener-strategy", "futures-core", "pin-project-lite", ] [[package]] name = "async-compat" -version = "0.2.3" +version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f68a707c1feb095d8c07f8a65b9f506b117d30af431cab89374357de7c11461b" +checksum = "7bab94bde396a3f7b4962e396fdad640e241ed797d4d8d77fc8c237d14c58fc0" dependencies = [ "futures-core", "futures-io", @@ -170,9 +181,9 @@ dependencies = [ [[package]] name = "async-executor" -version = "1.11.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b10202063978b3351199d68f8b22c4e47e4b1b822f8d43fd862d5ea8c006b29a" +checksum = "d7ebdfa2ebdab6b1760375fa7d6f382b9f486eac35fc994625a00e89280bdbb7" dependencies = [ "async-task", "concurrent-queue", @@ -187,10 +198,10 @@ version = "2.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "05b1b633a2115cd122d73b955eadd9916c18c8f510ec9cd1686404c60ad1c29c" dependencies = [ - "async-channel 2.2.1", + "async-channel 2.3.1", "async-executor", - "async-io 2.3.2", - "async-lock 3.3.0", + "async-io 2.3.4", + "async-lock 3.4.0", "blocking", "futures-lite 2.3.0", "once_cell", @@ -218,21 +229,21 @@ dependencies = [ [[package]] name = "async-io" -version = "2.3.2" +version = "2.3.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcccb0f599cfa2f8ace422d3555572f47424da5648a4382a9dd0310ff8210884" +checksum = "444b0228950ee6501b3568d3c93bf1176a1fdbc3b758dcd9475046d30f4dc7e8" dependencies = [ - "async-lock 3.3.0", + "async-lock 3.4.0", "cfg-if", "concurrent-queue", "futures-io", "futures-lite 2.3.0", "parking", - "polling 3.7.0", + "polling 3.7.3", "rustix 0.38.34", "slab", "tracing", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] @@ -246,12 +257,12 @@ dependencies = [ [[package]] name = "async-lock" -version = "3.3.0" +version = "3.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d034b430882f8381900d3fe6f0aaa3ad94f2cb4ac519b429692a1bc2dda4ae7b" +checksum = "ff6e472cdea888a4bd64f342f09b3f50e1886d32afe8df3d663c01140b811b18" dependencies = [ - "event-listener 4.0.3", - "event-listener-strategy 0.4.0", + "event-listener 5.3.1", + "event-listener-strategy", "pin-project-lite", ] @@ -274,7 +285,7 @@ checksum = "3b43422f69d8ff38f95f1b2bb76517c91589a924d1559a0e935d7c8ce0274c11" dependencies = [ "proc-macro2", "quote", - "syn 2.0.61", + "syn 2.0.75", ] [[package]] @@ -318,7 +329,7 @@ checksum = "6e0c28dcc82d7c8ead5cb13beb15405b57b8546e93215673ff8ca0349a028107" dependencies = [ "proc-macro2", "quote", - "syn 2.0.61", + "syn 2.0.75", ] [[package]] @@ -346,9 +357,9 @@ checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "backtrace" -version = "0.3.71" +version = "0.3.73" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26b05800d2e817c8b3b4b54abd461726265fa9789ae34330622f2db9ee696f9d" +checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" dependencies = [ "addr2line", "cc", @@ -365,22 +376,52 @@ version = "0.21.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567" +[[package]] +name = "bech32" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf9ff0bbfd639f15c74af777d81383cf53efb7c93613f6cab67c6c11e05bbf8b" + [[package]] name = "bech32" version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d86b93f97252c47b41663388e6d155714a9d0c398b99f1005cbc5f978b29f445" +[[package]] +name = "benchmark" +version = "1.0.0" +dependencies = [ + "async-channel 1.9.0", + "async-std", + "binary_sv2", + "bitcoin 0.28.2", + "codec_sv2", + "criterion 0.5.1", + "framing_sv2", + "iai", + "mining_sv2", + "network_helpers_sv2", + "num-bigint", + "num-traits", + "rand", + "roles_logic_sv2", + "serde", + "serde_json", + "sv1_api", +] + [[package]] name = "binary_codec_sv2" -version = "1.1.0" +version = "1.2.0" dependencies = [ "buffer_sv2", + "quickcheck", ] [[package]] name = "binary_sv2" -version = "1.1.0" +version = "1.2.0" dependencies = [ "binary_codec_sv2", "derive_codec_sv2", @@ -389,13 +430,24 @@ dependencies = [ "tracing", ] +[[package]] +name = "bitcoin" +version = "0.28.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4d30fb43d287492017964a1fd7d3f82e8cc760818471c6ef2d44111e317d5c3" +dependencies = [ + "bech32 0.8.1", + "bitcoin_hashes 0.10.0", + "secp256k1 0.22.2", +] + [[package]] name = "bitcoin" version = "0.29.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0694ea59225b0c5f3cb405ff3f670e4828358ed26aec49dc352f730f0cb1a8a3" dependencies = [ - "bech32", + "bech32 0.9.1", "bitcoin_hashes 0.11.0", "secp256k1 0.24.3", ] @@ -415,6 +467,12 @@ dependencies = [ "byteorder", ] +[[package]] +name = "bitcoin_hashes" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "006cc91e1a1d99819bc5b8214be3555c1f0611b169f527a1fdc54ed1f2b745b0" + [[package]] name = "bitcoin_hashes" version = "0.11.0" @@ -439,9 +497,9 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" dependencies = [ "serde", ] @@ -466,12 +524,11 @@ dependencies = [ [[package]] name = "blocking" -version = "1.6.0" +version = "1.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "495f7104e962b7356f0aeb34247aca1fe7d2e783b346582db7f2904cb5717e88" +checksum = "703f41c54fc768e63e091340b424302bb1c29ef4aa0c7f10fe849dfb114d29ea" dependencies = [ - "async-channel 2.2.1", - "async-lock 3.3.0", + "async-channel 2.3.1", "async-task", "futures-io", "futures-lite 2.3.0", @@ -492,6 +549,9 @@ name = "buffer_sv2" version = "1.1.0" dependencies = [ "aes-gcm", + "criterion 0.3.6", + "iai", + "rand", "serde", ] @@ -509,15 +569,24 @@ checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "bytes" -version = "1.6.0" +version = "1.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8318a53db07bb3f8dca91a600466bdb3f2eaadeedfdbcf02e1accbad9271ba50" + +[[package]] +name = "cast" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" +checksum = "37b2a672a2cb129a2e41c10b1224bb368f9f37a2b16b612598138befd7b37eb5" [[package]] name = "cc" -version = "1.0.97" +version = "1.1.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "099a5357d84c4c61eb35fc8eafa9a79a902c2f76911e5747ced4e032edd8d9b4" +checksum = "72db2f7947ecee9b03b510377e8bb9077afa27176fdbff55c51027e976fdcc48" +dependencies = [ + "shlex", +] [[package]] name = "cfg-if" @@ -549,6 +618,33 @@ dependencies = [ "zeroize", ] +[[package]] +name = "ciborium" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "42e69ffd6f0917f5c029256a24d0161db17cea3997d185db0d35926308770f0e" +dependencies = [ + "ciborium-io", + "ciborium-ll", + "serde", +] + +[[package]] +name = "ciborium-io" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05afea1e0a06c9be33d539b876f1ce3692f4afea2cb41f740e7743225ed1c757" + +[[package]] +name = "ciborium-ll" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57663b653d948a338bfb3eeba9bb2fd5fcfaecb9e199e87e1eda4d9e8b240fd9" +dependencies = [ + "ciborium-io", + "half 2.4.1", +] + [[package]] name = "cipher" version = "0.4.4" @@ -562,9 +658,20 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.4" +version = "2.34.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a0610544180c38b88101fecf2dd634b174a62eef6946f84dfc6a7127512b381c" +dependencies = [ + "bitflags 1.3.2", + "textwrap", + "unicode-width", +] + +[[package]] +name = "clap" +version = "4.5.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bc066a67923782aa8515dbaea16946c5bcc5addbd668bb80af688e53e548a0" +checksum = "ed6719fffa43d0d87e5fd8caeab59be1554fb028cd30edc88fc4369b17971019" dependencies = [ "clap_builder", "clap_derive", @@ -572,9 +679,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.2" +version = "4.5.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae129e2e766ae0ec03484e609954119f123cc1fe650337e155d03b022f24f7b4" +checksum = "216aec2b177652e3846684cbfe25c9964d18ec45234f0f5da5157b207ed1aab6" dependencies = [ "anstream", "anstyle", @@ -584,21 +691,21 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.5.4" +version = "4.5.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "528131438037fd55894f62d6e9f068b8f45ac57ffa77517819645d10aed04f64" +checksum = "501d359d5f3dcaf6ecdeee48833ae73ec6e42723a1e52419c79abf9507eec0a0" dependencies = [ "heck", "proc-macro2", "quote", - "syn 2.0.61", + "syn 2.0.75", ] [[package]] name = "clap_lex" -version = "0.7.0" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98cc8fbded0c607b7ba9dd60cd98df59af97e84d24e49c8557331cfc26d301ce" +checksum = "1462739cb27611015575c0c11df5df7601141071f07518d56fcc1be504cbec97" [[package]] name = "codec_sv2" @@ -615,9 +722,9 @@ dependencies = [ [[package]] name = "colorchoice" -version = "1.0.1" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" +checksum = "d3fd119d74b830634cea2a0f58bbd0d54540518a14397557951e79340abc28c0" [[package]] name = "common_messages_sv2" @@ -625,6 +732,10 @@ version = "2.0.0" dependencies = [ "binary_sv2", "const_sv2", + "quickcheck", + "quickcheck_macros", + "serde", + "serde_repr", ] [[package]] @@ -652,7 +763,7 @@ dependencies = [ "rust-ini", "serde", "serde_json", - "toml", + "toml 0.8.19", "yaml-rust", ] @@ -694,18 +805,109 @@ dependencies = [ [[package]] name = "cpufeatures" -version = "0.2.12" +version = "0.2.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" +checksum = "51e852e6dc9a5bed1fae92dd2375037bf2b768725bf3be87811edee3249d09ad" dependencies = [ "libc", ] +[[package]] +name = "criterion" +version = "0.3.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b01d6de93b2b6c65e17c634a26653a29d107b3c98c607c765bf38d041531cd8f" +dependencies = [ + "atty", + "cast", + "clap 2.34.0", + "criterion-plot 0.4.5", + "csv", + "itertools", + "lazy_static", + "num-traits", + "oorandom", + "plotters", + "rayon", + "regex", + "serde", + "serde_cbor", + "serde_derive", + "serde_json", + "tinytemplate", + "walkdir", +] + +[[package]] +name = "criterion" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f2b12d017a929603d80db1831cd3a24082f8137ce19c69e6447f54f5fc8d692f" +dependencies = [ + "anes", + "cast", + "ciborium", + "clap 4.5.16", + "criterion-plot 0.5.0", + "is-terminal", + "itertools", + "num-traits", + "once_cell", + "oorandom", + "plotters", + "rayon", + "regex", + "serde", + "serde_derive", + "serde_json", + "tinytemplate", + "walkdir", +] + +[[package]] +name = "criterion-plot" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2673cc8207403546f45f5fd319a974b1e6983ad1a3ee7e6041650013be041876" +dependencies = [ + "cast", + "itertools", +] + +[[package]] +name = "criterion-plot" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b50826342786a51a89e2da3a28f1c32b06e387201bc2d19791f622c673706b1" +dependencies = [ + "cast", + "itertools", +] + +[[package]] +name = "crossbeam-deque" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" +dependencies = [ + "crossbeam-epoch", + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-epoch" +version = "0.9.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" +dependencies = [ + "crossbeam-utils", +] + [[package]] name = "crossbeam-utils" -version = "0.8.19" +version = "0.8.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "248e3bacc7dc6baa3b21e405ee045c3047101a49145e7e9eca583ab4c2ca5345" +checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" [[package]] name = "crunchy" @@ -724,6 +926,27 @@ dependencies = [ "typenum", ] +[[package]] +name = "csv" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac574ff4d437a7b5ad237ef331c17ccca63c46479e5b5453eb8e10bb99a759fe" +dependencies = [ + "csv-core", + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "csv-core" +version = "0.1.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5efa2b3d7902f4b634a20cae3c9c4e6209dc4779feb6863329607560143efa70" +dependencies = [ + "memchr", +] + [[package]] name = "ctr" version = "0.9.2" @@ -735,7 +958,7 @@ dependencies = [ [[package]] name = "derive_codec_sv2" -version = "1.0.0" +version = "1.1.0" dependencies = [ "binary_codec_sv2", ] @@ -768,6 +991,12 @@ dependencies = [ "const-random", ] +[[package]] +name = "either" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" + [[package]] name = "env_logger" version = "0.7.1" @@ -781,6 +1010,16 @@ dependencies = [ "termcolor", ] +[[package]] +name = "env_logger" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a19187fea3ac7e84da7dacf48de0c45d63c6a76f9490dae389aead16c243fce3" +dependencies = [ + "log", + "regex", +] + [[package]] name = "equivalent" version = "1.0.1" @@ -789,9 +1028,9 @@ checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" [[package]] name = "errno" -version = "0.3.8" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a258e46cdc063eb8519c00b9fc845fc47bcfca4130e2f08e88665ceda8474245" +checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" dependencies = [ "libc", "windows-sys 0.52.0", @@ -809,43 +1048,22 @@ checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" [[package]] name = "event-listener" -version = "4.0.3" +version = "5.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67b215c49b2b248c855fb73579eb1f4f26c38ffdc12973e20e07b91d78d5646e" +checksum = "6032be9bd27023a771701cc49f9f053c751055f71efb2e0ae5c15809093675ba" dependencies = [ "concurrent-queue", "parking", "pin-project-lite", ] -[[package]] -name = "event-listener" -version = "5.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d9944b8ca13534cdfb2800775f8dd4902ff3fc75a50101466decadfdf322a24" -dependencies = [ - "concurrent-queue", - "parking", - "pin-project-lite", -] - -[[package]] -name = "event-listener-strategy" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "958e4d70b6d5e81971bebec42271ec641e7ff4e170a6fa605f2b8a8b65cb97d3" -dependencies = [ - "event-listener 4.0.3", - "pin-project-lite", -] - [[package]] name = "event-listener-strategy" version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0f214dc438f977e6d4e3500aaa277f5ad94ca83fbbd9b1a15713ce2344ccc5a1" dependencies = [ - "event-listener 5.3.0", + "event-listener 5.3.1", "pin-project-lite", ] @@ -964,7 +1182,7 @@ checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac" dependencies = [ "proc-macro2", "quote", - "syn 2.0.61", + "syn 2.0.75", ] [[package]] @@ -1030,9 +1248,9 @@ dependencies = [ [[package]] name = "gimli" -version = "0.28.1" +version = "0.29.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4271d37baee1b8c7e4b708028c57d816cf9d2434acb33a549475f78c181f6253" +checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" [[package]] name = "gloo-timers" @@ -1048,15 +1266,15 @@ dependencies = [ [[package]] name = "h2" -version = "0.4.4" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "816ec7294445779408f36fe57bc5b7fc1cf59664059096c65f905c1c61f58069" +checksum = "524e8ac6999421f49a846c2d4411f337e53497d8ec55d67753beffa43c5d9205" dependencies = [ + "atomic-waker", "bytes", "fnv", "futures-core", "futures-sink", - "futures-util", "http", "indexmap", "slab", @@ -1065,13 +1283,39 @@ dependencies = [ "tracing", ] +[[package]] +name = "half" +version = "1.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1b43ede17f21864e81be2fa654110bf1e793774238d86ef8555c37e6519c0403" + +[[package]] +name = "half" +version = "2.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6dd08c532ae367adf81c312a4580bc67f1d0fe8bc9c460520283f4c0ff277888" +dependencies = [ + "cfg-if", + "crunchy", +] + +[[package]] +name = "hashbrown" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96282e96bfcd3da0d3aa9938bedf1e50df3269b6db08b4876d2da0bb1a0841cf" +dependencies = [ + "ahash 0.3.8", + "autocfg", +] + [[package]] name = "hashbrown" version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ab5ef0d4909ef3724cc8cce6ccc8572c5c817592e9285f5464f8e86f8bd3726e" dependencies = [ - "ahash", + "ahash 0.7.8", "serde", ] @@ -1108,6 +1352,12 @@ version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" +[[package]] +name = "hermit-abi" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fbf6a919d6cf397374f7dfeeea91d974c7c0a7221d0d0f4f20d859d329e53fcc" + [[package]] name = "hex" version = "0.4.3" @@ -1116,9 +1366,9 @@ checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" [[package]] name = "hex-conservative" -version = "0.1.1" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30ed443af458ccb6d81c1e7e661545f94d3176752fb1df2f543b902a1e0f51e2" +checksum = "212ab92002354b4819390025006c897e8140934349e8635c9b077f47b4dcbd20" [[package]] name = "http" @@ -1133,9 +1383,9 @@ dependencies = [ [[package]] name = "http-body" -version = "1.0.0" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" +checksum = "1efedce1fb8e6913f23e0c92de8e62cd5b772a67e7b3946df930a62566c93184" dependencies = [ "bytes", "http", @@ -1143,12 +1393,12 @@ dependencies = [ [[package]] name = "http-body-util" -version = "0.1.1" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0475f8b2ac86659c21b64320d5d653f9efe42acd2a4e560073ec61a155a34f1d" +checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" dependencies = [ "bytes", - "futures-core", + "futures-util", "http", "http-body", "pin-project-lite", @@ -1156,9 +1406,9 @@ dependencies = [ [[package]] name = "httparse" -version = "1.8.0" +version = "1.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" +checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" [[package]] name = "httpdate" @@ -1177,9 +1427,9 @@ dependencies = [ [[package]] name = "hyper" -version = "1.3.1" +version = "1.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe575dd17d0862a9a33781c8c4696a55c320909004a67a00fb286ba8b1bc496d" +checksum = "50dfd22e0e76d0f662d429a5f80fcaf3855009297eab6a0a9f8543834744ba05" dependencies = [ "bytes", "futures-channel", @@ -1198,9 +1448,9 @@ dependencies = [ [[package]] name = "hyper-util" -version = "0.1.3" +version = "0.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca38ef113da30126bbff9cd1705f9273e15d45498615d138b0c20279ac7a76aa" +checksum = "cde7055719c54e36e95e8719f95883f22072a48ede39db7fc17a4e1d5281e9b9" dependencies = [ "bytes", "futures-channel", @@ -1216,11 +1466,17 @@ dependencies = [ "tracing", ] +[[package]] +name = "iai" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "71a816c97c42258aa5834d07590b718b4c9a598944cd39a52dc25b351185d678" + [[package]] name = "indexmap" -version = "2.2.6" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" +checksum = "93ead53efc7ea8ed3cfb0c79fc8023fbb782a5432b52830b6518941cebe6505c" dependencies = [ "equivalent", "hashbrown 0.14.5", @@ -1237,9 +1493,9 @@ dependencies = [ [[package]] name = "instant" -version = "0.1.12" +version = "0.1.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" +checksum = "e0242819d153cba4b4b05a5a8f2a7e9bbf97b6055b2a002b395c96b5ff3c0222" dependencies = [ "cfg-if", ] @@ -1255,11 +1511,31 @@ dependencies = [ "windows-sys 0.48.0", ] +[[package]] +name = "is-terminal" +version = "0.4.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "261f68e344040fbd0edea105bef17c66edf46f984ddb1115b775ce31be948f4b" +dependencies = [ + "hermit-abi 0.4.0", + "libc", + "windows-sys 0.52.0", +] + [[package]] name = "is_terminal_polyfill" -version = "1.70.0" +version = "1.70.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" +checksum = "7943c866cc5cd64cbc25b2e01621d07fa8eb2a1a23160ee81ce38704e97b8ecf" + +[[package]] +name = "itertools" +version = "0.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b0fd2260e829bddf4cb6ea802289de2f86d6a7a690192fbe91b3f46e0f2c8473" +dependencies = [ + "either", +] [[package]] name = "itoa" @@ -1325,13 +1601,14 @@ version = "1.0.0" dependencies = [ "binary_sv2", "const_sv2", + "serde", ] [[package]] name = "js-sys" -version = "0.3.69" +version = "0.3.70" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" +checksum = "1868808506b929d7b0cfa8f75951347aa71bb21144b7791bae35d9bccfcfe37a" dependencies = [ "wasm-bindgen", ] @@ -1354,6 +1631,7 @@ dependencies = [ "bs58", "secp256k1 0.28.2", "serde", + "toml 0.5.6", ] [[package]] @@ -1367,15 +1645,15 @@ dependencies = [ [[package]] name = "lazy_static" -version = "1.4.0" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" [[package]] name = "libc" -version = "0.2.154" +version = "0.2.158" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae743338b92ff9146ce83992f766a31066a91a8c84a45e0e9f21e7cf6de6d346" +checksum = "d8adc4bb1803a324070e64a98ae98f38934d91957a99cfb3a43dcbc01bc56439" [[package]] name = "linked-hash-map" @@ -1391,9 +1669,9 @@ checksum = "ef53942eb7bf7ff43a617b3e2c1c4a5ecf5944a7c1bc12d7ee39bbb15e5c1519" [[package]] name = "linux-raw-sys" -version = "0.4.13" +version = "0.4.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01cda141df6706de531b6c46c3a33ecca755538219bd484262fa09410c13539c" +checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" [[package]] name = "lock_api" @@ -1407,18 +1685,18 @@ dependencies = [ [[package]] name = "log" -version = "0.4.21" +version = "0.4.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" +checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" dependencies = [ "value-bag", ] [[package]] name = "memchr" -version = "2.7.2" +version = "2.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c8640c5d730cb13ebd907d8d04b52f55ac9a2eec55b440c8892f40d56c76c1d" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" [[package]] name = "minimal-lexical" @@ -1434,7 +1712,7 @@ dependencies = [ "async-recursion 0.3.2", "binary_sv2", "buffer_sv2", - "clap", + "clap 4.5.16", "codec_sv2", "const_sv2", "futures", @@ -1479,26 +1757,30 @@ version = "1.0.0" dependencies = [ "binary_sv2", "const_sv2", + "quickcheck", + "quickcheck_macros", + "serde", ] [[package]] name = "miniz_oxide" -version = "0.7.2" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d811f3e15f28568be3407c8e7fdb6514c1cda3cb30683f15b6a1a1dc4ea14a7" +checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" dependencies = [ "adler", ] [[package]] name = "mio" -version = "0.8.11" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" +checksum = "80e04d1dcff3aae0704555fe5fee3bcfaf3d1fdf8a7e521d5b9d2b42acb52cec" dependencies = [ + "hermit-abi 0.3.9", "libc", "wasi", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] @@ -1529,6 +1811,8 @@ dependencies = [ "aes-gcm", "chacha20poly1305", "const_sv2", + "quickcheck", + "quickcheck_macros", "rand", "rand_chacha", "secp256k1 0.28.2", @@ -1556,9 +1840,9 @@ dependencies = [ [[package]] name = "num-bigint" -version = "0.4.5" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" +checksum = "a5e44f723f1133c9deac646763579fdb3ac745e418f2a7af9cd0c431da1f20b9" dependencies = [ "num-integer", "num-traits", @@ -1582,21 +1866,11 @@ dependencies = [ "autocfg", ] -[[package]] -name = "num_cpus" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" -dependencies = [ - "hermit-abi 0.3.9", - "libc", -] - [[package]] name = "object" -version = "0.32.2" +version = "0.36.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6a622008b6e321afc04970976f62ee297fdbaa6f95318ca343e3eebb9648441" +checksum = "27b64972346851a39438c60b341ebc01bba47464ae329e55cf343eb93964efd9" dependencies = [ "memchr", ] @@ -1607,6 +1881,12 @@ version = "1.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" +[[package]] +name = "oorandom" +version = "11.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b410bbe7e14ab526a0e86877eb47c6996a2bd7746f027ba551028c925390e4e9" + [[package]] name = "opaque-debug" version = "0.3.1" @@ -1637,9 +1917,9 @@ checksum = "bb813b8af86854136c6922af0598d719255ecb2179515e6e7730d468f05c9cae" [[package]] name = "parking_lot" -version = "0.12.2" +version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e4af0ca4f6caed20e900d564c242b8e5d4903fdacf31d3daf527b66fe6f42fb" +checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" dependencies = [ "lock_api", "parking_lot_core", @@ -1655,7 +1935,7 @@ dependencies = [ "libc", "redox_syscall", "smallvec", - "windows-targets 0.52.5", + "windows-targets 0.52.6", ] [[package]] @@ -1695,7 +1975,7 @@ dependencies = [ "pest_meta", "proc-macro2", "quote", - "syn 2.0.61", + "syn 2.0.75", ] [[package]] @@ -1726,7 +2006,7 @@ checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" dependencies = [ "proc-macro2", "quote", - "syn 2.0.61", + "syn 2.0.75", ] [[package]] @@ -1743,15 +2023,43 @@ checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" [[package]] name = "piper" -version = "0.2.1" +version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "668d31b1c4eba19242f2088b2bf3316b82ca31082a8335764db4e083db7485d4" +checksum = "96c8c490f422ef9a4efd2cb5b42b76c8613d7e7dfc1caf667b8a3350a5acc066" dependencies = [ "atomic-waker", "fastrand 2.1.0", "futures-io", ] +[[package]] +name = "plotters" +version = "0.3.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a15b6eccb8484002195a3e44fe65a4ce8e93a625797a063735536fd59cb01cf3" +dependencies = [ + "num-traits", + "plotters-backend", + "plotters-svg", + "wasm-bindgen", + "web-sys", +] + +[[package]] +name = "plotters-backend" +version = "0.3.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "414cec62c6634ae900ea1c56128dfe87cf63e7caece0852ec76aba307cebadb7" + +[[package]] +name = "plotters-svg" +version = "0.3.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "81b30686a7d9c3e010b84284bdd26a29f2138574f52f5eb6f794fc0ad924e705" +dependencies = [ + "plotters-backend", +] + [[package]] name = "polling" version = "2.8.0" @@ -1770,17 +2078,17 @@ dependencies = [ [[package]] name = "polling" -version = "3.7.0" +version = "3.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "645493cf344456ef24219d02a768cf1fb92ddf8c92161679ae3d91b91a637be3" +checksum = "cc2790cd301dec6cd3b7a025e4815cf825724a51c98dccfe6a3e55f05ffb6511" dependencies = [ "cfg-if", "concurrent-queue", - "hermit-abi 0.3.9", + "hermit-abi 0.4.0", "pin-project-lite", "rustix 0.38.34", "tracing", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] @@ -1834,9 +2142,12 @@ dependencies = [ [[package]] name = "ppv-lite86" -version = "0.2.17" +version = "0.2.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" +checksum = "77957b295656769bb8ad2b6a6b09d897d94f05c41b069aede1fcdaa675eaea04" +dependencies = [ + "zerocopy", +] [[package]] name = "pretty_env_logger" @@ -1844,15 +2155,15 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "926d36b9553851b8b0005f1275891b392ee4d2d833852c417ed025477350fb9d" dependencies = [ - "env_logger", + "env_logger 0.7.1", "log", ] [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -1863,6 +2174,28 @@ version = "1.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a1d01941d82fa2ab50be1e79e6714289dd7cde78eba4c074bc5a4374f650dfe0" +[[package]] +name = "quickcheck" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "588f6378e4dd99458b60ec275b4477add41ce4fa9f64dcba6f15adccb19b50d6" +dependencies = [ + "env_logger 0.8.4", + "log", + "rand", +] + +[[package]] +name = "quickcheck_macros" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b22a693222d716a9587786f37ac3f6b4faedb5b80c23914e7303ff5a1d8016e9" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "quote" version = "1.0.36" @@ -1902,20 +2235,40 @@ dependencies = [ "getrandom", ] +[[package]] +name = "rayon" +version = "1.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b418a60154510ca1a002a752ca9714984e21e4241e804d32555251faf8b78ffa" +dependencies = [ + "either", + "rayon-core", +] + +[[package]] +name = "rayon-core" +version = "1.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1465873a3dfdaa8ae7cb14b4383657caab0b3e8a0aa9ae8e04b044854c8dfce2" +dependencies = [ + "crossbeam-deque", + "crossbeam-utils", +] + [[package]] name = "redox_syscall" -version = "0.5.1" +version = "0.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "469052894dcb553421e483e4209ee581a45100d31b4018de03e5a7ad86374a7e" +checksum = "2a908a6e00f1fdd0dfd9c0eb08ce85126f6d8bbda50017e74bc4a4b7d4a926a4" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", ] [[package]] name = "regex" -version = "1.10.4" +version = "1.10.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c117dbdfde9c8308975b6a18d71f3f385c89461f7b3fb054288ecf2a2058ba4c" +checksum = "4219d74c6b67a3654a9fbebc4b419e22126d13d2f3c4a07ee0cb61ff79a79619" dependencies = [ "aho-corasick", "memchr", @@ -1925,9 +2278,9 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.4.6" +version = "0.4.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86b83b8b9847f9bf95ef68afb0b8e6cdb80f498442f5179a29fad448fcc1eaea" +checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" dependencies = [ "aho-corasick", "memchr", @@ -1936,9 +2289,9 @@ dependencies = [ [[package]] name = "regex-syntax" -version = "0.8.3" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "adad44e29e4c806119491a7f06f03de4d1af22c3a680dd47f1e6e179439d1f56" +checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" [[package]] name = "roles_logic_sv2" @@ -1952,9 +2305,14 @@ dependencies = [ "job_declaration_sv2", "mining_sv2", "nohash-hasher", + "quickcheck", + "quickcheck_macros", + "rand", + "serde", "siphasher", "stratum-common", "template_distribution_sv2", + "toml 0.5.6", "tracing", ] @@ -1965,7 +2323,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b91f7eff05f748767f183df4320a63d6936e9c6107d97c9e6bdd9784f4289c94" dependencies = [ "base64", - "bitflags 2.5.0", + "bitflags 2.6.0", "serde", "serde_derive", ] @@ -2020,10 +2378,10 @@ version = "0.38.34" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "errno", "libc", - "linux-raw-sys 0.4.13", + "linux-raw-sys 0.4.14", "windows-sys 0.52.0", ] @@ -2033,12 +2391,30 @@ version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" +[[package]] +name = "same-file" +version = "1.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" +dependencies = [ + "winapi-util", +] + [[package]] name = "scopeguard" version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" +[[package]] +name = "secp256k1" +version = "0.22.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "295642060261c80709ac034f52fca8e5a9fa2c7d341ded5cdb164b7c33768b2a" +dependencies = [ + "secp256k1-sys 0.5.2", +] + [[package]] name = "secp256k1" version = "0.24.3" @@ -2060,6 +2436,15 @@ dependencies = [ "secp256k1-sys 0.9.2", ] +[[package]] +name = "secp256k1-sys" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "152e20a0fd0519390fc43ab404663af8a0b794273d2a91d60ad4a39f13ffe110" +dependencies = [ + "cc", +] + [[package]] name = "secp256k1-sys" version = "0.6.1" @@ -2080,35 +2465,57 @@ dependencies = [ [[package]] name = "serde" -version = "1.0.200" +version = "1.0.208" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ddc6f9cc94d67c0e21aaf7eda3a010fd3af78ebf6e096aa6e2e13c79749cce4f" +checksum = "cff085d2cb684faa248efb494c39b68e522822ac0de72ccf08109abde717cfb2" dependencies = [ "serde_derive", ] +[[package]] +name = "serde_cbor" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2bef2ebfde456fb76bbcf9f59315333decc4fda0b2b44b420243c11e0f5ec1f5" +dependencies = [ + "half 1.8.3", + "serde", +] + [[package]] name = "serde_derive" -version = "1.0.200" +version = "1.0.208" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "856f046b9400cee3c8c94ed572ecdb752444c24528c035cd35882aad6f492bcb" +checksum = "24008e81ff7613ed8e5ba0cfaf24e2c2f1e5b8a0495711e44fcd4882fca62bcf" dependencies = [ "proc-macro2", "quote", - "syn 2.0.61", + "syn 2.0.75", ] [[package]] name = "serde_json" -version = "1.0.116" +version = "1.0.125" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e17db7126d17feb94eb3fad46bf1a96b034e8aacbc2e775fe81505f8b0b2813" +checksum = "83c8e735a073ccf5be70aa8066aa984eaf2fa000db6c8d0100ae605b366d31ed" dependencies = [ "itoa", + "memchr", "ryu", "serde", ] +[[package]] +name = "serde_repr" +version = "0.1.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.75", +] + [[package]] name = "serde_spanned" version = "0.6.7" @@ -2159,6 +2566,12 @@ dependencies = [ "lazy_static", ] +[[package]] +name = "shlex" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" + [[package]] name = "signal-hook-registry" version = "1.4.2" @@ -2213,7 +2626,7 @@ dependencies = [ name = "stratum-common" version = "1.0.0" dependencies = [ - "bitcoin", + "bitcoin 0.29.2", "secp256k1 0.28.2", ] @@ -2225,9 +2638,9 @@ checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" [[package]] name = "subtle" -version = "2.5.0" +version = "2.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81cdd64d312baedb58e21336b31bc043b77e01cc99033ce76ef539f78e965ebc" +checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" [[package]] name = "sv1-mining-device" @@ -2254,11 +2667,26 @@ dependencies = [ "hex", "log", "pretty_env_logger", + "quickcheck", + "quickcheck_macros", "serde", "serde_json", "tracing", ] +[[package]] +name = "sv2_ffi" +version = "1.0.0" +dependencies = [ + "binary_sv2", + "codec_sv2", + "common_messages_sv2", + "const_sv2", + "quickcheck", + "quickcheck_macros", + "template_distribution_sv2", +] + [[package]] name = "syn" version = "1.0.109" @@ -2272,9 +2700,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.61" +version = "2.0.75" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "f6af063034fc1935ede7be0122941bafa9bacb949334d090b77ca98b5817c7d9" dependencies = [ "proc-macro2", "quote", @@ -2287,6 +2715,9 @@ version = "1.0.2" dependencies = [ "binary_sv2", "const_sv2", + "quickcheck", + "quickcheck_macros", + "serde", ] [[package]] @@ -2298,6 +2729,15 @@ dependencies = [ "winapi-util", ] +[[package]] +name = "textwrap" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d326610f408c7a4eb6f51c37c330e496b08506c9457c9d34287ecc38809fb060" +dependencies = [ + "unicode-width", +] + [[package]] name = "thiserror" version = "1.0.63" @@ -2315,7 +2755,7 @@ checksum = "a4558b58466b9ad7ca0f102865eccc95938dca1a74a856f2b57b6629050da261" dependencies = [ "proc-macro2", "quote", - "syn 2.0.61", + "syn 2.0.75", ] [[package]] @@ -2337,34 +2777,43 @@ dependencies = [ "crunchy", ] +[[package]] +name = "tinytemplate" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "be4d6b5f19ff7664e8c98d03e2139cb510db9b0a60b55f8e8709b689d939b6bc" +dependencies = [ + "serde", + "serde_json", +] + [[package]] name = "tokio" -version = "1.38.0" +version = "1.39.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba4f4a02a7a80d6f274636f0aa95c7e383b912d41fe721a31f29e29698585a4a" +checksum = "9babc99b9923bfa4804bd74722ff02c0381021eafa4db9949217e3be8e84fff5" dependencies = [ "backtrace", "bytes", "libc", "mio", - "num_cpus", "parking_lot", "pin-project-lite", "signal-hook-registry", "socket2 0.5.7", "tokio-macros", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] name = "tokio-macros" -version = "2.3.0" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" +checksum = "693d596312e88961bc67d7f1f97af8a70227d9f90c31bba5806eec004978d752" dependencies = [ "proc-macro2", "quote", - "syn 2.0.61", + "syn 2.0.75", ] [[package]] @@ -2380,6 +2829,15 @@ dependencies = [ "tokio", ] +[[package]] +name = "toml" +version = "0.5.6" +source = "git+https://github.com/diondokter/toml-rs?rev=c4161aa#c4161aa70202b3992dbec79b76e7a8659713b604" +dependencies = [ + "hashbrown 0.7.2", + "serde", +] + [[package]] name = "toml" version = "0.8.19" @@ -2427,20 +2885,19 @@ dependencies = [ "tokio", "tower-layer", "tower-service", - "tracing", ] [[package]] name = "tower-layer" -version = "0.3.2" +version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" +checksum = "121c2a6cda46980bb0fcd1647ffaf6cd3fc79a013de288782836f6df9c48780e" [[package]] name = "tower-service" -version = "0.3.2" +version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" +checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3" [[package]] name = "tracing" @@ -2448,7 +2905,6 @@ version = "0.1.40" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" dependencies = [ - "log", "pin-project-lite", "tracing-attributes", "tracing-core", @@ -2462,7 +2918,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.61", + "syn 2.0.75", ] [[package]] @@ -2561,6 +3017,12 @@ version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" +[[package]] +name = "unicode-width" +version = "0.1.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0336d538f7abc86d282a4189614dfaa90810dfc2c6f6427eaf88e16311dd225d" + [[package]] name = "universal-hash" version = "0.5.1" @@ -2573,9 +3035,9 @@ dependencies = [ [[package]] name = "utf8parse" -version = "0.2.1" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a" +checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "valuable" @@ -2591,15 +3053,25 @@ checksum = "5a84c137d37ab0142f0f2ddfe332651fdbf252e7b7dbb4e67b6c1f1b2e925101" [[package]] name = "version_check" -version = "0.9.4" +version = "0.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" +checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" [[package]] name = "waker-fn" -version = "1.1.1" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "317211a0dc0ceedd78fb2ca9a44aed3d7b9b26f81870d485c07122b4350673b7" + +[[package]] +name = "walkdir" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3c4517f54858c779bbcbf228f4fca63d121bf85fbecb2dc578cdf4a39395690" +checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" +dependencies = [ + "same-file", + "winapi-util", +] [[package]] name = "want" @@ -2618,34 +3090,35 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.92" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" +checksum = "a82edfc16a6c469f5f44dc7b571814045d60404b55a0ee849f9bcfa2e63dd9b5" dependencies = [ "cfg-if", + "once_cell", "wasm-bindgen-macro", ] [[package]] name = "wasm-bindgen-backend" -version = "0.2.92" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" +checksum = "9de396da306523044d3302746f1208fa71d7532227f15e347e2d93e4145dd77b" dependencies = [ "bumpalo", "log", "once_cell", "proc-macro2", "quote", - "syn 2.0.61", + "syn 2.0.75", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.42" +version = "0.4.43" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" +checksum = "61e9300f63a621e96ed275155c108eb6f843b6a26d053f122ab69724559dc8ed" dependencies = [ "cfg-if", "js-sys", @@ -2655,9 +3128,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.92" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" +checksum = "585c4c91a46b072c92e908d99cb1dcdf95c5218eeb6f3bf1efa991ee7a68cccf" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -2665,28 +3138,28 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.92" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" +checksum = "afc340c74d9005395cf9dd098506f7f44e38f2b4a21c6aaacf9a105ea5e1e836" dependencies = [ "proc-macro2", "quote", - "syn 2.0.61", + "syn 2.0.75", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.92" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" +checksum = "c62a0a307cb4a311d3a07867860911ca130c3494e8c2719593806c08bc5d0484" [[package]] name = "web-sys" -version = "0.3.69" +version = "0.3.70" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" +checksum = "26fdeaafd9bd129f65e7c031593c24d62186301e0c72c8978fa1678be7d532c0" dependencies = [ "js-sys", "wasm-bindgen", @@ -2710,11 +3183,11 @@ checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" [[package]] name = "winapi-util" -version = "0.1.8" +version = "0.1.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" +checksum = "cf221c93e13a30d793f7645a0e7762c55d169dbb0a49671918a2319d289b10bb" dependencies = [ - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] @@ -2738,7 +3211,16 @@ version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" dependencies = [ - "windows-targets 0.52.5", + "windows-targets 0.52.6", +] + +[[package]] +name = "windows-sys" +version = "0.59.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" +dependencies = [ + "windows-targets 0.52.6", ] [[package]] @@ -2758,18 +3240,18 @@ dependencies = [ [[package]] name = "windows-targets" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" +checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" dependencies = [ - "windows_aarch64_gnullvm 0.52.5", - "windows_aarch64_msvc 0.52.5", - "windows_i686_gnu 0.52.5", + "windows_aarch64_gnullvm 0.52.6", + "windows_aarch64_msvc 0.52.6", + "windows_i686_gnu 0.52.6", "windows_i686_gnullvm", - "windows_i686_msvc 0.52.5", - "windows_x86_64_gnu 0.52.5", - "windows_x86_64_gnullvm 0.52.5", - "windows_x86_64_msvc 0.52.5", + "windows_i686_msvc 0.52.6", + "windows_x86_64_gnu 0.52.6", + "windows_x86_64_gnullvm 0.52.6", + "windows_x86_64_msvc 0.52.6", ] [[package]] @@ -2780,9 +3262,9 @@ checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" [[package]] name = "windows_aarch64_gnullvm" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" +checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" [[package]] name = "windows_aarch64_msvc" @@ -2792,9 +3274,9 @@ checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" [[package]] name = "windows_aarch64_msvc" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" +checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" [[package]] name = "windows_i686_gnu" @@ -2804,15 +3286,15 @@ checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" [[package]] name = "windows_i686_gnu" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" +checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" [[package]] name = "windows_i686_gnullvm" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" +checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" [[package]] name = "windows_i686_msvc" @@ -2822,9 +3304,9 @@ checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" [[package]] name = "windows_i686_msvc" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" +checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" [[package]] name = "windows_x86_64_gnu" @@ -2834,9 +3316,9 @@ checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" [[package]] name = "windows_x86_64_gnu" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" +checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" [[package]] name = "windows_x86_64_gnullvm" @@ -2846,9 +3328,9 @@ checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" [[package]] name = "windows_x86_64_gnullvm" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" +checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" [[package]] name = "windows_x86_64_msvc" @@ -2858,9 +3340,9 @@ checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" [[package]] name = "windows_x86_64_msvc" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" +checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" [[package]] name = "winnow" @@ -2880,8 +3362,29 @@ dependencies = [ "linked-hash-map", ] +[[package]] +name = "zerocopy" +version = "0.7.35" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0" +dependencies = [ + "byteorder", + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.35" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.75", +] + [[package]] name = "zeroize" -version = "1.7.0" +version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "525b4ec142c6b68a2d10f01f7bbf6755599ca3f81ea53b8431b7dd348f5fdb2d" +checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" diff --git a/Cargo.toml b/Cargo.toml new file mode 100644 index 000000000..bc2ddc8a8 --- /dev/null +++ b/Cargo.toml @@ -0,0 +1,55 @@ +name = "stratum_v2" +version = "1.0.2" +authors = ["The Stratum v2 Developers"] +edition = "2021" +description = "" +documentation = "https://github.com/stratum-mining/stratum" +homepage = "https://stratumprotocol.org" +repository = "https://github.com/stratum-mining/stratum" +license = "MIT + Apache-2.0" +license-file = "LICENSE.md" +keywords = ["stratum", "mining", "bitcoin", "protocol"] + +[workspace] +resolver="2" +members = [ + # Protocol Crates + "stratum-protocols/v1", + "stratum-protocols/v2/binary-sv2/serde-sv2", + "stratum-protocols/v2/binary-sv2/no-serde-sv2/codec", + "stratum-protocols/v2/binary-sv2/no-serde-sv2/derive_codec", + "stratum-protocols/v2/binary-sv2/binary-sv2", + "stratum-protocols/v2/noise-sv2", + "stratum-protocols/v2/framing-sv2", + "stratum-protocols/v2/codec-sv2", + "stratum-protocols/v2/const-sv2", + "stratum-protocols/v2/subprotocols/common-messages", + "stratum-protocols/v2/subprotocols/template-distribution", + "stratum-protocols/v2/subprotocols/mining", + "stratum-protocols/v2/subprotocols/job-declaration", + "stratum-protocols/v2/sv2-ffi", + "stratum-protocols/v2/roles-logic-sv2", + + # Roles Crates + "stratum-roles/mining-proxy", + "stratum-roles/pool", + "stratum-roles/test-utils/mining-device", + "stratum-roles/test-utils/sv1-mining-device", + "stratum-roles/translator", + "stratum-roles/jd-client", + "stratum-roles/jd-server", + + # Common Functionality + "stratum-common", + + "benches", +] + +[profile.dev] +# Required by super_safe_lock +opt-level = 1 + +[profile.test] +# Required by super_safe_lock +opt-level = 1 + diff --git a/benches/Cargo.toml b/benches/Cargo.toml index 525c526e5..3fdb25407 100644 --- a/benches/Cargo.toml +++ b/benches/Cargo.toml @@ -7,19 +7,19 @@ edition = "2021" async-std={version = "1.10.0", features = ["attributes"]} criterion = "0.5.1" async-channel = "1.4.0" -v1 = { path="../protocols/v1", package="sv1_api", version = "^1.0.0" } +v1 = { path="../stratum-protocols/v1", package="sv1_api", version = "^1.0.0" } serde_json = { version = "1.0.64", default-features = false, features = ["alloc"] } iai="0.1" -mining_sv2 = { path = "../protocols/v2/subprotocols/mining", version = "^1.0.0" } -roles_logic_sv2 = { path = "../protocols/v2/roles-logic-sv2", version = "^1.0.0" } -framing_sv2 = { version = "2.0.0", path = "../protocols/v2/framing-sv2" } +mining_sv2 = { path = "../stratum-protocols/v2/subprotocols/mining", version = "^1.0.0" } +roles_logic_sv2 = { path = "../stratum-protocols/v2/roles-logic-sv2", version = "^1.0.0" } +framing_sv2 = { version = "2.0.0", path = "../stratum-protocols/v2/framing-sv2" } serde = { version = "1.0.89", default-features = false, features = ["derive", "alloc"] } num-bigint = "0.4.3" num-traits = "0.2.15" bitcoin="0.28.1" -codec_sv2 = { path = "../protocols/v2/codec-sv2", features=["noise_sv2"] } -binary_sv2 = { path = "../protocols/v2/binary-sv2/binary-sv2" } -network_helpers_sv2 = { path = "../roles/roles-utils/network-helpers", features=["async_std"] } +codec_sv2 = { path = "../stratum-protocols/v2/codec-sv2", features=["noise_sv2"] } +binary_sv2 = { path = "../stratum-protocols/v2/binary-sv2/binary-sv2" } +network_helpers_sv2 = { path = "../stratum-roles/roles-utils/network-helpers", features=["async_std"] } rand = "0.8.4" [[bench]] diff --git a/protocols/Cargo.toml b/protocols/Cargo.toml deleted file mode 100644 index d1f21ca36..000000000 --- a/protocols/Cargo.toml +++ /dev/null @@ -1,42 +0,0 @@ -name = "stratum_v2_protocols" -version = "1.0.0" -authors = ["The Stratum v2 Developers"] -edition = "2021" -description = "The Stratum protocol defines how miners, proxies, and pools communicate to contribute hashrate to the Bitcoin network. Stratum v2 is a robust set of primitives which anyone can use to expand the protocol or implement a role." -documentation = "https://github.com/stratum-mining/stratum" -readme = "README.md" -homepage = "https://stratumprotocol.org" -repository = "https://github.com/stratum-mining/stratum" -license = "MIT + Apache-2.0" -license-file = "LICENSE.md" -keywords = ["stratum", "mining", "bitcoin", "protocol"] - -[workspace] - -resolver="2" - -members = [ - "v1", - "v2/binary-sv2/serde-sv2", - "v2/binary-sv2/no-serde-sv2/codec", - "v2/binary-sv2/no-serde-sv2/derive_codec", - "v2/binary-sv2/binary-sv2", - "v2/noise-sv2", - "v2/framing-sv2", - "v2/codec-sv2", - "v2/const-sv2", - "v2/subprotocols/common-messages", - "v2/subprotocols/template-distribution", - "v2/subprotocols/mining", - "v2/subprotocols/job-declaration", - "v2/sv2-ffi", - "v2/roles-logic-sv2", -] - -[profile.dev] -# Required by super_safe_lock -opt-level = 1 - -[profile.test] -# Required by super_safe_lock -opt-level = 1 diff --git a/roles/Cargo.toml b/roles/Cargo.toml deleted file mode 100644 index 109cfd0ee..000000000 --- a/roles/Cargo.toml +++ /dev/null @@ -1,34 +0,0 @@ -name = "stratum_v2_roles" -version = "0.1.0" -authors = ["The Stratum v2 Developers"] -edition = "2021" -description = "The Stratum protocol defines how miners, proxies, and pools communicate to contribute hashrate to the Bitcoin network. Stratum v2 is a robust set of primitives which anyone can use to expand the protocol or implement a role." -documentation = "https://github.com/stratum-mining/stratum" -readme = "README.md" -homepage = "https://stratumprotocol.org" -repository = "https://github.com/stratum-mining/stratum" -license = "MIT + Apache-2.0" -license-file = "LICENSE.md" -keywords = ["stratum", "mining", "bitcoin", "protocol"] - -[workspace] - -resolver="2" - -members = [ - "mining-proxy", - "pool", - "test-utils/mining-device", - "test-utils/sv1-mining-device", - "translator", - "jd-client", - "jd-server", -] - -[profile.dev] -# Required by super_safe_lock -opt-level = 1 - -[profile.test] -# Required by super_safe_lock -opt-level = 1 diff --git a/common/Cargo.lock b/stratum-common/Cargo.lock similarity index 100% rename from common/Cargo.lock rename to stratum-common/Cargo.lock diff --git a/common/Cargo.toml b/stratum-common/Cargo.toml similarity index 100% rename from common/Cargo.toml rename to stratum-common/Cargo.toml diff --git a/common/src/lib.rs b/stratum-common/src/lib.rs similarity index 100% rename from common/src/lib.rs rename to stratum-common/src/lib.rs diff --git a/protocols/fuzz-tests/.gitignore b/stratum-protocols/fuzz-tests/.gitignore similarity index 100% rename from protocols/fuzz-tests/.gitignore rename to stratum-protocols/fuzz-tests/.gitignore diff --git a/protocols/Cargo.lock b/stratum-protocols/fuzz-tests/Cargo.lock similarity index 64% rename from protocols/Cargo.lock rename to stratum-protocols/fuzz-tests/Cargo.lock index 03934402e..454476f07 100644 --- a/protocols/Cargo.lock +++ b/stratum-protocols/fuzz-tests/Cargo.lock @@ -38,37 +38,26 @@ dependencies = [ ] [[package]] -name = "ahash" -version = "0.3.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8fd72866655d1904d6b0997d0b07ba561047d070fbe29de039031c641b61217" - -[[package]] -name = "aho-corasick" -version = "1.1.3" +name = "affinity" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" +checksum = "763e484feceb7dd021b21c5c6f81aee06b1594a743455ec7efbf72e6355e447b" dependencies = [ - "memchr", + "cfg-if", + "errno", + "libc", + "num_cpus", ] [[package]] -name = "atty" -version = "0.2.14" +name = "arbitrary" +version = "1.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9b39be18770d11421cdb1b9947a45dd3f37e93092cbf377614828a319d5fee8" +checksum = "7d5a26814d8dcb93b0e5a0ff3c6d80a8843bafb21b39e8e18a6f05471870e110" dependencies = [ - "hermit-abi", - "libc", - "winapi", + "derive_arbitrary", ] -[[package]] -name = "autocfg" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" - [[package]] name = "bech32" version = "0.9.1" @@ -89,8 +78,6 @@ version = "1.2.0" dependencies = [ "binary_codec_sv2", "derive_codec_sv2", - "serde", - "serde_sv2", "tracing", ] @@ -111,15 +98,6 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9425c3bf7089c983facbae04de54513cce73b41c7f9ff8c845b54e7bc64ebbfb" -[[package]] -name = "bitcoin_hashes" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b7a2e9773ee7ae7f2560f0426c938f57902dcb9e39321b0cbd608f47ed579a4" -dependencies = [ - "byteorder", -] - [[package]] name = "bitcoin_hashes" version = "0.11.0" @@ -141,7 +119,6 @@ name = "buffer_sv2" version = "1.1.0" dependencies = [ "aes-gcm", - "serde", ] [[package]] @@ -152,9 +129,14 @@ checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "cc" -version = "1.0.98" +version = "1.1.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41c270e7540d725e65ac7f1b212ac8ce349719624d7bcff99f8e2e488e8cf03f" +checksum = "72db2f7947ecee9b03b510377e8bb9077afa27176fdbff55c51027e976fdcc48" +dependencies = [ + "jobserver", + "libc", + "shlex", +] [[package]] name = "cfg-if" @@ -206,7 +188,6 @@ dependencies = [ "const_sv2", "framing_sv2", "noise_sv2", - "serde", "tracing", ] @@ -216,10 +197,6 @@ version = "2.0.0" dependencies = [ "binary_sv2", "const_sv2", - "quickcheck", - "quickcheck_macros", - "serde", - "serde_repr", ] [[package]] @@ -231,9 +208,9 @@ dependencies = [ [[package]] name = "cpufeatures" -version = "0.2.12" +version = "0.2.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" +checksum = "51e852e6dc9a5bed1fae92dd2375037bf2b768725bf3be87811edee3249d09ad" dependencies = [ "libc", ] @@ -259,33 +236,31 @@ dependencies = [ ] [[package]] -name = "derive_codec_sv2" -version = "1.1.0" +name = "derive_arbitrary" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" dependencies = [ - "binary_codec_sv2", + "proc-macro2", + "quote", + "syn", ] [[package]] -name = "env_logger" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44533bbbb3bb3c1fa17d9f2e4e38bbbaf8396ba82193c4cb1b6445d711445d36" +name = "derive_codec_sv2" +version = "1.1.0" dependencies = [ - "atty", - "humantime", - "log", - "regex", - "termcolor", + "binary_codec_sv2", ] [[package]] -name = "env_logger" -version = "0.8.4" +name = "errno" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a19187fea3ac7e84da7dacf48de0c45d63c6a76f9490dae389aead16c243fce3" +checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" dependencies = [ - "log", - "regex", + "libc", + "windows-sys", ] [[package]] @@ -293,9 +268,22 @@ name = "framing_sv2" version = "2.0.0" dependencies = [ "binary_sv2", - "buffer_sv2", "const_sv2", - "serde", +] + +[[package]] +name = "fuzz-tests" +version = "1.0.0" +dependencies = [ + "affinity", + "arbitrary", + "binary_codec_sv2", + "codec_sv2", + "lazy_static", + "libfuzzer-sys", + "rand", + "roles_logic_sv2", + "threadpool", ] [[package]] @@ -329,30 +317,11 @@ dependencies = [ "polyval", ] -[[package]] -name = "hashbrown" -version = "0.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96282e96bfcd3da0d3aa9938bedf1e50df3269b6db08b4876d2da0bb1a0841cf" -dependencies = [ - "ahash", - "autocfg", -] - [[package]] name = "hermit-abi" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33" -dependencies = [ - "libc", -] - -[[package]] -name = "hex" -version = "0.4.3" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" [[package]] name = "hex-conservative" @@ -360,15 +329,6 @@ version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "212ab92002354b4819390025006c897e8140934349e8635c9b077f47b4dcbd20" -[[package]] -name = "humantime" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df004cfca50ef23c36850aaaa59ad52cc70d0e90243c3c7737a4dd32dc7a3c4f" -dependencies = [ - "quick-error", -] - [[package]] name = "inout" version = "0.1.3" @@ -378,38 +338,45 @@ dependencies = [ "generic-array", ] -[[package]] -name = "itoa" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" - [[package]] name = "job_declaration_sv2" version = "1.0.0" dependencies = [ "binary_sv2", "const_sv2", - "serde", ] [[package]] -name = "libc" -version = "0.2.155" +name = "jobserver" +version = "0.1.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" +checksum = "48d1dbcbbeb6a7fec7e059840aa538bd62aaccf972c7346c4d9d2059312853d0" +dependencies = [ + "libc", +] + +[[package]] +name = "lazy_static" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" [[package]] -name = "log" -version = "0.4.21" +name = "libc" +version = "0.2.158" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" +checksum = "d8adc4bb1803a324070e64a98ae98f38934d91957a99cfb3a43dcbc01bc56439" [[package]] -name = "memchr" -version = "2.7.2" +name = "libfuzzer-sys" +version = "0.4.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c8640c5d730cb13ebd907d8d04b52f55ac9a2eec55b440c8892f40d56c76c1d" +checksum = "a96cfd5557eb82f2b83fed4955246c988d331975a002961b07c81584d107e7f7" +dependencies = [ + "arbitrary", + "cc", + "once_cell", +] [[package]] name = "mining_sv2" @@ -417,9 +384,6 @@ version = "1.0.0" dependencies = [ "binary_sv2", "const_sv2", - "quickcheck", - "quickcheck_macros", - "serde", ] [[package]] @@ -435,13 +399,21 @@ dependencies = [ "aes-gcm", "chacha20poly1305", "const_sv2", - "quickcheck", - "quickcheck_macros", "rand", "rand_chacha", "secp256k1 0.28.2", ] +[[package]] +name = "num_cpus" +version = "1.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" +dependencies = [ + "hermit-abi", + "libc", +] + [[package]] name = "once_cell" version = "1.19.0" @@ -485,57 +457,22 @@ dependencies = [ [[package]] name = "ppv-lite86" -version = "0.2.17" +version = "0.2.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[package]] -name = "pretty_env_logger" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "926d36b9553851b8b0005f1275891b392ee4d2d833852c417ed025477350fb9d" +checksum = "77957b295656769bb8ad2b6a6b09d897d94f05c41b069aede1fcdaa675eaea04" dependencies = [ - "env_logger 0.7.1", - "log", + "zerocopy", ] [[package]] name = "proc-macro2" -version = "1.0.85" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22244ce15aa966053a896d1accb3a6e68469b97c7f33f284b99f0d576879fc23" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] -[[package]] -name = "quick-error" -version = "1.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1d01941d82fa2ab50be1e79e6714289dd7cde78eba4c074bc5a4374f650dfe0" - -[[package]] -name = "quickcheck" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "588f6378e4dd99458b60ec275b4477add41ce4fa9f64dcba6f15adccb19b50d6" -dependencies = [ - "env_logger 0.8.4", - "log", - "rand", -] - -[[package]] -name = "quickcheck_macros" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b22a693222d716a9587786f37ac3f6b4faedb5b80c23914e7303ff5a1d8016e9" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - [[package]] name = "quote" version = "1.0.36" @@ -575,35 +512,6 @@ dependencies = [ "getrandom", ] -[[package]] -name = "regex" -version = "1.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c117dbdfde9c8308975b6a18d71f3f385c89461f7b3fb054288ecf2a2058ba4c" -dependencies = [ - "aho-corasick", - "memchr", - "regex-automata", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.4.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86b83b8b9847f9bf95ef68afb0b8e6cdb80f498442f5179a29fad448fcc1eaea" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.8.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "adad44e29e4c806119491a7f06f03de4d1af22c3a680dd47f1e6e179439d1f56" - [[package]] name = "roles_logic_sv2" version = "1.2.1" @@ -616,23 +524,12 @@ dependencies = [ "job_declaration_sv2", "mining_sv2", "nohash-hasher", - "quickcheck", - "quickcheck_macros", - "rand", - "serde", "siphasher", "stratum-common", "template_distribution_sv2", - "toml", "tracing", ] -[[package]] -name = "ryu" -version = "1.0.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" - [[package]] name = "secp256k1" version = "0.24.3" @@ -673,54 +570,10 @@ dependencies = [ ] [[package]] -name = "serde" -version = "1.0.203" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.203" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.66", -] - -[[package]] -name = "serde_json" -version = "1.0.117" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3" -dependencies = [ - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.19" +name = "shlex" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.66", -] - -[[package]] -name = "serde_sv2" -version = "1.0.1" -dependencies = [ - "buffer_sv2", - "serde", -] +checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" [[package]] name = "siphasher" @@ -738,56 +591,15 @@ dependencies = [ [[package]] name = "subtle" -version = "2.5.0" +version = "2.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81cdd64d312baedb58e21336b31bc043b77e01cc99033ce76ef539f78e965ebc" - -[[package]] -name = "sv1_api" -version = "1.0.1" -dependencies = [ - "binary_sv2", - "bitcoin_hashes 0.3.2", - "byteorder", - "hex", - "log", - "pretty_env_logger", - "quickcheck", - "quickcheck_macros", - "serde", - "serde_json", - "tracing", -] - -[[package]] -name = "sv2_ffi" -version = "1.0.0" -dependencies = [ - "binary_sv2", - "codec_sv2", - "common_messages_sv2", - "const_sv2", - "quickcheck", - "quickcheck_macros", - "template_distribution_sv2", -] - -[[package]] -name = "syn" -version = "1.0.109" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] +checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" [[package]] name = "syn" -version = "2.0.66" +version = "2.0.75" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c42f3f41a2de00b01c0aaad383c5a45241efc8b2d1eda5661812fda5f3cdcff5" +checksum = "f6af063034fc1935ede7be0122941bafa9bacb949334d090b77ca98b5817c7d9" dependencies = [ "proc-macro2", "quote", @@ -800,27 +612,15 @@ version = "1.0.2" dependencies = [ "binary_sv2", "const_sv2", - "quickcheck", - "quickcheck_macros", - "serde", ] [[package]] -name = "termcolor" -version = "1.4.1" +name = "threadpool" +version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06794f8f6c5c898b3275aebefa6b8a1cb24cd2c6c79397ab15774837a0bc5755" -dependencies = [ - "winapi-util", -] - -[[package]] -name = "toml" -version = "0.5.6" -source = "git+https://github.com/diondokter/toml-rs?rev=c4161aa#c4161aa70202b3992dbec79b76e7a8659713b604" +checksum = "d050e60b33d41c19108b32cea32164033a9013fe3b46cbd4457559bfbf77afaa" dependencies = [ - "hashbrown", - "serde", + "num_cpus", ] [[package]] @@ -842,7 +642,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.66", + "syn", ] [[package]] @@ -878,9 +678,9 @@ dependencies = [ [[package]] name = "version_check" -version = "0.9.4" +version = "0.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" +checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" [[package]] name = "wasi" @@ -888,37 +688,6 @@ version = "0.11.0+wasi-snapshot-preview1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" -[[package]] -name = "winapi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419" -dependencies = [ - "winapi-i686-pc-windows-gnu", - "winapi-x86_64-pc-windows-gnu", -] - -[[package]] -name = "winapi-i686-pc-windows-gnu" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" - -[[package]] -name = "winapi-util" -version = "0.1.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" -dependencies = [ - "windows-sys", -] - -[[package]] -name = "winapi-x86_64-pc-windows-gnu" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" - [[package]] name = "windows-sys" version = "0.52.0" @@ -930,9 +699,9 @@ dependencies = [ [[package]] name = "windows-targets" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" +checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" dependencies = [ "windows_aarch64_gnullvm", "windows_aarch64_msvc", @@ -946,51 +715,72 @@ dependencies = [ [[package]] name = "windows_aarch64_gnullvm" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" +checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" [[package]] name = "windows_aarch64_msvc" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" +checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" [[package]] name = "windows_i686_gnu" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" +checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" [[package]] name = "windows_i686_gnullvm" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" +checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" [[package]] name = "windows_i686_msvc" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" +checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" [[package]] name = "windows_x86_64_gnu" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" +checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" [[package]] name = "windows_x86_64_gnullvm" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" +checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" [[package]] name = "windows_x86_64_msvc" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" +checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" + +[[package]] +name = "zerocopy" +version = "0.7.35" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0" +dependencies = [ + "byteorder", + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.35" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] [[package]] name = "zeroize" diff --git a/protocols/fuzz-tests/Cargo.toml b/stratum-protocols/fuzz-tests/Cargo.toml similarity index 100% rename from protocols/fuzz-tests/Cargo.toml rename to stratum-protocols/fuzz-tests/Cargo.toml diff --git a/protocols/fuzz-tests/src/main.rs b/stratum-protocols/fuzz-tests/src/main.rs similarity index 100% rename from protocols/fuzz-tests/src/main.rs rename to stratum-protocols/fuzz-tests/src/main.rs diff --git a/protocols/tarpaulin.toml b/stratum-protocols/tarpaulin.toml similarity index 100% rename from protocols/tarpaulin.toml rename to stratum-protocols/tarpaulin.toml diff --git a/protocols/v1/Cargo.toml b/stratum-protocols/v1/Cargo.toml similarity index 100% rename from protocols/v1/Cargo.toml rename to stratum-protocols/v1/Cargo.toml diff --git a/protocols/v1/README.md b/stratum-protocols/v1/README.md similarity index 100% rename from protocols/v1/README.md rename to stratum-protocols/v1/README.md diff --git a/protocols/v1/src/error.rs b/stratum-protocols/v1/src/error.rs similarity index 100% rename from protocols/v1/src/error.rs rename to stratum-protocols/v1/src/error.rs diff --git a/protocols/v1/src/json_rpc.rs b/stratum-protocols/v1/src/json_rpc.rs similarity index 100% rename from protocols/v1/src/json_rpc.rs rename to stratum-protocols/v1/src/json_rpc.rs diff --git a/protocols/v1/src/lib.rs b/stratum-protocols/v1/src/lib.rs similarity index 100% rename from protocols/v1/src/lib.rs rename to stratum-protocols/v1/src/lib.rs diff --git a/protocols/v1/src/methods/client_to_server.rs b/stratum-protocols/v1/src/methods/client_to_server.rs similarity index 100% rename from protocols/v1/src/methods/client_to_server.rs rename to stratum-protocols/v1/src/methods/client_to_server.rs diff --git a/protocols/v1/src/methods/mod.rs b/stratum-protocols/v1/src/methods/mod.rs similarity index 100% rename from protocols/v1/src/methods/mod.rs rename to stratum-protocols/v1/src/methods/mod.rs diff --git a/protocols/v1/src/methods/server_to_client.rs b/stratum-protocols/v1/src/methods/server_to_client.rs similarity index 100% rename from protocols/v1/src/methods/server_to_client.rs rename to stratum-protocols/v1/src/methods/server_to_client.rs diff --git a/protocols/v1/src/utils.rs b/stratum-protocols/v1/src/utils.rs similarity index 100% rename from protocols/v1/src/utils.rs rename to stratum-protocols/v1/src/utils.rs diff --git a/protocols/v2/binary-sv2/binary-sv2/Cargo.toml b/stratum-protocols/v2/binary-sv2/binary-sv2/Cargo.toml similarity index 100% rename from protocols/v2/binary-sv2/binary-sv2/Cargo.toml rename to stratum-protocols/v2/binary-sv2/binary-sv2/Cargo.toml diff --git a/protocols/v2/binary-sv2/binary-sv2/README.md b/stratum-protocols/v2/binary-sv2/binary-sv2/README.md similarity index 100% rename from protocols/v2/binary-sv2/binary-sv2/README.md rename to stratum-protocols/v2/binary-sv2/binary-sv2/README.md diff --git a/protocols/v2/binary-sv2/binary-sv2/src/lib.rs b/stratum-protocols/v2/binary-sv2/binary-sv2/src/lib.rs similarity index 100% rename from protocols/v2/binary-sv2/binary-sv2/src/lib.rs rename to stratum-protocols/v2/binary-sv2/binary-sv2/src/lib.rs diff --git a/protocols/v2/binary-sv2/no-serde-sv2/codec/.gitignore b/stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/.gitignore similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/codec/.gitignore rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/.gitignore diff --git a/protocols/v2/binary-sv2/no-serde-sv2/codec/Cargo.toml b/stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/Cargo.toml similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/codec/Cargo.toml rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/Cargo.toml diff --git a/protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/decodable.rs b/stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/decodable.rs similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/decodable.rs rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/decodable.rs diff --git a/protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/encodable.rs b/stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/encodable.rs similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/encodable.rs rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/encodable.rs diff --git a/protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/impls.rs b/stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/impls.rs similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/impls.rs rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/impls.rs diff --git a/protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/mod.rs b/stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/mod.rs similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/mod.rs rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/codec/mod.rs diff --git a/protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/copy_data_types.rs b/stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/copy_data_types.rs similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/copy_data_types.rs rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/copy_data_types.rs diff --git a/protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/mod.rs b/stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/mod.rs similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/mod.rs rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/mod.rs diff --git a/protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/non_copy_data_types/inner.rs b/stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/non_copy_data_types/inner.rs similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/non_copy_data_types/inner.rs rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/non_copy_data_types/inner.rs diff --git a/protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/non_copy_data_types/mod.rs b/stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/non_copy_data_types/mod.rs similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/non_copy_data_types/mod.rs rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/non_copy_data_types/mod.rs diff --git a/protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/non_copy_data_types/seq_inner.rs b/stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/non_copy_data_types/seq_inner.rs similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/non_copy_data_types/seq_inner.rs rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/datatypes/non_copy_data_types/seq_inner.rs diff --git a/protocols/v2/binary-sv2/no-serde-sv2/codec/src/lib.rs b/stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/lib.rs similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/codec/src/lib.rs rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/codec/src/lib.rs diff --git a/protocols/v2/binary-sv2/no-serde-sv2/derive_codec/.gitignore b/stratum-protocols/v2/binary-sv2/no-serde-sv2/derive_codec/.gitignore similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/derive_codec/.gitignore rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/derive_codec/.gitignore diff --git a/protocols/v2/binary-sv2/no-serde-sv2/derive_codec/Cargo.lock b/stratum-protocols/v2/binary-sv2/no-serde-sv2/derive_codec/Cargo.lock similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/derive_codec/Cargo.lock rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/derive_codec/Cargo.lock diff --git a/protocols/v2/binary-sv2/no-serde-sv2/derive_codec/Cargo.toml b/stratum-protocols/v2/binary-sv2/no-serde-sv2/derive_codec/Cargo.toml similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/derive_codec/Cargo.toml rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/derive_codec/Cargo.toml diff --git a/protocols/v2/binary-sv2/no-serde-sv2/derive_codec/src/lib.rs b/stratum-protocols/v2/binary-sv2/no-serde-sv2/derive_codec/src/lib.rs similarity index 100% rename from protocols/v2/binary-sv2/no-serde-sv2/derive_codec/src/lib.rs rename to stratum-protocols/v2/binary-sv2/no-serde-sv2/derive_codec/src/lib.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/Cargo.toml b/stratum-protocols/v2/binary-sv2/serde-sv2/Cargo.toml similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/Cargo.toml rename to stratum-protocols/v2/binary-sv2/serde-sv2/Cargo.toml diff --git a/protocols/v2/binary-sv2/serde-sv2/src/de.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/de.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/de.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/de.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/error.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/error.rs similarity index 99% rename from protocols/v2/binary-sv2/serde-sv2/src/error.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/error.rs index 62da3c26d..afd2b7e2f 100644 --- a/protocols/v2/binary-sv2/serde-sv2/src/error.rs +++ b/stratum-protocols/v2/binary-sv2/serde-sv2/src/error.rs @@ -111,3 +111,5 @@ impl Display for Error { } } } + +impl std::error::Error for Error {} diff --git a/protocols/v2/binary-sv2/serde-sv2/src/lib.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/lib.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/lib.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/lib.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b016m.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b016m.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b016m.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b016m.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b0255.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b0255.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b0255.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b0255.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b032.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b032.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b032.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b032.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b064k.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b064k.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b064k.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/b064k.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/bytes.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/bytes.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/bytes.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/bytes.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/mod.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/mod.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/mod.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/byte_arrays/mod.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/primitives/mod.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/mod.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/primitives/mod.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/mod.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/mod.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/mod.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/mod.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/mod.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/option.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/option.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/option.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/option.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/seq0255.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/seq0255.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/seq0255.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/seq0255.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/seq064k.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/seq064k.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/seq064k.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/sequences/seq064k.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/primitives/short_tx_id.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/short_tx_id.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/primitives/short_tx_id.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/short_tx_id.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/primitives/signature.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/signature.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/primitives/signature.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/signature.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/primitives/u24.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/u24.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/primitives/u24.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/u24.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/primitives/u256.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/u256.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/primitives/u256.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/primitives/u256.rs diff --git a/protocols/v2/binary-sv2/serde-sv2/src/ser.rs b/stratum-protocols/v2/binary-sv2/serde-sv2/src/ser.rs similarity index 100% rename from protocols/v2/binary-sv2/serde-sv2/src/ser.rs rename to stratum-protocols/v2/binary-sv2/serde-sv2/src/ser.rs diff --git a/protocols/v2/codec-sv2/Cargo.toml b/stratum-protocols/v2/codec-sv2/Cargo.toml similarity index 61% rename from protocols/v2/codec-sv2/Cargo.toml rename to stratum-protocols/v2/codec-sv2/Cargo.toml index 20b0288af..608da1dcc 100644 --- a/protocols/v2/codec-sv2/Cargo.toml +++ b/stratum-protocols/v2/codec-sv2/Cargo.toml @@ -9,10 +9,10 @@ repository = "https://github.com/stratum-mining/stratum" [dependencies] serde = { version = "1.0.89", default-features = false, optional = true } -framing_sv2 = { version = "^2.0.0", path = "../../../protocols/v2/framing-sv2" } -noise_sv2 = { version = "1.0", path = "../../../protocols/v2/noise-sv2", optional=true} -binary_sv2 = { version = "1.0.0", path = "../../../protocols/v2/binary-sv2/binary-sv2" } -const_sv2 = { version = "2.0.0", path = "../../../protocols/v2/const-sv2"} +framing_sv2 = { version = "^2.0.0", path = "../../v2/framing-sv2" } +noise_sv2 = { version = "1.0", path = "../../v2/noise-sv2", optional=true} +binary_sv2 = { version = "1.0.0", path = "../..//v2/binary-sv2/binary-sv2" } +const_sv2 = { version = "2.0.0", path = "../..//v2/const-sv2"} buffer_sv2 = { version = "1.0.0", path = "../../../utils/buffer"} tracing = { version = "0.1"} @@ -21,4 +21,4 @@ tracing = { version = "0.1"} [features] with_serde = ["binary_sv2/with_serde", "serde", "framing_sv2/with_serde", "buffer_sv2/with_serde"] with_buffer_pool = ["framing_sv2/with_buffer_pool"] -no_std = [] \ No newline at end of file +no_std = [] diff --git a/protocols/v2/codec-sv2/src/decoder.rs b/stratum-protocols/v2/codec-sv2/src/decoder.rs similarity index 100% rename from protocols/v2/codec-sv2/src/decoder.rs rename to stratum-protocols/v2/codec-sv2/src/decoder.rs diff --git a/protocols/v2/codec-sv2/src/encoder.rs b/stratum-protocols/v2/codec-sv2/src/encoder.rs similarity index 100% rename from protocols/v2/codec-sv2/src/encoder.rs rename to stratum-protocols/v2/codec-sv2/src/encoder.rs diff --git a/protocols/v2/codec-sv2/src/error.rs b/stratum-protocols/v2/codec-sv2/src/error.rs similarity index 100% rename from protocols/v2/codec-sv2/src/error.rs rename to stratum-protocols/v2/codec-sv2/src/error.rs diff --git a/protocols/v2/codec-sv2/src/lib.rs b/stratum-protocols/v2/codec-sv2/src/lib.rs similarity index 100% rename from protocols/v2/codec-sv2/src/lib.rs rename to stratum-protocols/v2/codec-sv2/src/lib.rs diff --git a/protocols/v2/const-sv2/Cargo.toml b/stratum-protocols/v2/const-sv2/Cargo.toml similarity index 100% rename from protocols/v2/const-sv2/Cargo.toml rename to stratum-protocols/v2/const-sv2/Cargo.toml diff --git a/protocols/v2/const-sv2/src/lib.rs b/stratum-protocols/v2/const-sv2/src/lib.rs similarity index 100% rename from protocols/v2/const-sv2/src/lib.rs rename to stratum-protocols/v2/const-sv2/src/lib.rs diff --git a/protocols/v2/framing-sv2/Cargo.toml b/stratum-protocols/v2/framing-sv2/Cargo.toml similarity index 79% rename from protocols/v2/framing-sv2/Cargo.toml rename to stratum-protocols/v2/framing-sv2/Cargo.toml index 4450a4653..fba8ff694 100644 --- a/protocols/v2/framing-sv2/Cargo.toml +++ b/stratum-protocols/v2/framing-sv2/Cargo.toml @@ -12,8 +12,8 @@ repository = "https://github.com/stratum-mining/stratum" [dependencies] serde = { version = "1.0.89", default-features = false, optional = true } -const_sv2 = { version = "^2.0.0", path = "../../../protocols/v2/const-sv2"} -binary_sv2 = { version = "^1.0.0", path = "../../../protocols/v2/binary-sv2/binary-sv2" } +const_sv2 = { version = "^2.0.0", path = "../../v2/const-sv2"} +binary_sv2 = { version = "^1.0.0", path = "../../v2/binary-sv2/binary-sv2" } buffer_sv2 = { version = "^1.0.0", path = "../../../utils/buffer", optional=true } [features] diff --git a/protocols/v2/framing-sv2/src/error.rs b/stratum-protocols/v2/framing-sv2/src/error.rs similarity index 100% rename from protocols/v2/framing-sv2/src/error.rs rename to stratum-protocols/v2/framing-sv2/src/error.rs diff --git a/protocols/v2/framing-sv2/src/framing.rs b/stratum-protocols/v2/framing-sv2/src/framing.rs similarity index 100% rename from protocols/v2/framing-sv2/src/framing.rs rename to stratum-protocols/v2/framing-sv2/src/framing.rs diff --git a/protocols/v2/framing-sv2/src/header.rs b/stratum-protocols/v2/framing-sv2/src/header.rs similarity index 100% rename from protocols/v2/framing-sv2/src/header.rs rename to stratum-protocols/v2/framing-sv2/src/header.rs diff --git a/protocols/v2/framing-sv2/src/lib.rs b/stratum-protocols/v2/framing-sv2/src/lib.rs similarity index 100% rename from protocols/v2/framing-sv2/src/lib.rs rename to stratum-protocols/v2/framing-sv2/src/lib.rs diff --git a/protocols/v2/noise-sv2/Cargo.toml b/stratum-protocols/v2/noise-sv2/Cargo.toml similarity index 87% rename from protocols/v2/noise-sv2/Cargo.toml rename to stratum-protocols/v2/noise-sv2/Cargo.toml index c627bc1af..ca82c8024 100644 --- a/protocols/v2/noise-sv2/Cargo.toml +++ b/stratum-protocols/v2/noise-sv2/Cargo.toml @@ -13,7 +13,7 @@ rand = {version = "0.8.5", default-features = false, features = ["std","std_rng" aes-gcm = "0.10.2" chacha20poly1305 = "0.10.1" rand_chacha = "0.3.1" -const_sv2 = { version = "^2.0.0", path = "../../../protocols/v2/const-sv2"} +const_sv2 = { version = "^2.0.0", path = "../../v2/const-sv2"} [dev-dependencies] quickcheck = "1.0.3" diff --git a/protocols/v2/noise-sv2/src/aed_cipher.rs b/stratum-protocols/v2/noise-sv2/src/aed_cipher.rs similarity index 100% rename from protocols/v2/noise-sv2/src/aed_cipher.rs rename to stratum-protocols/v2/noise-sv2/src/aed_cipher.rs diff --git a/protocols/v2/noise-sv2/src/cipher_state.rs b/stratum-protocols/v2/noise-sv2/src/cipher_state.rs similarity index 100% rename from protocols/v2/noise-sv2/src/cipher_state.rs rename to stratum-protocols/v2/noise-sv2/src/cipher_state.rs diff --git a/protocols/v2/noise-sv2/src/error.rs b/stratum-protocols/v2/noise-sv2/src/error.rs similarity index 100% rename from protocols/v2/noise-sv2/src/error.rs rename to stratum-protocols/v2/noise-sv2/src/error.rs diff --git a/protocols/v2/noise-sv2/src/handshake.rs b/stratum-protocols/v2/noise-sv2/src/handshake.rs similarity index 100% rename from protocols/v2/noise-sv2/src/handshake.rs rename to stratum-protocols/v2/noise-sv2/src/handshake.rs diff --git a/protocols/v2/noise-sv2/src/initiator.rs b/stratum-protocols/v2/noise-sv2/src/initiator.rs similarity index 100% rename from protocols/v2/noise-sv2/src/initiator.rs rename to stratum-protocols/v2/noise-sv2/src/initiator.rs diff --git a/protocols/v2/noise-sv2/src/lib.rs b/stratum-protocols/v2/noise-sv2/src/lib.rs similarity index 100% rename from protocols/v2/noise-sv2/src/lib.rs rename to stratum-protocols/v2/noise-sv2/src/lib.rs diff --git a/protocols/v2/noise-sv2/src/responder.rs b/stratum-protocols/v2/noise-sv2/src/responder.rs similarity index 100% rename from protocols/v2/noise-sv2/src/responder.rs rename to stratum-protocols/v2/noise-sv2/src/responder.rs diff --git a/protocols/v2/noise-sv2/src/signature_message.rs b/stratum-protocols/v2/noise-sv2/src/signature_message.rs similarity index 100% rename from protocols/v2/noise-sv2/src/signature_message.rs rename to stratum-protocols/v2/noise-sv2/src/signature_message.rs diff --git a/protocols/v2/noise-sv2/src/test.rs b/stratum-protocols/v2/noise-sv2/src/test.rs similarity index 100% rename from protocols/v2/noise-sv2/src/test.rs rename to stratum-protocols/v2/noise-sv2/src/test.rs diff --git a/protocols/v2/roles-logic-sv2/Cargo.toml b/stratum-protocols/v2/roles-logic-sv2/Cargo.toml similarity index 58% rename from protocols/v2/roles-logic-sv2/Cargo.toml rename to stratum-protocols/v2/roles-logic-sv2/Cargo.toml index 2b7c34610..8ce80595a 100644 --- a/protocols/v2/roles-logic-sv2/Cargo.toml +++ b/stratum-protocols/v2/roles-logic-sv2/Cargo.toml @@ -9,15 +9,15 @@ repository = "https://github.com/stratum-mining/stratum" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -stratum-common = { version="1.0.0", path = "../../../common", features=["bitcoin"]} +stratum-common = { version="1.0.0", path = "../../../stratum-common", features=["bitcoin"]} serde = { version = "1.0.89", features = ["derive", "alloc"], default-features = false, optional = true} -binary_sv2 = {version = "^1.0.0", path = "../../../protocols/v2/binary-sv2/binary-sv2", default-features = true } -common_messages_sv2 = { path = "../../../protocols/v2/subprotocols/common-messages", version = "^2.0.0" } -mining_sv2 = { path = "../../../protocols/v2/subprotocols/mining", version = "^1.0.0" } -template_distribution_sv2 = { path = "../../../protocols/v2/subprotocols/template-distribution", version = "^1.0.1" } -job_declaration_sv2 = { path = "../../../protocols/v2/subprotocols/job-declaration", version = "^1.0.0" } -const_sv2 = { version = "^2.0.0", path = "../../../protocols/v2/const-sv2"} -framing_sv2 = { version = "^2.0.0", path = "../../../protocols/v2/framing-sv2" } +binary_sv2 = {version = "^1.0.0", path = "../../v2/binary-sv2/binary-sv2", default-features = true } +common_messages_sv2 = { path = "../../v2/subprotocols/common-messages", version = "^2.0.0" } +mining_sv2 = { path = "../../v2/subprotocols/mining", version = "^1.0.0" } +template_distribution_sv2 = { path = "../../v2/subprotocols/template-distribution", version = "^1.0.1" } +job_declaration_sv2 = { path = "../../v2/subprotocols/job-declaration", version = "^1.0.0" } +const_sv2 = { version = "^2.0.0", path = "../../v2/const-sv2"} +framing_sv2 = { version = "^2.0.0", path = "../../v2/framing-sv2" } tracing = { version = "0.1"} chacha20poly1305 = { version = "0.10.1"} nohash-hasher = "0.2.0" diff --git a/protocols/v2/roles-logic-sv2/src/channel_logic/channel_factory.rs b/stratum-protocols/v2/roles-logic-sv2/src/channel_logic/channel_factory.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/channel_logic/channel_factory.rs rename to stratum-protocols/v2/roles-logic-sv2/src/channel_logic/channel_factory.rs diff --git a/protocols/v2/roles-logic-sv2/src/channel_logic/mod.rs b/stratum-protocols/v2/roles-logic-sv2/src/channel_logic/mod.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/channel_logic/mod.rs rename to stratum-protocols/v2/roles-logic-sv2/src/channel_logic/mod.rs diff --git a/protocols/v2/roles-logic-sv2/src/channel_logic/proxy_group_channel.rs b/stratum-protocols/v2/roles-logic-sv2/src/channel_logic/proxy_group_channel.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/channel_logic/proxy_group_channel.rs rename to stratum-protocols/v2/roles-logic-sv2/src/channel_logic/proxy_group_channel.rs diff --git a/protocols/v2/roles-logic-sv2/src/common_properties.rs b/stratum-protocols/v2/roles-logic-sv2/src/common_properties.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/common_properties.rs rename to stratum-protocols/v2/roles-logic-sv2/src/common_properties.rs diff --git a/protocols/v2/roles-logic-sv2/src/errors.rs b/stratum-protocols/v2/roles-logic-sv2/src/errors.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/errors.rs rename to stratum-protocols/v2/roles-logic-sv2/src/errors.rs diff --git a/protocols/v2/roles-logic-sv2/src/handlers/common.rs b/stratum-protocols/v2/roles-logic-sv2/src/handlers/common.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/handlers/common.rs rename to stratum-protocols/v2/roles-logic-sv2/src/handlers/common.rs diff --git a/protocols/v2/roles-logic-sv2/src/handlers/job_declaration.rs b/stratum-protocols/v2/roles-logic-sv2/src/handlers/job_declaration.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/handlers/job_declaration.rs rename to stratum-protocols/v2/roles-logic-sv2/src/handlers/job_declaration.rs diff --git a/protocols/v2/roles-logic-sv2/src/handlers/mining.rs b/stratum-protocols/v2/roles-logic-sv2/src/handlers/mining.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/handlers/mining.rs rename to stratum-protocols/v2/roles-logic-sv2/src/handlers/mining.rs diff --git a/protocols/v2/roles-logic-sv2/src/handlers/mod.rs b/stratum-protocols/v2/roles-logic-sv2/src/handlers/mod.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/handlers/mod.rs rename to stratum-protocols/v2/roles-logic-sv2/src/handlers/mod.rs diff --git a/protocols/v2/roles-logic-sv2/src/handlers/template_distribution.rs b/stratum-protocols/v2/roles-logic-sv2/src/handlers/template_distribution.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/handlers/template_distribution.rs rename to stratum-protocols/v2/roles-logic-sv2/src/handlers/template_distribution.rs diff --git a/protocols/v2/roles-logic-sv2/src/job_creator.rs b/stratum-protocols/v2/roles-logic-sv2/src/job_creator.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/job_creator.rs rename to stratum-protocols/v2/roles-logic-sv2/src/job_creator.rs diff --git a/protocols/v2/roles-logic-sv2/src/job_dispatcher.rs b/stratum-protocols/v2/roles-logic-sv2/src/job_dispatcher.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/job_dispatcher.rs rename to stratum-protocols/v2/roles-logic-sv2/src/job_dispatcher.rs diff --git a/protocols/v2/roles-logic-sv2/src/lib.rs b/stratum-protocols/v2/roles-logic-sv2/src/lib.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/lib.rs rename to stratum-protocols/v2/roles-logic-sv2/src/lib.rs diff --git a/protocols/v2/roles-logic-sv2/src/parsers.rs b/stratum-protocols/v2/roles-logic-sv2/src/parsers.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/parsers.rs rename to stratum-protocols/v2/roles-logic-sv2/src/parsers.rs diff --git a/protocols/v2/roles-logic-sv2/src/routing_logic.rs b/stratum-protocols/v2/roles-logic-sv2/src/routing_logic.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/routing_logic.rs rename to stratum-protocols/v2/roles-logic-sv2/src/routing_logic.rs diff --git a/protocols/v2/roles-logic-sv2/src/selectors.rs b/stratum-protocols/v2/roles-logic-sv2/src/selectors.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/selectors.rs rename to stratum-protocols/v2/roles-logic-sv2/src/selectors.rs diff --git a/protocols/v2/roles-logic-sv2/src/utils.rs b/stratum-protocols/v2/roles-logic-sv2/src/utils.rs similarity index 100% rename from protocols/v2/roles-logic-sv2/src/utils.rs rename to stratum-protocols/v2/roles-logic-sv2/src/utils.rs diff --git a/protocols/v2/subprotocols/common-messages/Cargo.toml b/stratum-protocols/v2/subprotocols/common-messages/Cargo.toml similarity index 80% rename from protocols/v2/subprotocols/common-messages/Cargo.toml rename to stratum-protocols/v2/subprotocols/common-messages/Cargo.toml index 783c208df..e023b515f 100644 --- a/protocols/v2/subprotocols/common-messages/Cargo.toml +++ b/stratum-protocols/v2/subprotocols/common-messages/Cargo.toml @@ -11,8 +11,8 @@ repository = "https://github.com/stratum-mining/stratum" [dependencies] serde = { version = "1.0.89", default-features = false, optional= true } -binary_sv2 = {version = "^1.0.0", path = "../../../../protocols/v2/binary-sv2/binary-sv2" } -const_sv2 = {version = "^2.0.0", path = "../../../../protocols/v2/const-sv2"} +binary_sv2 = {version = "^1.0.0", path = "../../../v2/binary-sv2/binary-sv2" } +const_sv2 = {version = "^2.0.0", path = "../../../v2/const-sv2"} quickcheck = { version = "1.0.3", optional=true } quickcheck_macros = { version = "1", optional=true } serde_repr = {version= "0.1.10", optional=true} diff --git a/protocols/v2/subprotocols/common-messages/src/channel_endpoint_changed.rs b/stratum-protocols/v2/subprotocols/common-messages/src/channel_endpoint_changed.rs similarity index 100% rename from protocols/v2/subprotocols/common-messages/src/channel_endpoint_changed.rs rename to stratum-protocols/v2/subprotocols/common-messages/src/channel_endpoint_changed.rs diff --git a/protocols/v2/subprotocols/common-messages/src/lib.rs b/stratum-protocols/v2/subprotocols/common-messages/src/lib.rs similarity index 100% rename from protocols/v2/subprotocols/common-messages/src/lib.rs rename to stratum-protocols/v2/subprotocols/common-messages/src/lib.rs diff --git a/protocols/v2/subprotocols/common-messages/src/setup_connection.rs b/stratum-protocols/v2/subprotocols/common-messages/src/setup_connection.rs similarity index 100% rename from protocols/v2/subprotocols/common-messages/src/setup_connection.rs rename to stratum-protocols/v2/subprotocols/common-messages/src/setup_connection.rs diff --git a/protocols/v2/subprotocols/job-declaration/Cargo.toml b/stratum-protocols/v2/subprotocols/job-declaration/Cargo.toml similarity index 70% rename from protocols/v2/subprotocols/job-declaration/Cargo.toml rename to stratum-protocols/v2/subprotocols/job-declaration/Cargo.toml index 2ee4313f4..352e3ecb4 100644 --- a/protocols/v2/subprotocols/job-declaration/Cargo.toml +++ b/stratum-protocols/v2/subprotocols/job-declaration/Cargo.toml @@ -10,8 +10,8 @@ repository = "https://github.com/stratum-mining/stratum" [dependencies] serde = { version = "1.0.89", default-features = false, optional= true } -binary_sv2 = {version = "^1.0.0", path = "../../../../protocols/v2/binary-sv2/binary-sv2" } -const_sv2 = {version = "^2.0.0", path = "../../../../protocols/v2/const-sv2"} +binary_sv2 = {version = "^1.0.0", path = "../../../v2/binary-sv2/binary-sv2" } +const_sv2 = {version = "^2.0.0", path = "../../../v2/const-sv2"} [features] no_std = [] diff --git a/protocols/v2/subprotocols/job-declaration/job-negotiation-flow.png b/stratum-protocols/v2/subprotocols/job-declaration/job-negotiation-flow.png similarity index 100% rename from protocols/v2/subprotocols/job-declaration/job-negotiation-flow.png rename to stratum-protocols/v2/subprotocols/job-declaration/job-negotiation-flow.png diff --git a/protocols/v2/subprotocols/job-declaration/src/allocate_mining_job_token.rs b/stratum-protocols/v2/subprotocols/job-declaration/src/allocate_mining_job_token.rs similarity index 100% rename from protocols/v2/subprotocols/job-declaration/src/allocate_mining_job_token.rs rename to stratum-protocols/v2/subprotocols/job-declaration/src/allocate_mining_job_token.rs diff --git a/protocols/v2/subprotocols/job-declaration/src/declare_mining_job.rs b/stratum-protocols/v2/subprotocols/job-declaration/src/declare_mining_job.rs similarity index 100% rename from protocols/v2/subprotocols/job-declaration/src/declare_mining_job.rs rename to stratum-protocols/v2/subprotocols/job-declaration/src/declare_mining_job.rs diff --git a/protocols/v2/subprotocols/job-declaration/src/identify_transactions.rs b/stratum-protocols/v2/subprotocols/job-declaration/src/identify_transactions.rs similarity index 100% rename from protocols/v2/subprotocols/job-declaration/src/identify_transactions.rs rename to stratum-protocols/v2/subprotocols/job-declaration/src/identify_transactions.rs diff --git a/protocols/v2/subprotocols/job-declaration/src/lib.rs b/stratum-protocols/v2/subprotocols/job-declaration/src/lib.rs similarity index 100% rename from protocols/v2/subprotocols/job-declaration/src/lib.rs rename to stratum-protocols/v2/subprotocols/job-declaration/src/lib.rs diff --git a/protocols/v2/subprotocols/job-declaration/src/provide_missing_transactions.rs b/stratum-protocols/v2/subprotocols/job-declaration/src/provide_missing_transactions.rs similarity index 100% rename from protocols/v2/subprotocols/job-declaration/src/provide_missing_transactions.rs rename to stratum-protocols/v2/subprotocols/job-declaration/src/provide_missing_transactions.rs diff --git a/protocols/v2/subprotocols/job-declaration/src/submit_solution.rs b/stratum-protocols/v2/subprotocols/job-declaration/src/submit_solution.rs similarity index 100% rename from protocols/v2/subprotocols/job-declaration/src/submit_solution.rs rename to stratum-protocols/v2/subprotocols/job-declaration/src/submit_solution.rs diff --git a/protocols/v2/subprotocols/mining/Cargo.toml b/stratum-protocols/v2/subprotocols/mining/Cargo.toml similarity index 76% rename from protocols/v2/subprotocols/mining/Cargo.toml rename to stratum-protocols/v2/subprotocols/mining/Cargo.toml index c98bb7ec9..50fae7041 100644 --- a/protocols/v2/subprotocols/mining/Cargo.toml +++ b/stratum-protocols/v2/subprotocols/mining/Cargo.toml @@ -12,8 +12,8 @@ repository = "https://github.com/stratum-mining/stratum" [dependencies] serde = { version = "1.0.89", default-features = false, optional= true } -binary_sv2 = {version = "^1.0.0", path = "../../../../protocols/v2/binary-sv2/binary-sv2" } -const_sv2 = {version = "^2.0.0", path = "../../../../protocols/v2/const-sv2"} +binary_sv2 = {version = "^1.0.0", path = "../../../v2/binary-sv2/binary-sv2" } +const_sv2 = {version = "^2.0.0", path = "../../../v2/const-sv2"} [dev-dependencies] quickcheck = "1.0.3" diff --git a/protocols/v2/subprotocols/mining/src/close_channel.rs b/stratum-protocols/v2/subprotocols/mining/src/close_channel.rs similarity index 100% rename from protocols/v2/subprotocols/mining/src/close_channel.rs rename to stratum-protocols/v2/subprotocols/mining/src/close_channel.rs diff --git a/protocols/v2/subprotocols/mining/src/lib.rs b/stratum-protocols/v2/subprotocols/mining/src/lib.rs similarity index 100% rename from protocols/v2/subprotocols/mining/src/lib.rs rename to stratum-protocols/v2/subprotocols/mining/src/lib.rs diff --git a/protocols/v2/subprotocols/mining/src/new_mining_job.rs b/stratum-protocols/v2/subprotocols/mining/src/new_mining_job.rs similarity index 100% rename from protocols/v2/subprotocols/mining/src/new_mining_job.rs rename to stratum-protocols/v2/subprotocols/mining/src/new_mining_job.rs diff --git a/protocols/v2/subprotocols/mining/src/open_channel.rs b/stratum-protocols/v2/subprotocols/mining/src/open_channel.rs similarity index 100% rename from protocols/v2/subprotocols/mining/src/open_channel.rs rename to stratum-protocols/v2/subprotocols/mining/src/open_channel.rs diff --git a/protocols/v2/subprotocols/mining/src/reconnect.rs b/stratum-protocols/v2/subprotocols/mining/src/reconnect.rs similarity index 100% rename from protocols/v2/subprotocols/mining/src/reconnect.rs rename to stratum-protocols/v2/subprotocols/mining/src/reconnect.rs diff --git a/protocols/v2/subprotocols/mining/src/set_custom_mining_job.rs b/stratum-protocols/v2/subprotocols/mining/src/set_custom_mining_job.rs similarity index 100% rename from protocols/v2/subprotocols/mining/src/set_custom_mining_job.rs rename to stratum-protocols/v2/subprotocols/mining/src/set_custom_mining_job.rs diff --git a/protocols/v2/subprotocols/mining/src/set_extranonce_prefix.rs b/stratum-protocols/v2/subprotocols/mining/src/set_extranonce_prefix.rs similarity index 100% rename from protocols/v2/subprotocols/mining/src/set_extranonce_prefix.rs rename to stratum-protocols/v2/subprotocols/mining/src/set_extranonce_prefix.rs diff --git a/protocols/v2/subprotocols/mining/src/set_group_channel.rs b/stratum-protocols/v2/subprotocols/mining/src/set_group_channel.rs similarity index 100% rename from protocols/v2/subprotocols/mining/src/set_group_channel.rs rename to stratum-protocols/v2/subprotocols/mining/src/set_group_channel.rs diff --git a/protocols/v2/subprotocols/mining/src/set_new_prev_hash.rs b/stratum-protocols/v2/subprotocols/mining/src/set_new_prev_hash.rs similarity index 100% rename from protocols/v2/subprotocols/mining/src/set_new_prev_hash.rs rename to stratum-protocols/v2/subprotocols/mining/src/set_new_prev_hash.rs diff --git a/protocols/v2/subprotocols/mining/src/set_target.rs b/stratum-protocols/v2/subprotocols/mining/src/set_target.rs similarity index 100% rename from protocols/v2/subprotocols/mining/src/set_target.rs rename to stratum-protocols/v2/subprotocols/mining/src/set_target.rs diff --git a/protocols/v2/subprotocols/mining/src/submit_shares.rs b/stratum-protocols/v2/subprotocols/mining/src/submit_shares.rs similarity index 100% rename from protocols/v2/subprotocols/mining/src/submit_shares.rs rename to stratum-protocols/v2/subprotocols/mining/src/submit_shares.rs diff --git a/protocols/v2/subprotocols/mining/src/update_channel.rs b/stratum-protocols/v2/subprotocols/mining/src/update_channel.rs similarity index 100% rename from protocols/v2/subprotocols/mining/src/update_channel.rs rename to stratum-protocols/v2/subprotocols/mining/src/update_channel.rs diff --git a/protocols/v2/subprotocols/template-distribution/Cargo.toml b/stratum-protocols/v2/subprotocols/template-distribution/Cargo.toml similarity index 78% rename from protocols/v2/subprotocols/template-distribution/Cargo.toml rename to stratum-protocols/v2/subprotocols/template-distribution/Cargo.toml index b0120836d..00fcdef96 100644 --- a/protocols/v2/subprotocols/template-distribution/Cargo.toml +++ b/stratum-protocols/v2/subprotocols/template-distribution/Cargo.toml @@ -11,8 +11,8 @@ repository = "https://github.com/stratum-mining/stratum" [dependencies] serde = { version = "1.0.89", default-features = false, optional= true } -binary_sv2 = { version = "^1.0.1", path = "../../../../protocols/v2/binary-sv2/binary-sv2" } -const_sv2 = { version = "^2.0.0", path = "../../../../protocols/v2/const-sv2"} +binary_sv2 = { version = "^1.0.1", path = "../../../v2/binary-sv2/binary-sv2" } +const_sv2 = { version = "^2.0.0", path = "../../../v2/const-sv2"} quickcheck = { version = "1.0.3", optional=true } quickcheck_macros = { version = "1", optional=true } diff --git a/protocols/v2/subprotocols/template-distribution/src/coinbase_output_data_size.rs b/stratum-protocols/v2/subprotocols/template-distribution/src/coinbase_output_data_size.rs similarity index 100% rename from protocols/v2/subprotocols/template-distribution/src/coinbase_output_data_size.rs rename to stratum-protocols/v2/subprotocols/template-distribution/src/coinbase_output_data_size.rs diff --git a/protocols/v2/subprotocols/template-distribution/src/lib.rs b/stratum-protocols/v2/subprotocols/template-distribution/src/lib.rs similarity index 100% rename from protocols/v2/subprotocols/template-distribution/src/lib.rs rename to stratum-protocols/v2/subprotocols/template-distribution/src/lib.rs diff --git a/protocols/v2/subprotocols/template-distribution/src/new_template.rs b/stratum-protocols/v2/subprotocols/template-distribution/src/new_template.rs similarity index 100% rename from protocols/v2/subprotocols/template-distribution/src/new_template.rs rename to stratum-protocols/v2/subprotocols/template-distribution/src/new_template.rs diff --git a/protocols/v2/subprotocols/template-distribution/src/request_transaction_data.rs b/stratum-protocols/v2/subprotocols/template-distribution/src/request_transaction_data.rs similarity index 100% rename from protocols/v2/subprotocols/template-distribution/src/request_transaction_data.rs rename to stratum-protocols/v2/subprotocols/template-distribution/src/request_transaction_data.rs diff --git a/protocols/v2/subprotocols/template-distribution/src/set_new_prev_hash.rs b/stratum-protocols/v2/subprotocols/template-distribution/src/set_new_prev_hash.rs similarity index 100% rename from protocols/v2/subprotocols/template-distribution/src/set_new_prev_hash.rs rename to stratum-protocols/v2/subprotocols/template-distribution/src/set_new_prev_hash.rs diff --git a/protocols/v2/subprotocols/template-distribution/src/submit_solution.rs b/stratum-protocols/v2/subprotocols/template-distribution/src/submit_solution.rs similarity index 100% rename from protocols/v2/subprotocols/template-distribution/src/submit_solution.rs rename to stratum-protocols/v2/subprotocols/template-distribution/src/submit_solution.rs diff --git a/protocols/v2/sv2-ffi/Cargo.toml b/stratum-protocols/v2/sv2-ffi/Cargo.toml similarity index 51% rename from protocols/v2/sv2-ffi/Cargo.toml rename to stratum-protocols/v2/sv2-ffi/Cargo.toml index 6498b1b5b..cc0728615 100644 --- a/protocols/v2/sv2-ffi/Cargo.toml +++ b/stratum-protocols/v2/sv2-ffi/Cargo.toml @@ -11,11 +11,11 @@ repository = "https://github.com/stratum-mining/stratum" crate-type = ["staticlib"] [dependencies] -codec_sv2 = { path = "../../../protocols/v2/codec-sv2", version = "^1.0.0" } -const_sv2 = { path = "../../../protocols/v2/const-sv2", version = "^2.0.0" } -binary_sv2 = { path = "../../../protocols/v2/binary-sv2/binary-sv2", version = "^1.0.0" } -common_messages_sv2 = { path = "../../../protocols/v2/subprotocols/common-messages", version = "^2.0.0" } -template_distribution_sv2 = { path = "../../../protocols/v2/subprotocols/template-distribution", version = "^1.0.1" } +codec_sv2 = { path = "../../v2/codec-sv2", version = "^1.0.0" } +const_sv2 = { path = "../../v2/const-sv2", version = "^2.0.0" } +binary_sv2 = { path = "../../v2/binary-sv2/binary-sv2", version = "^1.0.0" } +common_messages_sv2 = { path = "../../v2/subprotocols/common-messages", version = "^2.0.0" } +template_distribution_sv2 = { path = "../../v2/subprotocols/template-distribution", version = "^1.0.1" } [dev-dependencies] quickcheck = "1.0.3" diff --git a/protocols/v2/sv2-ffi/src/lib.rs b/stratum-protocols/v2/sv2-ffi/src/lib.rs similarity index 100% rename from protocols/v2/sv2-ffi/src/lib.rs rename to stratum-protocols/v2/sv2-ffi/src/lib.rs diff --git a/protocols/v2/sv2-ffi/sv2.h b/stratum-protocols/v2/sv2-ffi/sv2.h similarity index 100% rename from protocols/v2/sv2-ffi/sv2.h rename to stratum-protocols/v2/sv2-ffi/sv2.h diff --git a/roles/jd-client/Cargo.toml b/stratum-roles/jd-client/Cargo.toml similarity index 66% rename from roles/jd-client/Cargo.toml rename to stratum-roles/jd-client/Cargo.toml index dc2d46079..65d64f34f 100644 --- a/roles/jd-client/Cargo.toml +++ b/stratum-roles/jd-client/Cargo.toml @@ -11,15 +11,15 @@ name = "jd_client" path = "src/lib/mod.rs" [dependencies] -stratum-common = { version = "1.0.0", path = "../../common" } +stratum-common = { version = "1.0.0", path = "../../stratum-common" } async-channel = "1.5.1" async-recursion = "0.3.2" -binary_sv2 = { version = "^1.0.0", path = "../../protocols/v2/binary-sv2/binary-sv2" } +binary_sv2 = { version = "^1.0.0", path = "../../stratum-protocols/v2/binary-sv2/binary-sv2" } buffer_sv2 = { version = "^1.0.0", path = "../../utils/buffer" } -codec_sv2 = { version = "^1.0.1", path = "../../protocols/v2/codec-sv2", features = ["noise_sv2", "with_buffer_pool"] } -framing_sv2 = { version = "^2.0.0", path = "../../protocols/v2/framing-sv2" } +codec_sv2 = { version = "^1.0.1", path = "../../stratum-protocols/v2/codec-sv2", features = ["noise_sv2", "with_buffer_pool"] } +framing_sv2 = { version = "^2.0.0", path = "../../stratum-protocols/v2/framing-sv2" } network_helpers_sv2 = { version = "2.0.0", path = "../roles-utils/network-helpers", features=["with_tokio", "with_buffer_pool"] } -roles_logic_sv2 = { version = "^1.0.0", path = "../../protocols/v2/roles-logic-sv2" } +roles_logic_sv2 = { version = "^1.0.0", path = "../../stratum-protocols/v2/roles-logic-sv2" } serde = { version = "1.0.89", default-features = false, features = ["derive", "alloc"] } futures = "0.3.25" tokio = { version = "1", features = ["full"] } diff --git a/roles/jd-client/README.md b/stratum-roles/jd-client/README.md similarity index 100% rename from roles/jd-client/README.md rename to stratum-roles/jd-client/README.md diff --git a/roles/jd-client/config-examples/jdc-config-hosted-example.toml b/stratum-roles/jd-client/config-examples/jdc-config-hosted-example.toml similarity index 100% rename from roles/jd-client/config-examples/jdc-config-hosted-example.toml rename to stratum-roles/jd-client/config-examples/jdc-config-hosted-example.toml diff --git a/roles/jd-client/config-examples/jdc-config-local-example.toml b/stratum-roles/jd-client/config-examples/jdc-config-local-example.toml similarity index 100% rename from roles/jd-client/config-examples/jdc-config-local-example.toml rename to stratum-roles/jd-client/config-examples/jdc-config-local-example.toml diff --git a/roles/jd-client/run.sh b/stratum-roles/jd-client/run.sh similarity index 100% rename from roles/jd-client/run.sh rename to stratum-roles/jd-client/run.sh diff --git a/roles/jd-client/src/args.rs b/stratum-roles/jd-client/src/args.rs similarity index 100% rename from roles/jd-client/src/args.rs rename to stratum-roles/jd-client/src/args.rs diff --git a/roles/jd-client/src/lib/downstream.rs b/stratum-roles/jd-client/src/lib/downstream.rs similarity index 100% rename from roles/jd-client/src/lib/downstream.rs rename to stratum-roles/jd-client/src/lib/downstream.rs diff --git a/roles/jd-client/src/lib/error.rs b/stratum-roles/jd-client/src/lib/error.rs similarity index 100% rename from roles/jd-client/src/lib/error.rs rename to stratum-roles/jd-client/src/lib/error.rs diff --git a/roles/jd-client/src/lib/job_declarator/message_handler.rs b/stratum-roles/jd-client/src/lib/job_declarator/message_handler.rs similarity index 100% rename from roles/jd-client/src/lib/job_declarator/message_handler.rs rename to stratum-roles/jd-client/src/lib/job_declarator/message_handler.rs diff --git a/roles/jd-client/src/lib/job_declarator/mod.rs b/stratum-roles/jd-client/src/lib/job_declarator/mod.rs similarity index 100% rename from roles/jd-client/src/lib/job_declarator/mod.rs rename to stratum-roles/jd-client/src/lib/job_declarator/mod.rs diff --git a/roles/jd-client/src/lib/job_declarator/setup_connection.rs b/stratum-roles/jd-client/src/lib/job_declarator/setup_connection.rs similarity index 100% rename from roles/jd-client/src/lib/job_declarator/setup_connection.rs rename to stratum-roles/jd-client/src/lib/job_declarator/setup_connection.rs diff --git a/roles/jd-client/src/lib/mod.rs b/stratum-roles/jd-client/src/lib/mod.rs similarity index 100% rename from roles/jd-client/src/lib/mod.rs rename to stratum-roles/jd-client/src/lib/mod.rs diff --git a/roles/jd-client/src/lib/proxy_config.rs b/stratum-roles/jd-client/src/lib/proxy_config.rs similarity index 100% rename from roles/jd-client/src/lib/proxy_config.rs rename to stratum-roles/jd-client/src/lib/proxy_config.rs diff --git a/roles/jd-client/src/lib/status.rs b/stratum-roles/jd-client/src/lib/status.rs similarity index 100% rename from roles/jd-client/src/lib/status.rs rename to stratum-roles/jd-client/src/lib/status.rs diff --git a/roles/jd-client/src/lib/template_receiver/message_handler.rs b/stratum-roles/jd-client/src/lib/template_receiver/message_handler.rs similarity index 100% rename from roles/jd-client/src/lib/template_receiver/message_handler.rs rename to stratum-roles/jd-client/src/lib/template_receiver/message_handler.rs diff --git a/roles/jd-client/src/lib/template_receiver/mod.rs b/stratum-roles/jd-client/src/lib/template_receiver/mod.rs similarity index 100% rename from roles/jd-client/src/lib/template_receiver/mod.rs rename to stratum-roles/jd-client/src/lib/template_receiver/mod.rs diff --git a/roles/jd-client/src/lib/template_receiver/setup_connection.rs b/stratum-roles/jd-client/src/lib/template_receiver/setup_connection.rs similarity index 100% rename from roles/jd-client/src/lib/template_receiver/setup_connection.rs rename to stratum-roles/jd-client/src/lib/template_receiver/setup_connection.rs diff --git a/roles/jd-client/src/lib/upstream_sv2/mod.rs b/stratum-roles/jd-client/src/lib/upstream_sv2/mod.rs similarity index 100% rename from roles/jd-client/src/lib/upstream_sv2/mod.rs rename to stratum-roles/jd-client/src/lib/upstream_sv2/mod.rs diff --git a/roles/jd-client/src/lib/upstream_sv2/upstream.rs b/stratum-roles/jd-client/src/lib/upstream_sv2/upstream.rs similarity index 100% rename from roles/jd-client/src/lib/upstream_sv2/upstream.rs rename to stratum-roles/jd-client/src/lib/upstream_sv2/upstream.rs diff --git a/roles/jd-client/src/main.rs b/stratum-roles/jd-client/src/main.rs similarity index 100% rename from roles/jd-client/src/main.rs rename to stratum-roles/jd-client/src/main.rs diff --git a/roles/jd-server/Cargo.toml b/stratum-roles/jd-server/Cargo.toml similarity index 67% rename from roles/jd-server/Cargo.toml rename to stratum-roles/jd-server/Cargo.toml index e8d82438a..7caaae9d5 100644 --- a/roles/jd-server/Cargo.toml +++ b/stratum-roles/jd-server/Cargo.toml @@ -10,16 +10,16 @@ name = "jd_server" path = "src/lib/mod.rs" [dependencies] -stratum-common = { version = "1.0.0", path = "../../common" } +stratum-common = { version = "1.0.0", path = "../../stratum-common" } async-channel = "1.5.1" -binary_sv2 = { version = "^1.0.0", path = "../../protocols/v2/binary-sv2/binary-sv2" } +binary_sv2 = { version = "^1.0.0", path = "../../stratum-protocols/v2/binary-sv2/binary-sv2" } buffer_sv2 = { version = "^1.0.0", path = "../../utils/buffer" } -codec_sv2 = { version = "^1.0.1", path = "../../protocols/v2/codec-sv2", features = ["noise_sv2"] } -const_sv2 = { version = "^2.0.0", path = "../../protocols/v2/const-sv2" } +codec_sv2 = { version = "^1.0.1", path = "../../stratum-protocols/v2/codec-sv2", features = ["noise_sv2"] } +const_sv2 = { version = "^2.0.0", path = "../../stratum-protocols/v2/const-sv2" } network_helpers_sv2 = { version = "2.0.0", path = "../roles-utils/network-helpers", features = ["with_tokio"] } -noise_sv2 = { version = "1.1.0", path = "../../protocols/v2/noise-sv2" } +noise_sv2 = { version = "1.1.0", path = "../../stratum-protocols/v2/noise-sv2" } rand = "0.8.4" -roles_logic_sv2 = { version = "^1.0.0", path = "../../protocols/v2/roles-logic-sv2" } +roles_logic_sv2 = { version = "^1.0.0", path = "../../stratum-protocols/v2/roles-logic-sv2" } tokio = { version = "1", features = ["full"] } ext-config = { version = "0.14.0", features = ["toml"], package = "config" } tracing = { version = "0.1" } @@ -31,4 +31,4 @@ serde = { version = "1.0.89", features = ["derive", "alloc"], default-features = hashbrown = { version = "0.11", default-features = false, features = ["ahash", "serde"] } key-utils = { version = "^1.0.0", path = "../../utils/key-utils" } rpc_sv2 = { version = "1.0.0", path = "../roles-utils/rpc" } -hex = "0.4.3" \ No newline at end of file +hex = "0.4.3" diff --git a/roles/jd-server/config-examples/jds-config-hosted-example.toml b/stratum-roles/jd-server/config-examples/jds-config-hosted-example.toml similarity index 100% rename from roles/jd-server/config-examples/jds-config-hosted-example.toml rename to stratum-roles/jd-server/config-examples/jds-config-hosted-example.toml diff --git a/roles/jd-server/config-examples/jds-config-local-example.toml b/stratum-roles/jd-server/config-examples/jds-config-local-example.toml similarity index 100% rename from roles/jd-server/config-examples/jds-config-local-example.toml rename to stratum-roles/jd-server/config-examples/jds-config-local-example.toml diff --git a/roles/jd-server/src/lib/error.rs b/stratum-roles/jd-server/src/lib/error.rs similarity index 100% rename from roles/jd-server/src/lib/error.rs rename to stratum-roles/jd-server/src/lib/error.rs diff --git a/roles/jd-server/src/lib/job_declarator/message_handler.rs b/stratum-roles/jd-server/src/lib/job_declarator/message_handler.rs similarity index 100% rename from roles/jd-server/src/lib/job_declarator/message_handler.rs rename to stratum-roles/jd-server/src/lib/job_declarator/message_handler.rs diff --git a/roles/jd-server/src/lib/job_declarator/mod.rs b/stratum-roles/jd-server/src/lib/job_declarator/mod.rs similarity index 100% rename from roles/jd-server/src/lib/job_declarator/mod.rs rename to stratum-roles/jd-server/src/lib/job_declarator/mod.rs diff --git a/roles/jd-server/src/lib/mempool/error.rs b/stratum-roles/jd-server/src/lib/mempool/error.rs similarity index 100% rename from roles/jd-server/src/lib/mempool/error.rs rename to stratum-roles/jd-server/src/lib/mempool/error.rs diff --git a/roles/jd-server/src/lib/mempool/mod.rs b/stratum-roles/jd-server/src/lib/mempool/mod.rs similarity index 100% rename from roles/jd-server/src/lib/mempool/mod.rs rename to stratum-roles/jd-server/src/lib/mempool/mod.rs diff --git a/roles/jd-server/src/lib/mod.rs b/stratum-roles/jd-server/src/lib/mod.rs similarity index 100% rename from roles/jd-server/src/lib/mod.rs rename to stratum-roles/jd-server/src/lib/mod.rs diff --git a/roles/jd-server/src/lib/status.rs b/stratum-roles/jd-server/src/lib/status.rs similarity index 100% rename from roles/jd-server/src/lib/status.rs rename to stratum-roles/jd-server/src/lib/status.rs diff --git a/roles/jd-server/src/main.rs b/stratum-roles/jd-server/src/main.rs similarity index 100% rename from roles/jd-server/src/main.rs rename to stratum-roles/jd-server/src/main.rs diff --git a/roles/mining-proxy/Cargo.toml b/stratum-roles/mining-proxy/Cargo.toml similarity index 66% rename from roles/mining-proxy/Cargo.toml rename to stratum-roles/mining-proxy/Cargo.toml index 8ffb5d095..a0dd44fd0 100644 --- a/roles/mining-proxy/Cargo.toml +++ b/stratum-roles/mining-proxy/Cargo.toml @@ -12,17 +12,17 @@ name = "mining_proxy_sv2" path = "src/lib/mod.rs" [dependencies] -stratum-common = { version = "1.0.0", path = "../../common" } +stratum-common = { version = "1.0.0", path = "../../stratum-common" } async-channel = "1.8.0" async-recursion = "0.3.2" -binary_sv2 = { version = "^1.0.0", path = "../../protocols/v2/binary-sv2/binary-sv2" } +binary_sv2 = { version = "^1.0.0", path = "../../stratum-protocols/v2/binary-sv2/binary-sv2" } buffer_sv2 = { version = "^1.0.0", path = "../../utils/buffer" } -codec_sv2 = { version = "^1.0.1", path = "../../protocols/v2/codec-sv2", features = ["noise_sv2", "with_buffer_pool"] } -const_sv2 = { version = "^2.0.0", path = "../../protocols/v2/const-sv2" } +codec_sv2 = { version = "^1.0.1", path = "../../stratum-protocols/v2/codec-sv2", features = ["noise_sv2", "with_buffer_pool"] } +const_sv2 = { version = "^2.0.0", path = "../../stratum-protocols/v2/const-sv2" } futures = "0.3.19" network_helpers_sv2 = {version = "2.0.0", path = "../roles-utils/network-helpers", features = ["with_tokio","with_buffer_pool"] } once_cell = "1.12.0" -roles_logic_sv2 = { version = "^1.0.0", path = "../../protocols/v2/roles-logic-sv2" } +roles_logic_sv2 = { version = "^1.0.0", path = "../../stratum-protocols/v2/roles-logic-sv2" } serde = { version = "1.0.89", features = ["derive", "alloc"], default-features = false } tokio = { version = "1", features = ["full"] } ext-config = { version = "0.14.0", features = ["toml"], package = "config" } diff --git a/roles/mining-proxy/README.md b/stratum-roles/mining-proxy/README.md similarity index 100% rename from roles/mining-proxy/README.md rename to stratum-roles/mining-proxy/README.md diff --git a/roles/mining-proxy/config-examples/proxy-config-example.toml b/stratum-roles/mining-proxy/config-examples/proxy-config-example.toml similarity index 100% rename from roles/mining-proxy/config-examples/proxy-config-example.toml rename to stratum-roles/mining-proxy/config-examples/proxy-config-example.toml diff --git a/roles/mining-proxy/flamegraph.svg b/stratum-roles/mining-proxy/flamegraph.svg similarity index 100% rename from roles/mining-proxy/flamegraph.svg rename to stratum-roles/mining-proxy/flamegraph.svg diff --git a/roles/mining-proxy/perf.data b/stratum-roles/mining-proxy/perf.data similarity index 100% rename from roles/mining-proxy/perf.data rename to stratum-roles/mining-proxy/perf.data diff --git a/roles/mining-proxy/perf.data.old b/stratum-roles/mining-proxy/perf.data.old similarity index 100% rename from roles/mining-proxy/perf.data.old rename to stratum-roles/mining-proxy/perf.data.old diff --git a/roles/mining-proxy/src/lib/downstream_mining.rs b/stratum-roles/mining-proxy/src/lib/downstream_mining.rs similarity index 100% rename from roles/mining-proxy/src/lib/downstream_mining.rs rename to stratum-roles/mining-proxy/src/lib/downstream_mining.rs diff --git a/roles/mining-proxy/src/lib/error.rs b/stratum-roles/mining-proxy/src/lib/error.rs similarity index 100% rename from roles/mining-proxy/src/lib/error.rs rename to stratum-roles/mining-proxy/src/lib/error.rs diff --git a/roles/mining-proxy/src/lib/mod.rs b/stratum-roles/mining-proxy/src/lib/mod.rs similarity index 100% rename from roles/mining-proxy/src/lib/mod.rs rename to stratum-roles/mining-proxy/src/lib/mod.rs diff --git a/roles/mining-proxy/src/lib/upstream_mining.rs b/stratum-roles/mining-proxy/src/lib/upstream_mining.rs similarity index 100% rename from roles/mining-proxy/src/lib/upstream_mining.rs rename to stratum-roles/mining-proxy/src/lib/upstream_mining.rs diff --git a/roles/mining-proxy/src/main.rs b/stratum-roles/mining-proxy/src/main.rs similarity index 100% rename from roles/mining-proxy/src/main.rs rename to stratum-roles/mining-proxy/src/main.rs diff --git a/roles/pool/Cargo.toml b/stratum-roles/pool/Cargo.toml similarity index 66% rename from roles/pool/Cargo.toml rename to stratum-roles/pool/Cargo.toml index c253e6b3e..5d4a6dfc6 100644 --- a/roles/pool/Cargo.toml +++ b/stratum-roles/pool/Cargo.toml @@ -11,16 +11,16 @@ name = "pool_sv2" path = "src/lib/mod.rs" [dependencies] -stratum-common = { version = "1.0.0", path = "../../common" } +stratum-common = { version = "1.0.0", path = "../../stratum-common" } async-channel = "1.5.1" -binary_sv2 = { version = "^1.0.0", path = "../../protocols/v2/binary-sv2/binary-sv2" } +binary_sv2 = { version = "^1.0.0", path = "../../stratum-protocols/v2/binary-sv2/binary-sv2" } buffer_sv2 = { version = "^1.0.0", path = "../../utils/buffer" } -codec_sv2 = { version = "^1.0.1", path = "../../protocols/v2/codec-sv2", features = ["noise_sv2"] } -const_sv2 = { version = "^2.0.0", path = "../../protocols/v2/const-sv2" } +codec_sv2 = { version = "^1.0.1", path = "../../stratum-protocols/v2/codec-sv2", features = ["noise_sv2"] } +const_sv2 = { version = "^2.0.0", path = "../../stratum-protocols/v2/const-sv2" } network_helpers_sv2 = { version = "2.0.0", path = "../roles-utils/network-helpers", features =["with_tokio","with_buffer_pool"] } -noise_sv2 = { version = "1.1.0", path = "../../protocols/v2/noise-sv2" } +noise_sv2 = { version = "1.1.0", path = "../../stratum-protocols/v2/noise-sv2" } rand = "0.8.4" -roles_logic_sv2 = { version = "^1.0.0", path = "../../protocols/v2/roles-logic-sv2" } +roles_logic_sv2 = { version = "^1.0.0", path = "../../stratum-protocols/v2/roles-logic-sv2" } serde = { version = "1.0.89", features = ["derive", "alloc"], default-features = false } tokio = { version = "1", features = ["full"] } ext-config = { version = "0.14.0", features = ["toml"], package = "config" } diff --git a/roles/pool/README.md b/stratum-roles/pool/README.md similarity index 100% rename from roles/pool/README.md rename to stratum-roles/pool/README.md diff --git a/roles/pool/config-examples/pool-config-hosted-tp-example.toml b/stratum-roles/pool/config-examples/pool-config-hosted-tp-example.toml similarity index 100% rename from roles/pool/config-examples/pool-config-hosted-tp-example.toml rename to stratum-roles/pool/config-examples/pool-config-hosted-tp-example.toml diff --git a/roles/pool/config-examples/pool-config-local-tp-example.toml b/stratum-roles/pool/config-examples/pool-config-local-tp-example.toml similarity index 100% rename from roles/pool/config-examples/pool-config-local-tp-example.toml rename to stratum-roles/pool/config-examples/pool-config-local-tp-example.toml diff --git a/roles/pool/src/lib/error.rs b/stratum-roles/pool/src/lib/error.rs similarity index 100% rename from roles/pool/src/lib/error.rs rename to stratum-roles/pool/src/lib/error.rs diff --git a/roles/pool/src/lib/mining_pool/message_handler.rs b/stratum-roles/pool/src/lib/mining_pool/message_handler.rs similarity index 100% rename from roles/pool/src/lib/mining_pool/message_handler.rs rename to stratum-roles/pool/src/lib/mining_pool/message_handler.rs diff --git a/roles/pool/src/lib/mining_pool/mod.rs b/stratum-roles/pool/src/lib/mining_pool/mod.rs similarity index 100% rename from roles/pool/src/lib/mining_pool/mod.rs rename to stratum-roles/pool/src/lib/mining_pool/mod.rs diff --git a/roles/pool/src/lib/mining_pool/setup_connection.rs b/stratum-roles/pool/src/lib/mining_pool/setup_connection.rs similarity index 100% rename from roles/pool/src/lib/mining_pool/setup_connection.rs rename to stratum-roles/pool/src/lib/mining_pool/setup_connection.rs diff --git a/roles/pool/src/lib/mod.rs b/stratum-roles/pool/src/lib/mod.rs similarity index 100% rename from roles/pool/src/lib/mod.rs rename to stratum-roles/pool/src/lib/mod.rs diff --git a/roles/pool/src/lib/status.rs b/stratum-roles/pool/src/lib/status.rs similarity index 100% rename from roles/pool/src/lib/status.rs rename to stratum-roles/pool/src/lib/status.rs diff --git a/roles/pool/src/lib/template_receiver/message_handler.rs b/stratum-roles/pool/src/lib/template_receiver/message_handler.rs similarity index 100% rename from roles/pool/src/lib/template_receiver/message_handler.rs rename to stratum-roles/pool/src/lib/template_receiver/message_handler.rs diff --git a/roles/pool/src/lib/template_receiver/mod.rs b/stratum-roles/pool/src/lib/template_receiver/mod.rs similarity index 100% rename from roles/pool/src/lib/template_receiver/mod.rs rename to stratum-roles/pool/src/lib/template_receiver/mod.rs diff --git a/roles/pool/src/lib/template_receiver/setup_connection.rs b/stratum-roles/pool/src/lib/template_receiver/setup_connection.rs similarity index 100% rename from roles/pool/src/lib/template_receiver/setup_connection.rs rename to stratum-roles/pool/src/lib/template_receiver/setup_connection.rs diff --git a/roles/pool/src/main.rs b/stratum-roles/pool/src/main.rs similarity index 100% rename from roles/pool/src/main.rs rename to stratum-roles/pool/src/main.rs diff --git a/roles/roles-utils/network-helpers/Cargo.toml b/stratum-roles/roles-utils/network-helpers/Cargo.toml similarity index 75% rename from roles/roles-utils/network-helpers/Cargo.toml rename to stratum-roles/roles-utils/network-helpers/Cargo.toml index b4af8f293..147ffc002 100644 --- a/roles/roles-utils/network-helpers/Cargo.toml +++ b/stratum-roles/roles-utils/network-helpers/Cargo.toml @@ -13,9 +13,9 @@ repository = "https://github.com/stratum-mining/stratum" async-std = { version = "1.8.0", optional = true } async-channel = { version = "1.8.0", optional = true } tokio = { version = "1", features = ["full"], optional = true } -binary_sv2 = { version = "^1.0.0", path = "../../../protocols/v2/binary-sv2/binary-sv2", optional = true } -codec_sv2 = { version = "1.0.1", path = "../../../protocols/v2/codec-sv2", features=["noise_sv2"], optional = true } -const_sv2 = {version = "2.0.0", path = "../../../protocols/v2/const-sv2"} +binary_sv2 = { version = "^1.0.0", path = "../../../stratum-protocols/v2/binary-sv2/binary-sv2", optional = true } +codec_sv2 = { version = "1.0.1", path = "../../../stratum-protocols/v2/codec-sv2", features=["noise_sv2"], optional = true } +const_sv2 = {version = "2.0.0", path = "../../../stratum-protocols/v2/const-sv2"} serde = { version = "1.0.89", features = ["derive"], default-features = false, optional = true } tracing = { version = "0.1" } futures = "0.3.28" diff --git a/roles/roles-utils/network-helpers/src/lib.rs b/stratum-roles/roles-utils/network-helpers/src/lib.rs similarity index 100% rename from roles/roles-utils/network-helpers/src/lib.rs rename to stratum-roles/roles-utils/network-helpers/src/lib.rs diff --git a/roles/roles-utils/network-helpers/src/noise_connection_async_std.rs b/stratum-roles/roles-utils/network-helpers/src/noise_connection_async_std.rs similarity index 100% rename from roles/roles-utils/network-helpers/src/noise_connection_async_std.rs rename to stratum-roles/roles-utils/network-helpers/src/noise_connection_async_std.rs diff --git a/roles/roles-utils/network-helpers/src/noise_connection_tokio.rs b/stratum-roles/roles-utils/network-helpers/src/noise_connection_tokio.rs similarity index 100% rename from roles/roles-utils/network-helpers/src/noise_connection_tokio.rs rename to stratum-roles/roles-utils/network-helpers/src/noise_connection_tokio.rs diff --git a/roles/roles-utils/network-helpers/src/plain_connection_async_std.rs b/stratum-roles/roles-utils/network-helpers/src/plain_connection_async_std.rs similarity index 100% rename from roles/roles-utils/network-helpers/src/plain_connection_async_std.rs rename to stratum-roles/roles-utils/network-helpers/src/plain_connection_async_std.rs diff --git a/roles/roles-utils/network-helpers/src/plain_connection_tokio.rs b/stratum-roles/roles-utils/network-helpers/src/plain_connection_tokio.rs similarity index 100% rename from roles/roles-utils/network-helpers/src/plain_connection_tokio.rs rename to stratum-roles/roles-utils/network-helpers/src/plain_connection_tokio.rs diff --git a/roles/roles-utils/rpc/Cargo.toml b/stratum-roles/roles-utils/rpc/Cargo.toml similarity index 85% rename from roles/roles-utils/rpc/Cargo.toml rename to stratum-roles/roles-utils/rpc/Cargo.toml index 6ae6e0552..463d10a1a 100644 --- a/roles/roles-utils/rpc/Cargo.toml +++ b/stratum-roles/roles-utils/rpc/Cargo.toml @@ -8,7 +8,7 @@ license = "MIT OR Apache-2.0" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -stratum-common = { version = "1.0.0", path = "../../../common", features=["bitcoin"] } +stratum-common = { version = "1.0.0", path = "../../../stratum-common", features=["bitcoin"] } serde = { version = "1.0.89", features = ["derive", "alloc"], default-features = false } serde_json = { version = "1.0", default-features = false, features = ["alloc","raw_value"] } hex = "0.4.3" diff --git a/roles/roles-utils/rpc/src/lib.rs b/stratum-roles/roles-utils/rpc/src/lib.rs similarity index 100% rename from roles/roles-utils/rpc/src/lib.rs rename to stratum-roles/roles-utils/rpc/src/lib.rs diff --git a/roles/roles-utils/rpc/src/mini_rpc_client.rs b/stratum-roles/roles-utils/rpc/src/mini_rpc_client.rs similarity index 100% rename from roles/roles-utils/rpc/src/mini_rpc_client.rs rename to stratum-roles/roles-utils/rpc/src/mini_rpc_client.rs diff --git a/roles/tarpaulin.toml b/stratum-roles/tarpaulin.toml similarity index 100% rename from roles/tarpaulin.toml rename to stratum-roles/tarpaulin.toml diff --git a/roles/test-utils/mining-device/Cargo.toml b/stratum-roles/test-utils/mining-device/Cargo.toml similarity index 59% rename from roles/test-utils/mining-device/Cargo.toml rename to stratum-roles/test-utils/mining-device/Cargo.toml index a59719504..a38a3b795 100644 --- a/roles/test-utils/mining-device/Cargo.toml +++ b/stratum-roles/test-utils/mining-device/Cargo.toml @@ -7,12 +7,12 @@ publish = false # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -stratum-common = { version = "1.0.0", path = "../../../common" } -codec_sv2 = { version = "^1.0.1", path = "../../../protocols/v2/codec-sv2", features=["noise_sv2"] } -roles_logic_sv2 = { version = "1.0.0", path = "../../../protocols/v2/roles-logic-sv2" } -const_sv2 = { version = "2.0.0", path = "../../../protocols/v2/const-sv2" } +stratum-common = { version = "1.0.0", path = "../../../stratum-common" } +codec_sv2 = { version = "^1.0.1", path = "../../../stratum-protocols/v2/codec-sv2", features=["noise_sv2"] } +roles_logic_sv2 = { version = "1.0.0", path = "../../../stratum-protocols/v2/roles-logic-sv2" } +const_sv2 = { version = "2.0.0", path = "../../../stratum-protocols/v2/const-sv2" } async-channel = "1.5.1" -binary_sv2 = { version = "1.0.0", path = "../../../protocols/v2/binary-sv2/binary-sv2" } +binary_sv2 = { version = "1.0.0", path = "../../../stratum-protocols/v2/binary-sv2/binary-sv2" } network_helpers_sv2 = { version = "2.0.0", path = "../../roles-utils/network-helpers", features=["tokio"] } buffer_sv2 = { version = "1.0.0", path = "../../../utils/buffer"} async-recursion = "0.3.2" diff --git a/roles/test-utils/mining-device/README.md b/stratum-roles/test-utils/mining-device/README.md similarity index 100% rename from roles/test-utils/mining-device/README.md rename to stratum-roles/test-utils/mining-device/README.md diff --git a/roles/test-utils/mining-device/src/main.rs b/stratum-roles/test-utils/mining-device/src/main.rs similarity index 100% rename from roles/test-utils/mining-device/src/main.rs rename to stratum-roles/test-utils/mining-device/src/main.rs diff --git a/roles/test-utils/sv1-mining-device/Cargo.toml b/stratum-roles/test-utils/sv1-mining-device/Cargo.toml similarity index 71% rename from roles/test-utils/sv1-mining-device/Cargo.toml rename to stratum-roles/test-utils/sv1-mining-device/Cargo.toml index 55b990c63..f5c78d137 100644 --- a/roles/test-utils/sv1-mining-device/Cargo.toml +++ b/stratum-roles/test-utils/sv1-mining-device/Cargo.toml @@ -7,12 +7,12 @@ publish = false # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -stratum-common = { path = "../../../common" } +stratum-common = { path = "../../../stratum-common" } async-channel = "1.5.1" async-std = { version = "1.8.0", features = ["attributes"] } -roles_logic_sv2 = { path = "../../../protocols/v2/roles-logic-sv2" } +roles_logic_sv2 = { path = "../../../stratum-protocols/v2/roles-logic-sv2" } serde = { version = "1.0.89", default-features = false, features = ["derive", "alloc"] } serde_json = { version = "1.0.64", default-features = false, features = ["alloc"] } -v1 = { path="../../../protocols/v1", package="sv1_api" } +v1 = { path="../../../stratum-protocols/v1", package="sv1_api" } num-bigint = "0.4.3" num-traits = "0.2.15" diff --git a/roles/test-utils/sv1-mining-device/src/client.rs b/stratum-roles/test-utils/sv1-mining-device/src/client.rs similarity index 100% rename from roles/test-utils/sv1-mining-device/src/client.rs rename to stratum-roles/test-utils/sv1-mining-device/src/client.rs diff --git a/roles/test-utils/sv1-mining-device/src/job.rs b/stratum-roles/test-utils/sv1-mining-device/src/job.rs similarity index 100% rename from roles/test-utils/sv1-mining-device/src/job.rs rename to stratum-roles/test-utils/sv1-mining-device/src/job.rs diff --git a/roles/test-utils/sv1-mining-device/src/main.rs b/stratum-roles/test-utils/sv1-mining-device/src/main.rs similarity index 100% rename from roles/test-utils/sv1-mining-device/src/main.rs rename to stratum-roles/test-utils/sv1-mining-device/src/main.rs diff --git a/roles/test-utils/sv1-mining-device/src/miner.rs b/stratum-roles/test-utils/sv1-mining-device/src/miner.rs similarity index 100% rename from roles/test-utils/sv1-mining-device/src/miner.rs rename to stratum-roles/test-utils/sv1-mining-device/src/miner.rs diff --git a/roles/translator/Cargo.toml b/stratum-roles/translator/Cargo.toml similarity index 70% rename from roles/translator/Cargo.toml rename to stratum-roles/translator/Cargo.toml index c7abf7048..a6e62bcd8 100644 --- a/roles/translator/Cargo.toml +++ b/stratum-roles/translator/Cargo.toml @@ -11,17 +11,17 @@ name = "translator_sv2" path = "src/lib/mod.rs" [dependencies] -stratum-common = { version = "1.0.0", path = "../../common" } +stratum-common = { version = "1.0.0", path = "../../stratum-common" } async-channel = "1.5.1" async-recursion = "0.3.2" async-std = { version = "1.12.0", features = ["attributes"] } -binary_sv2 = { version = "^1.0.0", path = "../../protocols/v2/binary-sv2/binary-sv2" } +binary_sv2 = { version = "^1.0.0", path = "../../stratum-protocols/v2/binary-sv2/binary-sv2" } buffer_sv2 = { version = "^1.0.0", path = "../../utils/buffer" } -codec_sv2 = { version = "^1.0.1", path = "../../protocols/v2/codec-sv2", features = ["noise_sv2", "with_buffer_pool"] } -framing_sv2 = { version = "^2.0.0", path = "../../protocols/v2/framing-sv2" } +codec_sv2 = { version = "^1.0.1", path = "../../stratum-protocols/v2/codec-sv2", features = ["noise_sv2", "with_buffer_pool"] } +framing_sv2 = { version = "^2.0.0", path = "../../stratum-protocols/v2/framing-sv2" } network_helpers_sv2 = { version = "2.0.0", path = "../roles-utils/network-helpers", features=["async_std", "with_buffer_pool"] } once_cell = "1.12.0" -roles_logic_sv2 = { version = "^1.0.0", path = "../../protocols/v2/roles-logic-sv2" } +roles_logic_sv2 = { version = "^1.0.0", path = "../../stratum-protocols/v2/roles-logic-sv2" } serde = { version = "1.0.89", default-features = false, features = ["derive", "alloc"] } serde_json = { version = "1.0.64", default-features = false, features = ["alloc"] } futures = "0.3.25" @@ -29,7 +29,7 @@ tokio = { version = "1", features = ["full"] } ext-config = { version = "0.14.0", features = ["toml"], package = "config" } tracing = { version = "0.1" } tracing-subscriber = { version = "0.3" } -v1 = { version = "^1.0.0", path = "../../protocols/v1", package="sv1_api" } +v1 = { version = "^1.0.0", path = "../../stratum-protocols/v1", package="sv1_api" } error_handling = { version = "1.0.0", path = "../../utils/error-handling" } key-utils = { version = "^1.0.0", path = "../../utils/key-utils" } tokio-util = { version = "0.7.10", features = ["codec"] } diff --git a/roles/translator/Dockerfile.dev b/stratum-roles/translator/Dockerfile.dev similarity index 100% rename from roles/translator/Dockerfile.dev rename to stratum-roles/translator/Dockerfile.dev diff --git a/roles/translator/README.md b/stratum-roles/translator/README.md similarity index 100% rename from roles/translator/README.md rename to stratum-roles/translator/README.md diff --git a/roles/translator/config-examples/tproxy-config-hosted-pool-example.toml b/stratum-roles/translator/config-examples/tproxy-config-hosted-pool-example.toml similarity index 100% rename from roles/translator/config-examples/tproxy-config-hosted-pool-example.toml rename to stratum-roles/translator/config-examples/tproxy-config-hosted-pool-example.toml diff --git a/roles/translator/config-examples/tproxy-config-local-jdc-example.toml b/stratum-roles/translator/config-examples/tproxy-config-local-jdc-example.toml similarity index 100% rename from roles/translator/config-examples/tproxy-config-local-jdc-example.toml rename to stratum-roles/translator/config-examples/tproxy-config-local-jdc-example.toml diff --git a/roles/translator/config-examples/tproxy-config-local-pool-example.toml b/stratum-roles/translator/config-examples/tproxy-config-local-pool-example.toml similarity index 100% rename from roles/translator/config-examples/tproxy-config-local-pool-example.toml rename to stratum-roles/translator/config-examples/tproxy-config-local-pool-example.toml diff --git a/roles/translator/src/args.rs b/stratum-roles/translator/src/args.rs similarity index 100% rename from roles/translator/src/args.rs rename to stratum-roles/translator/src/args.rs diff --git a/roles/translator/src/lib/downstream_sv1/diff_management.rs b/stratum-roles/translator/src/lib/downstream_sv1/diff_management.rs similarity index 100% rename from roles/translator/src/lib/downstream_sv1/diff_management.rs rename to stratum-roles/translator/src/lib/downstream_sv1/diff_management.rs diff --git a/roles/translator/src/lib/downstream_sv1/downstream.rs b/stratum-roles/translator/src/lib/downstream_sv1/downstream.rs similarity index 100% rename from roles/translator/src/lib/downstream_sv1/downstream.rs rename to stratum-roles/translator/src/lib/downstream_sv1/downstream.rs diff --git a/roles/translator/src/lib/downstream_sv1/mod.rs b/stratum-roles/translator/src/lib/downstream_sv1/mod.rs similarity index 100% rename from roles/translator/src/lib/downstream_sv1/mod.rs rename to stratum-roles/translator/src/lib/downstream_sv1/mod.rs diff --git a/roles/translator/src/lib/error.rs b/stratum-roles/translator/src/lib/error.rs similarity index 100% rename from roles/translator/src/lib/error.rs rename to stratum-roles/translator/src/lib/error.rs diff --git a/roles/translator/src/lib/mod.rs b/stratum-roles/translator/src/lib/mod.rs similarity index 100% rename from roles/translator/src/lib/mod.rs rename to stratum-roles/translator/src/lib/mod.rs diff --git a/roles/translator/src/lib/proxy/bridge.rs b/stratum-roles/translator/src/lib/proxy/bridge.rs similarity index 100% rename from roles/translator/src/lib/proxy/bridge.rs rename to stratum-roles/translator/src/lib/proxy/bridge.rs diff --git a/roles/translator/src/lib/proxy/mod.rs b/stratum-roles/translator/src/lib/proxy/mod.rs similarity index 100% rename from roles/translator/src/lib/proxy/mod.rs rename to stratum-roles/translator/src/lib/proxy/mod.rs diff --git a/roles/translator/src/lib/proxy/next_mining_notify.rs b/stratum-roles/translator/src/lib/proxy/next_mining_notify.rs similarity index 100% rename from roles/translator/src/lib/proxy/next_mining_notify.rs rename to stratum-roles/translator/src/lib/proxy/next_mining_notify.rs diff --git a/roles/translator/src/lib/proxy_config.rs b/stratum-roles/translator/src/lib/proxy_config.rs similarity index 100% rename from roles/translator/src/lib/proxy_config.rs rename to stratum-roles/translator/src/lib/proxy_config.rs diff --git a/roles/translator/src/lib/status.rs b/stratum-roles/translator/src/lib/status.rs similarity index 100% rename from roles/translator/src/lib/status.rs rename to stratum-roles/translator/src/lib/status.rs diff --git a/roles/translator/src/lib/upstream_sv2/diff_management.rs b/stratum-roles/translator/src/lib/upstream_sv2/diff_management.rs similarity index 100% rename from roles/translator/src/lib/upstream_sv2/diff_management.rs rename to stratum-roles/translator/src/lib/upstream_sv2/diff_management.rs diff --git a/roles/translator/src/lib/upstream_sv2/mod.rs b/stratum-roles/translator/src/lib/upstream_sv2/mod.rs similarity index 100% rename from roles/translator/src/lib/upstream_sv2/mod.rs rename to stratum-roles/translator/src/lib/upstream_sv2/mod.rs diff --git a/roles/translator/src/lib/upstream_sv2/upstream.rs b/stratum-roles/translator/src/lib/upstream_sv2/upstream.rs similarity index 100% rename from roles/translator/src/lib/upstream_sv2/upstream.rs rename to stratum-roles/translator/src/lib/upstream_sv2/upstream.rs diff --git a/roles/translator/src/lib/upstream_sv2/upstream_connection.rs b/stratum-roles/translator/src/lib/upstream_sv2/upstream_connection.rs similarity index 100% rename from roles/translator/src/lib/upstream_sv2/upstream_connection.rs rename to stratum-roles/translator/src/lib/upstream_sv2/upstream_connection.rs diff --git a/roles/translator/src/lib/utils.rs b/stratum-roles/translator/src/lib/utils.rs similarity index 100% rename from roles/translator/src/lib/utils.rs rename to stratum-roles/translator/src/lib/utils.rs diff --git a/roles/translator/src/main.rs b/stratum-roles/translator/src/main.rs similarity index 100% rename from roles/translator/src/main.rs rename to stratum-roles/translator/src/main.rs diff --git a/utils/bip32-key-derivation/Cargo.toml b/utils/bip32-key-derivation/Cargo.toml index a2d0681e4..1d30c34f7 100644 --- a/utils/bip32-key-derivation/Cargo.toml +++ b/utils/bip32-key-derivation/Cargo.toml @@ -15,7 +15,7 @@ name = "bip32_derivation-bin" path = "src/main.rs" [dependencies] -stratum-common = { version="1.0.0", path = "../../common", features=["bitcoin"]} +stratum-common = { version="1.0.0", path = "../../stratum-common", features=["bitcoin"]} slip132 = "0.10" [dev-dependencies]