From 2a1d37dd22b8739c0919c1b097bcd4f6ed84c9b5 Mon Sep 17 00:00:00 2001 From: Simon Wicky Date: Tue, 21 May 2024 16:31:19 +0200 Subject: [PATCH] update crypto and rand crates --- Cargo.lock | 268 +++----- Cargo.toml | 10 +- clients/native/Cargo.toml | 2 +- clients/socks5/Cargo.toml | 2 +- common/bandwidth-controller/Cargo.toml | 2 +- common/client-core/Cargo.toml | 2 +- common/client-libs/gateway-client/Cargo.toml | 2 +- common/credentials/Cargo.toml | 2 +- common/crypto/Cargo.toml | 10 +- .../crypto/src/asymmetric/encryption/mod.rs | 15 +- common/crypto/src/asymmetric/identity/mod.rs | 36 +- common/crypto/src/shared_key.rs | 4 +- common/node-tester-utils/Cargo.toml | 2 +- common/nymsphinx/Cargo.toml | 2 +- common/nymsphinx/acknowledgements/Cargo.toml | 2 +- common/nymsphinx/addressing/Cargo.toml | 2 +- common/nymsphinx/anonymous-replies/Cargo.toml | 4 +- common/nymsphinx/chunking/Cargo.toml | 2 +- common/nymsphinx/cover/Cargo.toml | 2 +- common/nymsphinx/types/src/lib.rs | 2 +- common/socks5-client-core/Cargo.toml | 2 +- common/topology/Cargo.toml | 2 +- common/wasm/client-core/Cargo.toml | 2 +- common/wireguard-types/Cargo.toml | 2 +- contracts/Cargo.lock | 634 ++++++++---------- contracts/coconut-test/Cargo.toml | 2 +- .../Cargo.toml | 2 +- contracts/mixnet/Cargo.toml | 2 +- contracts/name-service/Cargo.toml | 2 +- .../service-provider-directory/Cargo.toml | 2 +- gateway/Cargo.toml | 2 +- gateway/gateway-requests/Cargo.toml | 2 +- .../src/registration/handshake/shared_key.rs | 8 +- gateway/gateway-requests/src/types.rs | 2 +- mixnode/Cargo.toml | 2 +- nym-api/Cargo.toml | 4 +- nym-api/src/coconut/tests/fixtures.rs | 14 +- nym-api/src/coconut/tests/mod.rs | 6 +- nym-api/src/network_monitor/chunker.rs | 2 +- nym-api/src/network_monitor/mod.rs | 2 +- .../src/network_monitor/monitor/preparer.rs | 2 +- nym-api/src/support/config/helpers.rs | 3 +- nym-connect/desktop/Cargo.lock | 309 +++------ nym-connect/desktop/src-tauri/Cargo.toml | 15 +- .../desktop/src-tauri/src/config/mod.rs | 4 +- .../src/operations/directory/gateways.rs | 2 +- nym-node/Cargo.toml | 2 +- nym-node/nym-node-http-api/Cargo.toml | 2 +- nym-node/nym-node-requests/Cargo.toml | 2 +- nym-outfox/Cargo.toml | 2 +- nym-outfox/src/format.rs | 2 +- nym-outfox/tests/unittests.rs | 2 +- nym-wallet/Cargo.lock | 211 ++---- nym-wallet/src-tauri/Cargo.toml | 2 +- nym-wallet/src-tauri/src/error.rs | 4 - sdk/lib/socks5-listener/Cargo.toml | 2 +- sdk/rust/nym-sdk/Cargo.toml | 2 +- .../network-requester/Cargo.toml | 2 +- wasm/client/Cargo.toml | 2 +- wasm/mix-fetch/Cargo.toml | 2 +- wasm/node-tester/Cargo.toml | 2 +- 61 files changed, 647 insertions(+), 998 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 2c9cd69d32..1c6b60125c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -43,19 +43,6 @@ dependencies = [ "generic-array 0.14.7", ] -[[package]] -name = "aes" -version = "0.7.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e8b47f52ea9bae42228d07ec09eb676433d7c4ed1ebdf0f1d1c29ed446f1ab8" -dependencies = [ - "cfg-if", - "cipher 0.3.0", - "cpufeatures", - "ctr 0.8.0", - "opaque-debug 0.3.1", -] - [[package]] name = "aes" version = "0.8.4" @@ -63,7 +50,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b169f7a6d4742236a0a00c541b845991d0ac43e546831af1249753ab4c3aa3a0" dependencies = [ "cfg-if", - "cipher 0.4.4", + "cipher", "cpufeatures", ] @@ -74,9 +61,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "831010a0f742e1209b3bcea8fab6a8e149051ba6099432c8cb2cc117dec3ead1" dependencies = [ "aead", - "aes 0.8.4", - "cipher 0.4.4", - "ctr 0.9.2", + "aes", + "cipher", + "ctr", "ghash", "subtle 2.5.0", ] @@ -537,7 +524,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7e141fb0f8be1c7b45887af94c88b182472b57c96b56773250ae00cd6a14a164" dependencies = [ "bs58 0.5.1", - "hmac 0.12.1", + "hmac", "k256", "once_cell", "pbkdf2", @@ -599,7 +586,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94cb07b0da6a73955f8fb85d24c466778e70cda767a568229b104f0264089330" dependencies = [ "byte-tools", - "crypto-mac 0.7.0", + "crypto-mac", "digest 0.8.1", "opaque-debug 0.2.3", ] @@ -827,7 +814,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c3613f74bd2eac03dad61bd53dbe620703d4371614fe0bc3b9f04dd36fe4e818" dependencies = [ "cfg-if", - "cipher 0.4.4", + "cipher", "cpufeatures", ] @@ -839,7 +826,7 @@ checksum = "10cd79432192d1c0f4e1a0fef9527696cc039165d729fb41b3f4f4f354c2dc35" dependencies = [ "aead", "chacha20", - "cipher 0.4.4", + "cipher", "poly1305", "zeroize", ] @@ -886,15 +873,6 @@ dependencies = [ "half", ] -[[package]] -name = "cipher" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ee52072ec15386f770805afd189a01c8841be8696bed250fa2f13c4c0d6dfb7" -dependencies = [ - "generic-array 0.14.7", -] - [[package]] name = "cipher" version = "0.4.4" @@ -1188,7 +1166,7 @@ dependencies = [ "rand_core 0.6.4", "serde", "serde_json", - "signature 2.2.0", + "signature", "subtle-encoding", "tendermint", "thiserror", @@ -1207,7 +1185,7 @@ dependencies = [ "rand_core 0.6.4", "serde", "serde_json", - "signature 2.2.0", + "signature", "subtle-encoding", "tendermint", "tendermint-rpc", @@ -1473,16 +1451,6 @@ dependencies = [ "subtle 1.0.0", ] -[[package]] -name = "crypto-mac" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25fab6889090c8133f3deb8f73ba3c65a7f456f66436fc012a1b1e272b1e103e" -dependencies = [ - "generic-array 0.14.7", - "subtle 2.5.0", -] - [[package]] name = "csv" version = "1.3.0" @@ -1504,22 +1472,13 @@ dependencies = [ "memchr", ] -[[package]] -name = "ctr" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "049bb91fb4aaf0e3c7efa6cd5ef877dbbbd15b39dad06d9948de4ec8a75761ea" -dependencies = [ - "cipher 0.3.0", -] - [[package]] name = "ctr" version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0369ee1ad671834580515889b80f2ea915f23b8be8d0daa4bbaf2ac5c7590835" dependencies = [ - "cipher 0.4.4", + "cipher", ] [[package]] @@ -1571,7 +1530,6 @@ dependencies = [ "byteorder", "digest 0.9.0", "rand_core 0.5.1", - "serde", "subtle 2.5.0", "zeroize", ] @@ -1585,9 +1543,11 @@ dependencies = [ "cfg-if", "cpufeatures", "curve25519-dalek-derive", + "digest 0.10.7", "fiat-crypto", "platforms", "rustc_version 0.4.0", + "serde", "subtle 2.5.0", "zeroize", ] @@ -1985,20 +1945,10 @@ dependencies = [ "elliptic-curve", "rfc6979", "serdect", - "signature 2.2.0", + "signature", "spki", ] -[[package]] -name = "ed25519" -version = "1.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" -dependencies = [ - "serde", - "signature 1.6.4", -] - [[package]] name = "ed25519" version = "2.2.3" @@ -2006,7 +1956,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "115531babc129696a58c64a4fef0a8bf9e9698629fb97e9e40767d235cfbcd53" dependencies = [ "pkcs8", - "signature 2.2.0", + "serde", + "signature", ] [[package]] @@ -2024,16 +1975,16 @@ dependencies = [ [[package]] name = "ed25519-dalek" -version = "1.0.1" +version = "2.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" +checksum = "4a3daa8e81a3963a60642bcc1f90a670680bd4a77535faa384e9d1c79d620871" dependencies = [ - "curve25519-dalek 3.2.0", - "ed25519 1.5.3", - "rand 0.7.3", + "curve25519-dalek 4.1.2", + "ed25519", + "rand_core 0.6.4", "serde", - "serde_bytes", - "sha2 0.9.9", + "sha2 0.10.8", + "subtle 2.5.0", "zeroize", ] @@ -2825,33 +2776,13 @@ dependencies = [ "winapi", ] -[[package]] -name = "hkdf" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01706d578d5c281058480e673ae4086a9f4710d8df1ad80a5b03e39ece5f886b" -dependencies = [ - "digest 0.9.0", - "hmac 0.11.0", -] - [[package]] name = "hkdf" version = "0.12.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7b5f8eb2ad728638ea2c7d47a21db23b7b58a72ed6a38256b8a1849f15fbbdf7" dependencies = [ - "hmac 0.12.1", -] - -[[package]] -name = "hmac" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a2a2320eb7ec0ebe8da8f744d7812d9fc4cb4d09344ac01898dbcb6a20ae69b" -dependencies = [ - "crypto-mac 0.11.0", - "digest 0.9.0", + "hmac", ] [[package]] @@ -3409,7 +3340,7 @@ dependencies = [ "elliptic-curve", "once_cell", "sha2 0.10.8", - "signature 2.2.0", + "signature", ] [[package]] @@ -3688,7 +3619,7 @@ dependencies = [ "nym-ordered-buffer", "nym-service-providers-common", "nym-socks5-requests", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde-wasm-bindgen 0.6.5", "thiserror", @@ -3978,9 +3909,7 @@ dependencies = [ "nym-vesting-contract-common", "okapi", "pin-project", - "rand 0.7.3", "rand 0.8.5", - "rand_chacha 0.2.2", "rand_chacha 0.3.1", "reqwest 0.12.4", "rocket", @@ -4046,7 +3975,7 @@ dependencies = [ "nym-crypto", "nym-network-defaults", "nym-validator-client", - "rand 0.7.3", + "rand 0.8.5", "thiserror", "url", "zeroize", @@ -4196,7 +4125,7 @@ dependencies = [ "nym-task", "nym-topology", "nym-validator-client", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde_json", "tap", @@ -4244,7 +4173,7 @@ dependencies = [ "nym-task", "nym-topology", "nym-validator-client", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde_json", "sha2 0.10.8", @@ -4324,7 +4253,7 @@ dependencies = [ "nym-bin-common", "nym-node-tester-utils", "nym-node-tester-wasm", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde-wasm-bindgen 0.6.5", "serde_json", @@ -4467,7 +4396,7 @@ dependencies = [ "nym-credentials-interface", "nym-crypto", "nym-validator-client", - "rand 0.7.3", + "rand 0.8.5", "serde", "thiserror", "time", @@ -4488,25 +4417,25 @@ dependencies = [ name = "nym-crypto" version = "0.4.0" dependencies = [ - "aes 0.8.4", + "aes", "blake3", "bs58 0.5.1", - "cipher 0.4.4", - "ctr 0.9.2", + "cipher", + "ctr", "digest 0.10.7", "ed25519-dalek", "generic-array 0.14.7", - "hkdf 0.12.4", - "hmac 0.12.1", + "hkdf", + "hmac", "nym-pemstore", "nym-sphinx-types", - "rand 0.7.3", - "rand_chacha 0.2.2", + "rand 0.8.5", + "rand_chacha 0.3.1", "serde", "serde_bytes", "subtle-encoding", "thiserror", - "x25519-dalek 1.1.1", + "x25519-dalek", "zeroize", ] @@ -4628,7 +4557,7 @@ dependencies = [ "nym-wireguard", "nym-wireguard-types", "once_cell", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde_json", "sqlx", @@ -4661,7 +4590,7 @@ dependencies = [ "nym-sphinx", "nym-task", "nym-validator-client", - "rand 0.7.3", + "rand 0.8.5", "serde", "si-scale", "thiserror", @@ -4690,7 +4619,7 @@ dependencies = [ "nym-crypto", "nym-pemstore", "nym-sphinx", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde_json", "thiserror", @@ -4918,7 +4847,7 @@ dependencies = [ "nym-topology", "nym-types", "nym-validator-client", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde_json", "sysinfo 0.27.8", @@ -5040,7 +4969,7 @@ dependencies = [ "nym-types", "pretty_env_logger", "publicsuffix", - "rand 0.7.3", + "rand 0.8.5", "regex", "reqwest 0.12.4", "serde", @@ -5102,7 +5031,7 @@ dependencies = [ "nym-task", "nym-types", "nym-wireguard-types", - "rand 0.7.3", + "rand 0.8.5", "semver 1.0.23", "serde", "serde_json", @@ -5126,7 +5055,7 @@ dependencies = [ "dashmap", "fastrand 2.1.0", "headers", - "hmac 0.12.1", + "hmac", "hyper 1.3.1", "ipnetwork 0.16.0", "nym-crypto", @@ -5136,7 +5065,7 @@ dependencies = [ "nym-task", "nym-wireguard", "nym-wireguard-types", - "rand 0.7.3", + "rand 0.8.5", "serde_json", "thiserror", "time", @@ -5146,7 +5075,7 @@ dependencies = [ "tracing", "utoipa", "utoipa-swagger-ui", - "x25519-dalek 2.0.1", + "x25519-dalek", ] [[package]] @@ -5163,7 +5092,7 @@ dependencies = [ "nym-exit-policy", "nym-http-api-client", "nym-wireguard-types", - "rand_chacha 0.2.2", + "rand_chacha 0.3.1", "schemars", "serde", "serde_json", @@ -5184,7 +5113,7 @@ dependencies = [ "nym-sphinx-params", "nym-task", "nym-topology", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde_json", "thiserror", @@ -5199,7 +5128,7 @@ dependencies = [ "futures", "js-sys", "nym-node-tester-utils", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde-wasm-bindgen 0.6.5", "thiserror", @@ -5254,11 +5183,11 @@ dependencies = [ "chacha20", "chacha20poly1305", "criterion", - "curve25519-dalek 3.2.0", + "curve25519-dalek 4.1.2", "fastrand 1.9.0", "getrandom 0.2.15", "log", - "rand 0.7.3", + "rand 0.8.5", "rayon", "sphinx-packet", "thiserror", @@ -5306,7 +5235,7 @@ dependencies = [ "nym-validator-client", "parking_lot 0.12.2", "pretty_env_logger", - "rand 0.7.3", + "rand 0.8.5", "reqwest 0.12.4", "tap", "thiserror", @@ -5368,7 +5297,7 @@ dependencies = [ "nym-socks5-client-core", "nym-sphinx", "nym-topology", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde_json", "tap", @@ -5401,7 +5330,7 @@ dependencies = [ "nym-task", "nym-validator-client", "pin-project", - "rand 0.7.3", + "rand 0.8.5", "reqwest 0.12.4", "schemars", "serde", @@ -5427,7 +5356,7 @@ dependencies = [ "nym-credential-storage", "nym-crypto", "nym-socks5-client-core", - "rand 0.7.3", + "rand 0.8.5", "safer-ffi", "serde", "tokio", @@ -5481,7 +5410,7 @@ dependencies = [ "nym-sphinx-routing", "nym-sphinx-types", "nym-topology", - "rand 0.7.3", + "rand 0.8.5", "rand_distr", "thiserror", "tokio", @@ -5499,7 +5428,7 @@ dependencies = [ "nym-sphinx-routing", "nym-sphinx-types", "nym-topology", - "rand 0.7.3", + "rand 0.8.5", "serde", "thiserror", "zeroize", @@ -5511,7 +5440,7 @@ version = "0.1.0" dependencies = [ "nym-crypto", "nym-sphinx-types", - "rand 0.7.3", + "rand 0.8.5", "serde", "thiserror", ] @@ -5527,8 +5456,8 @@ dependencies = [ "nym-sphinx-routing", "nym-sphinx-types", "nym-topology", - "rand 0.7.3", - "rand_chacha 0.2.2", + "rand 0.8.5", + "rand_chacha 0.3.1", "serde", "thiserror", "wasm-bindgen", @@ -5542,7 +5471,7 @@ dependencies = [ "nym-sphinx-addressing", "nym-sphinx-params", "nym-sphinx-types", - "rand 0.7.3", + "rand 0.8.5", "thiserror", ] @@ -5559,7 +5488,7 @@ dependencies = [ "nym-sphinx-routing", "nym-sphinx-types", "nym-topology", - "rand 0.7.3", + "rand 0.8.5", "thiserror", ] @@ -5670,7 +5599,7 @@ dependencies = [ "nym-sphinx-addressing", "nym-sphinx-routing", "nym-sphinx-types", - "rand 0.7.3", + "rand 0.8.5", "semver 0.11.0", "serde", "serde_json", @@ -5700,7 +5629,7 @@ dependencies = [ "cosmrs 0.15.0 (git+https://github.com/jstuczyn/cosmos-rust?branch=nym-temp/all-validator-features)", "cosmwasm-std", "eyre", - "hmac 0.12.1", + "hmac", "itertools 0.11.0", "log", "nym-config", @@ -5718,7 +5647,7 @@ dependencies = [ "thiserror", "ts-rs", "url", - "x25519-dalek 2.0.1", + "x25519-dalek", ] [[package]] @@ -5850,7 +5779,7 @@ dependencies = [ "nym-task", "nym-wireguard-types", "tokio", - "x25519-dalek 2.0.1", + "x25519-dalek", ] [[package]] @@ -5859,18 +5788,18 @@ version = "0.1.0" dependencies = [ "base64 0.21.7", "dashmap", - "hmac 0.12.1", + "hmac", "log", "nym-config", "nym-crypto", "nym-network-defaults", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde_json", "sha2 0.10.8", "thiserror", "utoipa", - "x25519-dalek 2.0.1", + "x25519-dalek", ] [[package]] @@ -6194,7 +6123,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" dependencies = [ "digest 0.10.7", - "hmac 0.12.1", + "hmac", ] [[package]] @@ -6753,12 +6682,12 @@ dependencies = [ [[package]] name = "rand_distr" -version = "0.3.0" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9e9532ada3929fb8b2e9dbe28d1e06c9b2cc65813f074fcb6bd5fbefeff9d56" +checksum = "32cb0b9bc82b0a0876c2dd994a7e7a2683d3e7390ca40e6886785ef0c7e3ee31" dependencies = [ "num-traits", - "rand 0.7.3", + "rand 0.8.5", ] [[package]] @@ -7072,7 +7001,7 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f8dd2a808d456c4a54e300a23e9f5a67e122c3024119acbfd73e3bf664491cb2" dependencies = [ - "hmac 0.12.1", + "hmac", "subtle 2.5.0", ] @@ -7864,12 +7793,6 @@ dependencies = [ "libc", ] -[[package]] -name = "signature" -version = "1.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" - [[package]] name = "signature" version = "2.2.0" @@ -7940,25 +7863,26 @@ dependencies = [ [[package]] name = "sphinx-packet" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc43eda802856ee82a7555c7b75ceb9e07451741c7a2f5f23d036020e01189d4" +checksum = "dabeca95bf5fd0563d6be7ebcb1c6a9fcb135746a0ba9050c47dc68c8607e595" dependencies = [ - "aes 0.7.5", + "aes", "arrayref", "blake2 0.8.1", - "bs58 0.4.0", + "bs58 0.5.1", "byteorder", "chacha", - "curve25519-dalek 3.2.0", - "digest 0.9.0", - "hkdf 0.11.0", - "hmac 0.11.0", + "ctr", + "curve25519-dalek 4.1.2", + "digest 0.10.7", + "hkdf", + "hmac", "lioness", "log", - "rand 0.7.3", + "rand 0.8.5", "rand_distr", - "sha2 0.9.9", + "sha2 0.10.8", "subtle 2.5.0", ] @@ -8349,7 +8273,7 @@ checksum = "15ab8f0a25d0d2ad49ac615da054d6a76aa6603ff95f7d18bafdd34450a1a04b" dependencies = [ "bytes", "digest 0.10.7", - "ed25519 2.2.3", + "ed25519", "ed25519-consensus", "flex-error", "futures", @@ -8364,7 +8288,7 @@ dependencies = [ "serde_json", "serde_repr", "sha2 0.10.8", - "signature 2.2.0", + "signature", "subtle 2.5.0", "subtle-encoding", "tendermint-proto", @@ -9500,7 +9424,7 @@ dependencies = [ "nym-task", "nym-topology", "nym-validator-client", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde-wasm-bindgen 0.6.5", "thiserror", @@ -9956,18 +9880,6 @@ dependencies = [ "tap", ] -[[package]] -name = "x25519-dalek" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a0c105152107e3b96f6a00a65e86ce82d9b125230e1c4302940eca58ff71f4f" -dependencies = [ - "curve25519-dalek 3.2.0", - "rand_core 0.5.1", - "serde", - "zeroize", -] - [[package]] name = "x25519-dalek" version = "2.0.1" diff --git a/Cargo.toml b/Cargo.toml index 75a8e1eaf0..45cfe0955c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -172,7 +172,7 @@ bincode = "1.3.3" bip39 = { version = "2.0.0", features = ["zeroize"] } bitvec = "1.0.0" blake3 = "1.3.1" -bs58 = "0.5.0" +bs58 = "0.5.1" bytecodec = "0.4.15" bytes = "1.5.0" cargo_metadata = "0.18.1" @@ -195,13 +195,13 @@ criterion = "0.4" csv = "1.3.0" ctr = "0.9.1" cupid = "0.6.1" -curve25519-dalek = "3.2" +curve25519-dalek = "4.1" dashmap = "5.5.3" defguard_wireguard_rs = { git = "https://github.com/neacsu/wireguard-rs.git", rev = "c2cd0c1119f699f4bc43f5e6ffd6fc242caa42ed" } doc-comment = "0.3" dotenvy = "0.15.6" ecdsa = "0.16" -ed25519-dalek = "1.0" +ed25519-dalek = "2.1" etherparse = "0.13.0" eyre = "0.6.9" flate2 = "1.0.28" @@ -247,7 +247,7 @@ rand = "0.8.5" rand-07 = "0.7.3" rand_chacha_02 = "0.2" rand_core = "0.6.3" -rand_distr = "0.3" +rand_distr = "0.4" rand_pcg = "0.3.1" rand_seeder = "0.2.3" rayon = "1.5.1" @@ -266,7 +266,7 @@ serde_repr = "0.1" serde_with = "3.4.0" serde_yaml = "0.9.25" si-scale = "0.2.2" -sphinx-packet = "0.1.0" +sphinx-packet = "0.1.1" sqlx = "0.6.3" strum = "0.25" subtle-encoding = "0.5" diff --git a/clients/native/Cargo.toml b/clients/native/Cargo.toml index 0852b42dd4..23692d8cc1 100644 --- a/clients/native/Cargo.toml +++ b/clients/native/Cargo.toml @@ -25,7 +25,7 @@ bs58 = { workspace = true } clap = { workspace = true, features = ["cargo", "derive"] } dirs = "4.0" log = { workspace = true } # self explanatory -rand = { version = "0.7.3", features = ["wasm-bindgen"] } # rng-related traits + some rng implementation to use +rand = { workspace = true } serde = { workspace = true, features = ["derive"] } # for config serialization/deserialization serde_json = { workspace = true } thiserror = { workspace = true } diff --git a/clients/socks5/Cargo.toml b/clients/socks5/Cargo.toml index 92ce134d53..26d8b5316e 100644 --- a/clients/socks5/Cargo.toml +++ b/clients/socks5/Cargo.toml @@ -16,7 +16,7 @@ serde_json = { workspace = true } tap = { workspace = true } thiserror = { workspace = true } tokio = { workspace = true, features = ["rt-multi-thread", "net", "signal"] } -rand = "0.7.3" +rand = { workspace = true } time = { workspace = true } url = { workspace = true } zeroize = { workspace = true } diff --git a/common/bandwidth-controller/Cargo.toml b/common/bandwidth-controller/Cargo.toml index 284ccbfc77..b122849639 100644 --- a/common/bandwidth-controller/Cargo.toml +++ b/common/bandwidth-controller/Cargo.toml @@ -9,7 +9,7 @@ license.workspace = true [dependencies] bip39 = { workspace = true } log = { workspace = true } -rand = "0.7.3" +rand = { workspace = true } thiserror = { workspace = true } url = { workspace = true } zeroize = { workspace = true } diff --git a/common/client-core/Cargo.toml b/common/client-core/Cargo.toml index 6efec53df6..6462e98154 100644 --- a/common/client-core/Cargo.toml +++ b/common/client-core/Cargo.toml @@ -17,7 +17,7 @@ clap = { workspace = true, optional = true } futures = { workspace = true } humantime-serde = { workspace = true } log = { workspace = true } -rand = { version = "0.7.3", features = ["wasm-bindgen"] } +rand = { workspace = true } serde = { workspace = true, features = ["derive"] } serde_json = { workspace = true } sha2 = "0.10.6" diff --git a/common/client-libs/gateway-client/Cargo.toml b/common/client-libs/gateway-client/Cargo.toml index 21123588e1..9eb2e96402 100644 --- a/common/client-libs/gateway-client/Cargo.toml +++ b/common/client-libs/gateway-client/Cargo.toml @@ -14,7 +14,7 @@ futures = { workspace = true } log = { workspace = true } thiserror = { workspace = true } url = { workspace = true } -rand = { version = "0.7.3", features = ["wasm-bindgen"] } +rand = { workspace = true } tokio = { workspace = true, features = ["macros"] } si-scale = { workspace = true } time.workspace = true diff --git a/common/credentials/Cargo.toml b/common/credentials/Cargo.toml index 11d1a4b82e..a51604a142 100644 --- a/common/credentials/Cargo.toml +++ b/common/credentials/Cargo.toml @@ -23,5 +23,5 @@ nym-api-requests = { path = "../../nym-api/nym-api-requests" } nym-validator-client = { path = "../client-libs/validator-client", default-features = false } [dev-dependencies] -rand = "0.7.3" +rand = "0.8.5" diff --git a/common/crypto/Cargo.toml b/common/crypto/Cargo.toml index a34403598f..09a7e413fd 100644 --- a/common/crypto/Cargo.toml +++ b/common/crypto/Cargo.toml @@ -17,10 +17,10 @@ generic-array = { workspace = true, optional = true } hkdf = { workspace = true, optional = true } hmac = { workspace = true, optional = true } cipher = { workspace = true, optional = true } -x25519-dalek = { version = "1.1", optional = true } -ed25519-dalek = { workspace = true, optional = true } -rand = { version = "0.7.3", features = ["wasm-bindgen"], optional = true } -serde_bytes = { workspace = true, optional = true } +x25519-dalek = { version = "2.0", optional = true, features = ["static_secrets"]} +ed25519-dalek = { version = "2.1", features = ["rand_core"], optional = true } +rand = { workspace = true, optional = true } +serde_bytes = { version = "0.11.6", optional = true } serde_crate = { version = "1.0", optional = true, default_features = false, features = ["derive"], package = "serde" } subtle-encoding = { workspace = true, features = ["bech32-preview"] } thiserror = { workspace = true } @@ -31,7 +31,7 @@ nym-sphinx-types = { path = "../nymsphinx/types", version = "0.2.0", default-fea nym-pemstore = { path = "../../common/pemstore", version = "0.3.0" } [dev-dependencies] -rand_chacha = "0.2" +rand_chacha = "0.3" [features] default = ["sphinx"] diff --git a/common/crypto/src/asymmetric/encryption/mod.rs b/common/crypto/src/asymmetric/encryption/mod.rs index 7f24ffcf44..cadb5437e4 100644 --- a/common/crypto/src/asymmetric/encryption/mod.rs +++ b/common/crypto/src/asymmetric/encryption/mod.rs @@ -56,7 +56,7 @@ pub struct KeyPair { impl KeyPair { #[cfg(feature = "rand")] pub fn new(rng: &mut R) -> Self { - let private_key = x25519_dalek::StaticSecret::new(rng); + let private_key = x25519_dalek::StaticSecret::random_from_rng(rng); let public_key = (&private_key).into(); KeyPair { @@ -211,7 +211,7 @@ impl FromStr for PrivateKey { impl PrivateKey { #[cfg(feature = "rand")] pub fn new(rng: &mut R) -> Self { - let x25519_secret = x25519_dalek::StaticSecret::new(rng); + let x25519_secret = x25519_dalek::StaticSecret::random_from_rng(rng); PrivateKey(x25519_secret) } @@ -358,16 +358,23 @@ mod sphinx_key_conversion { let private = &keys.private_key; let public = &keys.public_key; - let private_bytes = private.to_bytes(); + let dummy_remote = KeyPair::new(&mut rng); + let dh1 = private.diffie_hellman(&dummy_remote.public_key); + let public_bytes = public.to_bytes(); let sphinx_private: nym_sphinx_types::PrivateKey = private.into(); let recovered_private = PrivateKey::from(sphinx_private); + let dh2 = recovered_private.diffie_hellman(&dummy_remote.public_key); + let sphinx_public: nym_sphinx_types::PublicKey = public.into(); let recovered_public = PublicKey::from(sphinx_public); - assert_eq!(private_bytes, recovered_private.to_bytes()); assert_eq!(public_bytes, recovered_public.to_bytes()); + + // even though the byte representation of the private key changed, the resultant DH is the same + // which is what matters + assert_eq!(dh1, dh2); } } diff --git a/common/crypto/src/asymmetric/identity/mod.rs b/common/crypto/src/asymmetric/identity/mod.rs index a9b8879069..f65290f907 100644 --- a/common/crypto/src/asymmetric/identity/mod.rs +++ b/common/crypto/src/asymmetric/identity/mod.rs @@ -1,8 +1,8 @@ // Copyright 2021-2023 - Nym Technologies SA // SPDX-License-Identifier: Apache-2.0 -pub use ed25519_dalek::ed25519::signature::Signature as SignatureTrait; pub use ed25519_dalek::SignatureError; +use ed25519_dalek::{Signer, SigningKey}; pub use ed25519_dalek::{Verifier, PUBLIC_KEY_LENGTH, SECRET_KEY_LENGTH, SIGNATURE_LENGTH}; use nym_pemstore::traits::{PemStorableKey, PemStorableKeyPair}; use std::fmt::{self, Display, Formatter}; @@ -30,6 +30,9 @@ pub enum Ed25519RecoveryError { #[error(transparent)] MalformedBytes(#[from] SignatureError), + #[error(transparent)] + BytesLengthError(#[from] std::array::TryFromSliceError), + #[error("the base58 representation of the public key was malformed - {source}")] MalformedPublicKeyString { #[source] @@ -64,11 +67,11 @@ pub struct KeyPair { impl KeyPair { #[cfg(feature = "rand")] pub fn new(rng: &mut R) -> Self { - let ed25519_keypair = ed25519_dalek::Keypair::generate(rng); + let ed25519_signing_key = ed25519_dalek::SigningKey::generate(rng); KeyPair { - private_key: PrivateKey(ed25519_keypair.secret), - public_key: PublicKey(ed25519_keypair.public), + private_key: PrivateKey(ed25519_signing_key.to_bytes()), + public_key: PublicKey(ed25519_signing_key.verifying_key()), } } @@ -109,7 +112,7 @@ impl PemStorableKeyPair for KeyPair { /// ed25519 EdDSA Public Key #[derive(Debug, Copy, Clone, Eq, PartialEq)] -pub struct PublicKey(ed25519_dalek::PublicKey); +pub struct PublicKey(ed25519_dalek::VerifyingKey); impl Display for PublicKey { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { @@ -135,7 +138,9 @@ impl PublicKey { } pub fn from_bytes(b: &[u8]) -> Result { - Ok(PublicKey(ed25519_dalek::PublicKey::from_bytes(b)?)) + Ok(PublicKey(ed25519_dalek::VerifyingKey::from_bytes( + b.try_into()?, + )?)) } pub fn to_base58_string(self) -> String { @@ -189,7 +194,7 @@ impl<'d> Deserialize<'d> for PublicKey { where D: Deserializer<'d>, { - Ok(PublicKey(ed25519_dalek::PublicKey::deserialize( + Ok(PublicKey(ed25519_dalek::VerifyingKey::deserialize( deserializer, )?)) } @@ -223,7 +228,7 @@ impl Display for PrivateKey { impl<'a> From<&'a PrivateKey> for PublicKey { fn from(pk: &'a PrivateKey) -> Self { - PublicKey((&pk.0).into()) + PublicKey(SigningKey::from_bytes(&pk.0).verifying_key()) } } @@ -238,7 +243,7 @@ impl FromStr for PrivateKey { impl PrivateKey { #[cfg(feature = "rand")] pub fn new(rng: &mut R) -> Self { - let ed25519_secret = ed25519_dalek::SecretKey::generate(rng); + let ed25519_secret = ed25519_dalek::SigningKey::generate(rng).to_bytes(); PrivateKey(ed25519_secret) } @@ -248,11 +253,11 @@ impl PrivateKey { } pub fn to_bytes(&self) -> [u8; SECRET_KEY_LENGTH] { - self.0.to_bytes() + self.0 } pub fn from_bytes(b: &[u8]) -> Result { - Ok(PrivateKey(ed25519_dalek::SecretKey::from_bytes(b)?)) + Ok(PrivateKey(b.try_into()?)) } pub fn to_base58_string(&self) -> String { @@ -267,9 +272,8 @@ impl PrivateKey { } pub fn sign>(&self, message: M) -> Signature { - let expanded_secret_key = ed25519_dalek::ExpandedSecretKey::from(&self.0); - let public_key: PublicKey = self.into(); - let sig = expanded_secret_key.sign(message.as_ref(), &public_key.0); + let signing_key: SigningKey = self.0.into(); + let sig = signing_key.sign(message.as_ref()); Signature(sig) } @@ -338,7 +342,9 @@ impl Signature { } pub fn from_bytes(bytes: &[u8]) -> Result { - Ok(Signature(ed25519_dalek::Signature::from_bytes(bytes)?)) + Ok(Signature(ed25519_dalek::Signature::from_bytes( + bytes.try_into()?, + ))) } } diff --git a/common/crypto/src/shared_key.rs b/common/crypto/src/shared_key.rs index 35ccf2432e..bcc707489b 100644 --- a/common/crypto/src/shared_key.rs +++ b/common/crypto/src/shared_key.rs @@ -3,11 +3,11 @@ use crate::asymmetric::encryption; use crate::hkdf; +#[cfg(feature = "rand")] +use cipher::crypto_common::rand_core::{CryptoRng, RngCore}; use cipher::{Key, KeyIvInit, StreamCipher}; use digest::crypto_common::BlockSizeUser; use digest::Digest; -#[cfg(feature = "rand")] -use rand::{CryptoRng, RngCore}; /// Generate an ephemeral encryption keypair and perform diffie-hellman to establish /// shared key with the remote. diff --git a/common/node-tester-utils/Cargo.toml b/common/node-tester-utils/Cargo.toml index 647453edfd..cdb2ddb994 100644 --- a/common/node-tester-utils/Cargo.toml +++ b/common/node-tester-utils/Cargo.toml @@ -8,7 +8,7 @@ license.workspace = true [dependencies] futures = { workspace = true } -rand = "0.7.3" +rand = { workspace = true } serde = { workspace = true } serde_json = { workspace = true } diff --git a/common/nymsphinx/Cargo.toml b/common/nymsphinx/Cargo.toml index ecdd83e298..40769d2ec6 100644 --- a/common/nymsphinx/Cargo.toml +++ b/common/nymsphinx/Cargo.toml @@ -9,7 +9,7 @@ repository = { workspace = true } [dependencies] log = { workspace = true } -rand = { version = "0.7.3", features = ["wasm-bindgen"] } +rand = { workspace = true } rand_distr = { workspace = true } thiserror = { workspace = true } diff --git a/common/nymsphinx/acknowledgements/Cargo.toml b/common/nymsphinx/acknowledgements/Cargo.toml index da9977d1f3..3d997c436f 100644 --- a/common/nymsphinx/acknowledgements/Cargo.toml +++ b/common/nymsphinx/acknowledgements/Cargo.toml @@ -8,7 +8,7 @@ license = { workspace = true } repository = { workspace = true } [dependencies] -rand = { version = "0.7.3", features = ["wasm-bindgen"] } +rand = { workspace = true } serde_crate = { version = "1.0", optional = true, default_features = false, features = ["derive"], package = "serde" } generic-array = { workspace = true, optional = true, features = ["serde"] } thiserror = { workspace = true } diff --git a/common/nymsphinx/addressing/Cargo.toml b/common/nymsphinx/addressing/Cargo.toml index 19ccdeb5b3..049dcd9a49 100644 --- a/common/nymsphinx/addressing/Cargo.toml +++ b/common/nymsphinx/addressing/Cargo.toml @@ -14,5 +14,5 @@ serde = { workspace = true } # implementing serialization/deserialization for so thiserror = { workspace = true } [dev-dependencies] -rand = "0.7" +rand = "0.8.5" nym-crypto = { path = "../../crypto", features = ["rand"] } diff --git a/common/nymsphinx/anonymous-replies/Cargo.toml b/common/nymsphinx/anonymous-replies/Cargo.toml index 9c057f31f5..9ece0e1085 100644 --- a/common/nymsphinx/anonymous-replies/Cargo.toml +++ b/common/nymsphinx/anonymous-replies/Cargo.toml @@ -8,7 +8,7 @@ license = { workspace = true } repository = { workspace = true } [dependencies] -rand = { version = "0.7.3", features = ["wasm-bindgen"] } +rand = { workspace = true } bs58 = { workspace = true } serde = { workspace = true } thiserror = { workspace = true } @@ -24,4 +24,4 @@ nym-topology = { path = "../../topology" } version = "0.2.83" [dev-dependencies] -rand_chacha = "0.2" +rand_chacha = "0.3" diff --git a/common/nymsphinx/chunking/Cargo.toml b/common/nymsphinx/chunking/Cargo.toml index 542c8d28e2..dc608a9718 100644 --- a/common/nymsphinx/chunking/Cargo.toml +++ b/common/nymsphinx/chunking/Cargo.toml @@ -11,7 +11,7 @@ repository = { workspace = true } [dependencies] log = { workspace = true } -rand = { version = "0.7.3", features = ["wasm-bindgen"] } +rand = { workspace = true } thiserror = { workspace = true } nym-sphinx-addressing = { path = "../addressing" } diff --git a/common/nymsphinx/cover/Cargo.toml b/common/nymsphinx/cover/Cargo.toml index d3da16d2db..59710923d1 100644 --- a/common/nymsphinx/cover/Cargo.toml +++ b/common/nymsphinx/cover/Cargo.toml @@ -8,7 +8,7 @@ license = { workspace = true } repository = { workspace = true } [dependencies] -rand = { version = "0.7.3", features = ["wasm-bindgen"] } +rand = { workspace = true } thiserror = { workspace = true } nym-crypto = { path = "../../crypto" } diff --git a/common/nymsphinx/types/src/lib.rs b/common/nymsphinx/types/src/lib.rs index d75060e9b0..05232c0483 100644 --- a/common/nymsphinx/types/src/lib.rs +++ b/common/nymsphinx/types/src/lib.rs @@ -15,7 +15,7 @@ pub use sphinx_packet::{ self, DESTINATION_ADDRESS_LENGTH, IDENTIFIER_LENGTH, MAX_PATH_LENGTH, NODE_ADDRESS_LENGTH, PAYLOAD_KEY_SIZE, }, - crypto::{self, EphemeralSecret, PrivateKey, PublicKey, SharedSecret}, + crypto::{self, PrivateKey, PublicKey}, header::{self, delays, delays::Delay, ProcessedHeader, SphinxHeader, HEADER_SIZE}, packet::builder::DEFAULT_PAYLOAD_SIZE, payload::{Payload, PAYLOAD_OVERHEAD_SIZE}, diff --git a/common/socks5-client-core/Cargo.toml b/common/socks5-client-core/Cargo.toml index e839377bc4..344b60cd64 100644 --- a/common/socks5-client-core/Cargo.toml +++ b/common/socks5-client-core/Cargo.toml @@ -12,7 +12,7 @@ dirs = "4.0" futures = { workspace = true } log = { workspace = true } pin-project = { workspace = true } -rand = { version = "0.7.3", features = ["wasm-bindgen"] } +rand = { workspace = true } reqwest = { workspace = true } schemars = { workspace = true, features = ["preserve_order"] } serde = { workspace = true, features = ["derive"] } # for config serialization/deserialization diff --git a/common/topology/Cargo.toml b/common/topology/Cargo.toml index f8ec395887..471a8621a4 100644 --- a/common/topology/Cargo.toml +++ b/common/topology/Cargo.toml @@ -14,7 +14,7 @@ documentation = { workspace = true } [dependencies] bs58 = { workspace = true } log = { workspace = true } -rand = { version = "0.7.3", features = ["wasm-bindgen"] } +rand = { workspace = true } thiserror = { workspace = true } async-trait = { workspace = true, optional = true } semver = "0.11" diff --git a/common/wasm/client-core/Cargo.toml b/common/wasm/client-core/Cargo.toml index c9a07a4733..015ff09a82 100644 --- a/common/wasm/client-core/Cargo.toml +++ b/common/wasm/client-core/Cargo.toml @@ -11,7 +11,7 @@ repository = "https://github.com/nymtech/nym" [dependencies] async-trait = { workspace = true } js-sys = { workspace = true } -rand = { version = "0.7.3", features = ["wasm-bindgen"] } +rand = { workspace = true } serde = { workspace = true, features = ["derive"] } serde-wasm-bindgen = { workspace = true } thiserror = { workspace = true } diff --git a/common/wireguard-types/Cargo.toml b/common/wireguard-types/Cargo.toml index 84efd4aec9..7a87e53456 100644 --- a/common/wireguard-types/Cargo.toml +++ b/common/wireguard-types/Cargo.toml @@ -34,7 +34,7 @@ serde_json = { workspace = true, optional = true } x25519-dalek = { version = "2.0.0", features = ["static_secrets"] } [dev-dependencies] -rand = "0.7.3" +rand = "0.8.5" nym-crypto = { path = "../crypto", features = ["rand"]} diff --git a/contracts/Cargo.lock b/contracts/Cargo.lock index 026e514e9c..cd7002d7c3 100644 --- a/contracts/Cargo.lock +++ b/contracts/Cargo.lock @@ -4,33 +4,40 @@ version = 3 [[package]] name = "aes" -version = "0.7.5" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e8b47f52ea9bae42228d07ec09eb676433d7c4ed1ebdf0f1d1c29ed446f1ab8" +checksum = "b169f7a6d4742236a0a00c541b845991d0ac43e546831af1249753ab4c3aa3a0" dependencies = [ "cfg-if", "cipher", "cpufeatures", - "ctr", - "opaque-debug 0.3.0", ] [[package]] name = "ahash" -version = "0.7.6" +version = "0.7.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47" +checksum = "891477e0c6a8957309ee5c45a6368af3ae14bb510732d2684ffa19af310920f9" dependencies = [ - "getrandom 0.2.10", + "getrandom", "once_cell", "version_check", ] [[package]] -name = "anyhow" -version = "1.0.70" +name = "aho-corasick" +version = "1.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7de8ce5e0f9f8d88245311066a578d72b7af3e7088f32783804676302df237e4" +checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" +dependencies = [ + "memchr", +] + +[[package]] +name = "anyhow" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f538837af36e6f6a9be0faa67f9a314f8119e4e4b5867c6ab40ed60360142519" [[package]] name = "arrayref" @@ -40,9 +47,9 @@ checksum = "6b4930d2cb77ce62f89ee5d5289b4ac049559b1c45539271f5ed4fdc7db34545" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "f1fdabc7756949593fe60f30ec81974b613357de856987752631dea1e3394c80" [[package]] name = "base16ct" @@ -64,9 +71,9 @@ checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" [[package]] name = "base64" -version = "0.21.0" +version = "0.21.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a4ddaa51a5bc52a6948f74c06d20aaaddb71924eab79b8c97a8c556e942d6a" +checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567" [[package]] name = "base64ct" @@ -87,7 +94,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94cb07b0da6a73955f8fb85d24c466778e70cda767a568229b104f0264089330" dependencies = [ "byte-tools", - "crypto-mac 0.7.0", + "crypto-mac", "digest 0.8.1", "opaque-debug 0.2.3", ] @@ -131,12 +138,6 @@ dependencies = [ "tinyvec", ] -[[package]] -name = "bumpalo" -version = "3.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b1ce199063694f33ffb7dd4e0ee620741495c32833cde5aa08f02a0bf96f0c8" - [[package]] name = "byte-tools" version = "0.3.1" @@ -145,23 +146,24 @@ checksum = "e3b5ca7a04898ad4bcd41c90c5285445ff5b791899bb1b0abdd2a2aa791211d7" [[package]] name = "byteorder" -version = "1.4.3" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "bytes" -version = "1.4.0" +version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89b2fd2a0dcf38d7971e2194b6b6eebab45ae01067456a7fd93d5547a61b70be" +checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" [[package]] name = "cc" -version = "1.0.79" +version = "1.0.94" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50d30906286121d95be3d479533b458f87493b30a4b5f79a607db8f5d11aa91f" +checksum = "17f6e324229dc011159fcc089755d1e2e216a90d43a7dea6853ca740b84f35e7" dependencies = [ "jobserver", + "libc", ] [[package]] @@ -182,11 +184,12 @@ dependencies = [ [[package]] name = "cipher" -version = "0.3.0" +version = "0.4.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ee52072ec15386f770805afd189a01c8841be8696bed250fa2f13c4c0d6dfb7" +checksum = "773f3b9af64447d2ce9850330c473515014aa235e6a783b02db81ff39e4a3dad" dependencies = [ - "generic-array 0.14.7", + "crypto-common", + "inout", ] [[package]] @@ -210,7 +213,7 @@ dependencies = [ "nym-coconut-dkg-common", "nym-group-contract-common", "nym-multisig-contract-common", - "rand_chacha 0.2.2", + "rand_chacha", "schemars", "serde", "subtle-encoding", @@ -219,9 +222,9 @@ dependencies = [ [[package]] name = "const-oid" -version = "0.9.2" +version = "0.9.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "520fbf3c07483f94e3e3ca9d0cfd913d7718ef2483d2cfd91c0d9e91474ab913" +checksum = "c2459377285ad874054d797f3ccebf984978aa39129f6eafde5cdc8315b612f8" [[package]] name = "cosmwasm-crypto" @@ -231,7 +234,7 @@ checksum = "c533b66e502ecab30fec23d03eb54ab1d3ce120645a00493459f8510b7a9736f" dependencies = [ "digest 0.10.7", "ed25519-zebra", - "k256 0.13.2", + "k256 0.13.3", "rand_core 0.6.4", "thiserror", ] @@ -275,7 +278,7 @@ version = "1.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e98e19fae6c3f468412f731274b0f9434602722009d6a77432d39c7c4bb09202" dependencies = [ - "base64 0.21.0", + "base64 0.21.7", "bnum", "cosmwasm-crypto", "cosmwasm-derive", @@ -285,7 +288,7 @@ dependencies = [ "schemars", "serde", "serde-json-wasm", - "sha2 0.10.6", + "sha2 0.10.8", "thiserror", ] @@ -301,9 +304,9 @@ dependencies = [ [[package]] name = "cpufeatures" -version = "0.2.5" +version = "0.2.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28d997bd5e24a5928dd43e46dc529867e207907fe0b239c3477d924f7f2ca320" +checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" dependencies = [ "libc", ] @@ -352,21 +355,11 @@ dependencies = [ "subtle 1.0.0", ] -[[package]] -name = "crypto-mac" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1d1a86f49236c215f271d40892d5fc950490551400b02ef360692c29815c714" -dependencies = [ - "generic-array 0.14.7", - "subtle 2.4.1", -] - [[package]] name = "ctr" -version = "0.8.0" +version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "049bb91fb4aaf0e3c7efa6cd5ef877dbbbd15b39dad06d9948de4ec8a75761ea" +checksum = "0369ee1ad671834580515889b80f2ea915f23b8be8d0daa4bbaf2ac5c7590835" dependencies = [ "cipher", ] @@ -384,6 +377,34 @@ dependencies = [ "zeroize", ] +[[package]] +name = "curve25519-dalek" +version = "4.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0a677b8922c94e01bdbb12126b0bc852f00447528dee1782229af9c720c3f348" +dependencies = [ + "cfg-if", + "cpufeatures", + "curve25519-dalek-derive", + "digest 0.10.7", + "fiat-crypto", + "platforms", + "rustc_version", + "subtle 2.4.1", + "zeroize", +] + +[[package]] +name = "curve25519-dalek-derive" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f46882e17999c6cc590af592290432be3bce0428cb0d5f8b6715e4dc7b383eb3" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.59", +] + [[package]] name = "cw-controllers" version = "1.1.0" @@ -474,14 +495,13 @@ dependencies = [ [[package]] name = "cw20-base" -version = "1.0.1" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "afcd279230b08ed8afd8be5828221622bd5b9ce25d0b01d58bad626c6ce0169c" +checksum = "17ad79e86ea3707229bf78df94e08732e8f713207b4a77b2699755596725e7d9" dependencies = [ "cosmwasm-schema", "cosmwasm-std", "cw-storage-plus", - "cw-utils", "cw2", "cw20", "schemars", @@ -584,9 +604,9 @@ dependencies = [ [[package]] name = "der" -version = "0.7.8" +version = "0.7.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fffa369a668c8af7dbf8b5e56c9f744fbd399949ed171606040001947de40b1c" +checksum = "f55bf8e7b65898637379c1b74eb1551107c8294ed26d855ceb9fd1a09cfc9bc0" dependencies = [ "const-oid", "zeroize", @@ -594,9 +614,9 @@ dependencies = [ [[package]] name = "deranged" -version = "0.3.9" +version = "0.3.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f32d04922c60427da6f9fef14d042d9edddef64cb9d4ce0d64d0685fbeb1fd3" +checksum = "b42b6fa04a440b495c8b04d0e71b707c585f83cb9cb28cf8cd0d976c315e31b4" dependencies = [ "powerfmt", ] @@ -644,9 +664,9 @@ dependencies = [ [[package]] name = "dyn-clone" -version = "1.0.11" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68b0cf012f1230e43cd00ebb729c6bb58707ecfa8ad08b52ef3a4ccd2697fc30" +checksum = "0d6ef0072f8a535281e4876be788938b528e9a1d43900b82c2569af7da799125" [[package]] name = "ecdsa" @@ -666,9 +686,9 @@ version = "0.16.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ee27f32b5c5292967d2d4a9d7f1e0b0aed2c15daded5a60300e4abb9d8020bca" dependencies = [ - "der 0.7.8", + "der 0.7.9", "digest 0.10.7", - "elliptic-curve 0.13.7", + "elliptic-curve 0.13.8", "rfc6979 0.4.0", "signature 2.2.0", "spki 0.7.3", @@ -676,24 +696,26 @@ dependencies = [ [[package]] name = "ed25519" -version = "1.5.3" +version = "2.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" +checksum = "115531babc129696a58c64a4fef0a8bf9e9698629fb97e9e40767d235cfbcd53" dependencies = [ - "signature 1.6.4", + "pkcs8 0.10.2", + "signature 2.2.0", ] [[package]] name = "ed25519-dalek" -version = "1.0.1" +version = "2.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" +checksum = "4a3daa8e81a3963a60642bcc1f90a670680bd4a77535faa384e9d1c79d620871" dependencies = [ - "curve25519-dalek", + "curve25519-dalek 4.1.2", "ed25519", - "rand 0.7.3", + "rand_core 0.6.4", "serde", - "sha2 0.9.9", + "sha2 0.10.8", + "subtle 2.4.1", "zeroize", ] @@ -703,7 +725,7 @@ version = "3.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7c24f403d068ad0b359e577a77f92392118be3f3c927538f2bb544a5ecd828c6" dependencies = [ - "curve25519-dalek", + "curve25519-dalek 3.2.0", "hashbrown", "hex", "rand_core 0.6.4", @@ -714,9 +736,9 @@ dependencies = [ [[package]] name = "either" -version = "1.8.1" +version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7fcaabb2fef8c910e7f4c7ce9f67a1283a1715879a7c230ca9d6d1ae31f16d91" +checksum = "a47c1c47d2f5964e29c61246e81db715514cd532db6b5116a25ea3c03d6780a2" [[package]] name = "elliptic-curve" @@ -740,9 +762,9 @@ dependencies = [ [[package]] name = "elliptic-curve" -version = "0.13.7" +version = "0.13.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e9775b22bc152ad86a0cf23f0f348b884b26add12bf741e7ffc4d4ab2ab4d205" +checksum = "b5e6043086bf7973472e0c7dff2142ea0b680d30e18d9cc40f267efbf222bd47" dependencies = [ "base16ct 0.2.0", "crypto-bigint 0.5.5", @@ -768,13 +790,13 @@ dependencies = [ [[package]] name = "enum-iterator-derive" -version = "1.2.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "355f93763ef7b0ae1c43c4d8eccc9d5848d84ad1a1d8ce61c421d1ac85a19d05" +checksum = "03cdc46ec28bd728e67540c528013c6a10eb69a02eb31078a1bda695438cbfb8" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.59", ] [[package]] @@ -798,10 +820,16 @@ dependencies = [ ] [[package]] -name = "form_urlencoded" -version = "1.1.0" +name = "fiat-crypto" +version = "0.2.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9c384f161156f5260c24a097c56119f9be8c798586aecc13afbcbe7b7e26bf8" +checksum = "c007b1ae3abe1cb6f85a16305acd418b7ca6343b953633fee2b76d8f108b830f" + +[[package]] +name = "form_urlencoded" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" dependencies = [ "percent-encoding", ] @@ -814,9 +842,9 @@ checksum = "c8cbd1169bd7b4a0a20d92b9af7a7e0422888bd38a6f5ec29c1fd8c1558a272e" [[package]] name = "futures" -version = "0.3.28" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23342abe12aba583913b2e62f22225ff9c950774065e4bfb61a19cd9770fec40" +checksum = "645c6916888f6cb6350d2550b80fb63e734897a8498abe35cfb732b6487804b0" dependencies = [ "futures-channel", "futures-core", @@ -829,9 +857,9 @@ dependencies = [ [[package]] name = "futures-channel" -version = "0.3.28" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "955518d47e09b25bbebc7a18df10b81f0c766eaf4c4f1cccef2fca5f2a4fb5f2" +checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" dependencies = [ "futures-core", "futures-sink", @@ -839,15 +867,15 @@ dependencies = [ [[package]] name = "futures-core" -version = "0.3.28" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bca583b7e26f571124fe5b7561d49cb2868d79116cfa0eefce955557c6fee8c" +checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" [[package]] name = "futures-executor" -version = "0.3.28" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccecee823288125bd88b4d7f565c9e58e41858e47ab72e8ea2d64e93624386e0" +checksum = "a576fc72ae164fca6b9db127eaa9a9dda0d61316034f33a0a0d4eda41f02b01d" dependencies = [ "futures-core", "futures-task", @@ -856,44 +884,44 @@ dependencies = [ [[package]] name = "futures-io" -version = "0.3.28" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fff74096e71ed47f8e023204cfd0aa1289cd54ae5430a9523be060cdb849964" +checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" [[package]] name = "futures-macro" -version = "0.3.28" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89ca545a94061b6365f2c7355b4b32bd20df3ff95f02da9329b34ccc3bd6ee72" +checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac" dependencies = [ "proc-macro2", "quote", - "syn 2.0.49", + "syn 2.0.59", ] [[package]] name = "futures-sink" -version = "0.3.28" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f43be4fe21a13b9781a69afa4985b0f6ee0e1afab2c6f454a8cf30e2b2237b6e" +checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" [[package]] name = "futures-task" -version = "0.3.28" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76d3d132be6c0e6aa1534069c705a74a5997a356c0dc2f86a47765e5617c5b65" +checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" [[package]] name = "futures-timer" -version = "3.0.2" +version = "3.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e64b03909df88034c26dc1547e8970b91f98bdb65165d6a4e9110d94263dbb2c" +checksum = "f288b0a4f20f9a56b5d1da57e2227c661b7b16168e2f72365f57b63326e29b24" [[package]] name = "futures-util" -version = "0.3.28" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26b01e40b772d54cf6c6d721c1d1abd0647a0106a12ecaa1c186273392a69533" +checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" dependencies = [ "futures-channel", "futures-core", @@ -929,26 +957,13 @@ dependencies = [ [[package]] name = "getrandom" -version = "0.1.16" +version = "0.2.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "js-sys", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", - "wasm-bindgen", -] - -[[package]] -name = "getrandom" -version = "0.2.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be4136b2a15dd319360be1c07d9933517ccf0be8f16bf62a3bee4f0d618df427" +checksum = "94b22e06ecb0110981051723910cbf0b5f5e09a2062dd7663334ee79a9d1286c" dependencies = [ "cfg-if", "libc", - "wasi 0.11.0+wasi-snapshot-preview1", + "wasi", ] [[package]] @@ -1015,22 +1030,11 @@ checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" [[package]] name = "hkdf" -version = "0.11.0" +version = "0.12.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01706d578d5c281058480e673ae4086a9f4710d8df1ad80a5b03e39ece5f886b" +checksum = "7b5f8eb2ad728638ea2c7d47a21db23b7b58a72ed6a38256b8a1849f15fbbdf7" dependencies = [ - "digest 0.9.0", - "hmac 0.11.0", -] - -[[package]] -name = "hmac" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a2a2320eb7ec0ebe8da8f744d7812d9fc4cb4d09344ac01898dbcb6a20ae69b" -dependencies = [ - "crypto-mac 0.11.1", - "digest 0.9.0", + "hmac", ] [[package]] @@ -1060,14 +1064,23 @@ dependencies = [ [[package]] name = "idna" -version = "0.3.0" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e14ddfc70884202db2244c223200c204c2bda1bc6e0998d11b5e024d657209e6" +checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" dependencies = [ "unicode-bidi", "unicode-normalization", ] +[[package]] +name = "inout" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a0c10553d664a4d0bcff9f4215d0aac67a639cc68ef660840afe309b807bc9f5" +dependencies = [ + "generic-array 0.14.7", +] + [[package]] name = "itertools" version = "0.10.5" @@ -1079,28 +1092,19 @@ dependencies = [ [[package]] name = "itoa" -version = "1.0.6" +version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "453ad9f582a441959e5f0d088b02ce04cfe8d51a8eaf077f12ac6d3e94164ca6" +checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" [[package]] name = "jobserver" -version = "0.1.26" +version = "0.1.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "936cfd212a0155903bcbc060e316fb6cc7cbf2e1907329391ebadc1fe0ce77c2" +checksum = "685a7d121ee3f65ae4fddd72b25a04bb36b6af81bc0828f7d5434c0fe60fa3a2" dependencies = [ "libc", ] -[[package]] -name = "js-sys" -version = "0.3.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "445dde2150c55e483f3d8416706b97ec8e8237c307e5b7b4b8dd15e6af2a0730" -dependencies = [ - "wasm-bindgen", -] - [[package]] name = "k256" version = "0.11.6" @@ -1110,20 +1114,20 @@ dependencies = [ "cfg-if", "ecdsa 0.14.8", "elliptic-curve 0.12.3", - "sha2 0.10.6", + "sha2 0.10.8", ] [[package]] name = "k256" -version = "0.13.2" +version = "0.13.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f01b677d82ef7a676aa37e099defd83a28e15687112cafdd112d60236b6115b" +checksum = "956ff9b67e26e1a6a866cb758f12c6f8746208489e3e4a4b5580802f2f0a587b" dependencies = [ "cfg-if", "ecdsa 0.16.9", - "elliptic-curve 0.13.7", + "elliptic-curve 0.13.8", "once_cell", - "sha2 0.10.6", + "sha2 0.10.8", "signature 2.2.0", ] @@ -1135,9 +1139,9 @@ checksum = "c33070833c9ee02266356de0c43f723152bd38bd96ddf52c82b3af10c9138b28" [[package]] name = "libc" -version = "0.2.146" +version = "0.2.153" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f92be4933c13fd498862a9e02a3055f8a8d9c039ce33db97306fd5a6caa7f29b" +checksum = "9c198f91728a82281a64e1f4f9eeb25d82cb32a5de251c6bd1b5154d63a8e7bd" [[package]] name = "libgit2-sys" @@ -1153,15 +1157,15 @@ dependencies = [ [[package]] name = "libm" -version = "0.2.7" +version = "0.2.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7012b1bbb0719e1097c47611d3898568c546d597c2e74d66f6087edd5233ff4" +checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" [[package]] name = "libz-sys" -version = "1.1.8" +version = "1.1.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9702761c3935f8cc2f101793272e202c72b99da8f4224a19ddcf1279a6450bbf" +checksum = "5e143b5e666b2695d28f6bca6497720813f699c9602dd7f5cac91008b8ada7f9" dependencies = [ "cc", "libc", @@ -1183,18 +1187,15 @@ dependencies = [ [[package]] name = "log" -version = "0.4.17" +version = "0.4.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" -dependencies = [ - "cfg-if", -] +checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" [[package]] name = "memchr" -version = "2.5.0" +version = "2.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" +checksum = "6c8640c5d730cb13ebd907d8d04b52f55ac9a2eec55b440c8892f40d56c76c1d" [[package]] name = "mixnet-vesting-integration-tests" @@ -1209,14 +1210,20 @@ dependencies = [ "nym-mixnet-contract-common", "nym-vesting-contract", "nym-vesting-contract-common", - "rand_chacha 0.2.2", + "rand_chacha", ] [[package]] -name = "num-traits" -version = "0.2.16" +name = "num-conv" +version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f30b0abd723be7e2ffca1272140fac1a2f084c77ec3e123c192b66af1ee9e6c2" +checksum = "51d515d32fb182ee37cda2ccdcb92950d6a3c2893aa280e540671c2cd0f3b1d9" + +[[package]] +name = "num-traits" +version = "0.2.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da0df0e5185db44f69b44f26786fe401b6c293d1907744beaa7fa62b2e5a517a" dependencies = [ "autocfg", "libm", @@ -1300,7 +1307,7 @@ dependencies = [ "ed25519-dalek", "nym-pemstore", "nym-sphinx-types", - "rand 0.7.3", + "rand", "subtle-encoding", "thiserror", "x25519-dalek", @@ -1333,7 +1340,7 @@ dependencies = [ "nym-crypto", "nym-mixnet-contract-common", "nym-vesting-contract-common", - "rand_chacha 0.2.2", + "rand_chacha", "semver", "serde", "thiserror", @@ -1392,8 +1399,8 @@ dependencies = [ "nym-crypto", "nym-name-service-common", "nym-sphinx-addressing", - "rand 0.8.5", - "rand_chacha 0.2.2", + "rand", + "rand_chacha", "rstest", "semver", "serde", @@ -1438,7 +1445,7 @@ dependencies = [ "nym-contracts-common", "nym-crypto", "nym-service-provider-directory-common", - "rand_chacha 0.2.2", + "rand_chacha", "rstest", "semver", "serde", @@ -1481,7 +1488,7 @@ dependencies = [ name = "nym-vesting-contract" version = "1.4.1" dependencies = [ - "base64 0.21.0", + "base64 0.21.7", "cosmwasm-crypto", "cosmwasm-derive", "cosmwasm-schema", @@ -1492,7 +1499,7 @@ dependencies = [ "nym-contracts-common", "nym-mixnet-contract-common", "nym-vesting-contract-common", - "rand_chacha 0.3.1", + "rand_chacha", "semver", "serde", "serde_json", @@ -1527,9 +1534,9 @@ checksum = "2839e79665f131bdb5782e51f2c6c9599c133c6098982a54c794358bf432529c" [[package]] name = "opaque-debug" -version = "0.3.0" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" +checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" [[package]] name = "pem" @@ -1544,15 +1551,15 @@ dependencies = [ [[package]] name = "percent-encoding" -version = "2.2.0" +version = "2.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e" +checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" [[package]] name = "pin-project-lite" -version = "0.2.9" +version = "0.2.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0a7ae3ac2f1173085d398531c705756c94a4c56843785df85a60c1a0afac116" +checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" [[package]] name = "pin-utils" @@ -1576,15 +1583,21 @@ version = "0.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f950b2377845cebe5cf8b5165cb3cc1a5e0fa5cfa3e1f7f55707d8fd82e0a7b7" dependencies = [ - "der 0.7.8", + "der 0.7.9", "spki 0.7.3", ] [[package]] name = "pkg-config" -version = "0.3.26" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ac9a59f73473f1b8d852421e59e64809f025994837ef743615c6d0c5b305160" +checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" + +[[package]] +name = "platforms" +version = "3.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db23d408679286588f4d4644f965003d056e3dd5abcaaa938116871d7ce2fee7" [[package]] name = "powerfmt" @@ -1624,9 +1637,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.81" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "3d1597b0c024618f09a9c3b8655b7e430397a36d23fdafec26d6965e9eec3eba" dependencies = [ "unicode-ident", ] @@ -1656,26 +1669,13 @@ dependencies = [ [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", -] - [[package]] name = "rand" version = "0.8.5" @@ -1683,20 +1683,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" dependencies = [ "libc", - "rand_chacha 0.3.1", + "rand_chacha", "rand_core 0.6.4", ] -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - [[package]] name = "rand_chacha" version = "0.3.1" @@ -1712,9 +1702,6 @@ name = "rand_core" version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] [[package]] name = "rand_core" @@ -1722,42 +1709,47 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" dependencies = [ - "getrandom 0.2.10", + "getrandom", ] [[package]] name = "rand_distr" -version = "0.3.0" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9e9532ada3929fb8b2e9dbe28d1e06c9b2cc65813f074fcb6bd5fbefeff9d56" +checksum = "32cb0b9bc82b0a0876c2dd994a7e7a2683d3e7390ca40e6886785ef0c7e3ee31" dependencies = [ "num-traits", - "rand 0.7.3", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", + "rand", ] [[package]] name = "regex" -version = "1.8.1" +version = "1.10.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af83e617f331cc6ae2da5443c602dfa5af81e517212d9d611a5b3ba1777b5370" +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.7.1" +version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a5996294f19bd3aae0453a862ad728f60e6600695733dd5df01da90c54363a3c" +checksum = "adad44e29e4c806119491a7f06f03de4d1af22c3a680dd47f1e6e179439d1f56" [[package]] name = "rfc6979" @@ -1766,7 +1758,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7743f17af12fa0b03b803ba12cd6a8d9483a587e89c69445e3909655c0b9fabb" dependencies = [ "crypto-bigint 0.4.9", - "hmac 0.12.1", + "hmac", "zeroize", ] @@ -1776,7 +1768,7 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f8dd2a808d456c4a54e300a23e9f5a67e122c3024119acbfd73e3bf664491cb2" dependencies = [ - "hmac 0.12.1", + "hmac", "subtle 2.4.1", ] @@ -1817,15 +1809,15 @@ dependencies = [ [[package]] name = "rustversion" -version = "1.0.12" +version = "1.0.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f3208ce4d8448b3f3e7d168a73f5e0c43a61e32930de3bceeccedb388b6bf06" +checksum = "80af6f9131f277a45a3fba6ce8e2258037bb0477a67e610d3c1fe046ab31de47" [[package]] name = "ryu" -version = "1.0.13" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f91339c0467de62360649f8d3e185ca8de4224ff281f66000de5eb2a77a79041" +checksum = "e86697c916019a8588c99b5fac3cead74ec0b4b819707a682fd4d23fa0ce1ba1" [[package]] name = "schemars" @@ -1872,7 +1864,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d3e97a565f76233a6003f9f5c54be1d9c5bdfa3eccfb189469f11ec4901c47dc" dependencies = [ "base16ct 0.2.0", - "der 0.7.8", + "der 0.7.9", "generic-array 0.14.7", "pkcs8 0.10.2", "subtle 2.4.1", @@ -1881,15 +1873,15 @@ dependencies = [ [[package]] name = "semver" -version = "1.0.21" +version = "1.0.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b97ed7a9823b74f99c7742f5336af7be5ecd3eeafcb1507d1fa93347b1d589b0" +checksum = "92d43fe69e652f3df9bdc2b85b2854a0825b86e4fb76bc44d945137d053639ca" [[package]] name = "serde" -version = "1.0.196" +version = "1.0.198" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "870026e60fa08c69f064aa766c10f10b1d62db9ccd4d0abb206472bee0ce3b32" +checksum = "9846a40c979031340571da2545a4e5b7c4163bdae79b301d5f86d03979451fcc" dependencies = [ "serde_derive", ] @@ -1905,13 +1897,13 @@ dependencies = [ [[package]] name = "serde_derive" -version = "1.0.196" +version = "1.0.198" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33c85360c95e7d137454dc81d9a4ed2b8efd8fbe19cee57357b32b9771fccb67" +checksum = "e88edab869b01783ba905e7d0153f9fc1a6505a96e4ad3018011eedb838566d9" dependencies = [ "proc-macro2", "quote", - "syn 2.0.49", + "syn 2.0.59", ] [[package]] @@ -1927,9 +1919,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.96" +version = "1.0.116" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "057d394a50403bcac12672b2b18fb387ab6d289d957dab67dd201875391e52f1" +checksum = "3e17db7126d17feb94eb3fad46bf1a96b034e8aacbc2e775fe81505f8b0b2813" dependencies = [ "itoa", "ryu", @@ -1938,13 +1930,13 @@ dependencies = [ [[package]] name = "serde_repr" -version = "0.1.12" +version = "0.1.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bcec881020c684085e55a25f7fd888954d56609ef363479dc5a1305eb0d40cab" +checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" dependencies = [ "proc-macro2", "quote", - "syn 2.0.49", + "syn 2.0.59", ] [[package]] @@ -1957,14 +1949,14 @@ dependencies = [ "cfg-if", "cpufeatures", "digest 0.9.0", - "opaque-debug 0.3.0", + "opaque-debug 0.3.1", ] [[package]] name = "sha2" -version = "0.10.6" +version = "0.10.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82e6b795fe2e3b1e845bafcb27aa35405c4d47cdfc92af5fc8d3002f76cebdc0" +checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" dependencies = [ "cfg-if", "cpufeatures", @@ -1993,34 +1985,35 @@ dependencies = [ [[package]] name = "slab" -version = "0.4.8" +version = "0.4.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6528351c9bc8ab22353f9d776db39a20288e8d6c37ef8cfe3317cf875eecfc2d" +checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" dependencies = [ "autocfg", ] [[package]] name = "sphinx-packet" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc43eda802856ee82a7555c7b75ceb9e07451741c7a2f5f23d036020e01189d4" +checksum = "dabeca95bf5fd0563d6be7ebcb1c6a9fcb135746a0ba9050c47dc68c8607e595" dependencies = [ "aes", "arrayref", "blake2", - "bs58 0.4.0", + "bs58 0.5.1", "byteorder", "chacha", - "curve25519-dalek", - "digest 0.9.0", + "ctr", + "curve25519-dalek 4.1.2", + "digest 0.10.7", "hkdf", - "hmac 0.11.0", + "hmac", "lioness", "log", - "rand 0.7.3", + "rand", "rand_distr", - "sha2 0.9.9", + "sha2 0.10.8", "subtle 2.4.1", ] @@ -2041,7 +2034,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d91ed6c858b01f942cd56b37a94b3e0a1798290327d1236e4d9cf4eaca44d29d" dependencies = [ "base64ct", - "der 0.7.8", + "der 0.7.9", ] [[package]] @@ -2078,9 +2071,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.49" +version = "2.0.59" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "915aea9e586f80826ee59f8453c1101f9d1c4b3964cd2460185ee8e299ada496" +checksum = "4a6531ffc7b071655e4ce2e04bd464c4830bb585a61cabb96cf808f05172615a" dependencies = [ "proc-macro2", "quote", @@ -2104,17 +2097,18 @@ checksum = "c61f3ba182994efc43764a46c018c347bc492c79f024e705f46567b418f6d4f7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.49", + "syn 2.0.59", ] [[package]] name = "time" -version = "0.3.30" +version = "0.3.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4a34ab300f2dee6e562c10a046fc05e358b29f9bf92277f30c3c8d82275f6f5" +checksum = "5dfd88e563464686c916c7e46e623e520ddc6d79fa6641390f2e3fa86e83e885" dependencies = [ "deranged", "itoa", + "num-conv", "powerfmt", "serde", "time-core", @@ -2129,10 +2123,11 @@ checksum = "ef927ca75afb808a4d64dd374f00a2adf8d0fcff8e7b184af886c3c87ec4a3f3" [[package]] name = "time-macros" -version = "0.2.15" +version = "0.2.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ad70d68dba9e1f8aceda7aa6711965dfec1cac869f311a51bd08b3a2ccbce20" +checksum = "3f252a68540fde3a3877aeea552b832b40ab9a69e318efd078774a01ddee1ccf" dependencies = [ + "num-conv", "time-core", ] @@ -2153,36 +2148,36 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "typenum" -version = "1.16.0" +version = "1.17.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "497961ef93d974e23eb6f433eb5fe1b7930b659f06d12dec6fc44a8f554c0bba" +checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" [[package]] name = "unicode-bidi" -version = "0.3.12" +version = "0.3.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d502c968c6a838ead8e69b2ee18ec708802f99db92a0d156705ec9ef801993b" +checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" [[package]] name = "unicode-ident" -version = "1.0.8" +version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5464a87b239f13a63a501f2701565754bae92d243d4bb7eb12f6d57d2269bf4" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" [[package]] name = "unicode-normalization" -version = "0.1.22" +version = "0.1.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" +checksum = "a56d1686db2308d901306f92a263857ef59ea39678a5458e7cb17f01415101f5" dependencies = [ "tinyvec", ] [[package]] name = "url" -version = "2.3.1" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d68c799ae75762b8c3fe375feb6600ef5602c883c5d21eb51c09f22b83c4643" +checksum = "31e6302e3bb753d46e83516cae55ae196fc0c309407cf11ab35cc51a4c2a4633" dependencies = [ "form_urlencoded", "idna", @@ -2218,88 +2213,29 @@ version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - [[package]] name = "wasi" version = "0.11.0+wasi-snapshot-preview1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" -[[package]] -name = "wasm-bindgen" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31f8dcbc21f30d9b8f2ea926ecb58f6b91192c17e9d33594b3df58b2007ca53b" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95ce90fd5bcc06af55a641a86428ee4229e44e07033963a2290a8e241607ccb9" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn 1.0.109", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c21f77c0bedc37fd5dc21f897894a5ca01e7bb159884559461862ae90c0b4c5" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2aff81306fcac3c7515ad4e177f521b5c9a15f2b08f4e32d823066102f35a5f6" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0046fef7e28c3804e5e38bfa31ea2a0f73905319b677e57ebe37e49358989b5d" - [[package]] name = "x25519-dalek" -version = "1.1.1" +version = "2.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a0c105152107e3b96f6a00a65e86ce82d9b125230e1c4302940eca58ff71f4f" +checksum = "c7e468321c81fb07fa7f4c636c3972b9100f0346e5b6a9f2bd0603a52f7ed277" dependencies = [ - "curve25519-dalek", - "rand_core 0.5.1", + "curve25519-dalek 4.1.2", + "rand_core 0.6.4", + "serde", "zeroize", ] [[package]] name = "zeroize" -version = "1.6.0" +version = "1.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a0956f1ba7c7909bfb66c2e9e4124ab6f6482560f6628b5aaeba39207c9aad9" +checksum = "525b4ec142c6b68a2d10f01f7bbf6755599ca3f81ea53b8431b7dd348f5fdb2d" dependencies = [ "zeroize_derive", ] @@ -2312,5 +2248,5 @@ checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ "proc-macro2", "quote", - "syn 2.0.49", + "syn 2.0.59", ] diff --git a/contracts/coconut-test/Cargo.toml b/contracts/coconut-test/Cargo.toml index 22475dda1f..8b174175df 100644 --- a/contracts/coconut-test/Cargo.toml +++ b/contracts/coconut-test/Cargo.toml @@ -32,7 +32,7 @@ cw-multi-test = { workspace = true } cw3-flex-multisig = { path = "../multisig/cw3-flex-multisig" } cw4-group = { path = "../multisig/cw4-group" } -rand_chacha = "0.2" +rand_chacha = "0.3" [[test]] name = "coconut-test" diff --git a/contracts/mixnet-vesting-integration-tests/Cargo.toml b/contracts/mixnet-vesting-integration-tests/Cargo.toml index 24d2ddd1ab..a60f433758 100644 --- a/contracts/mixnet-vesting-integration-tests/Cargo.toml +++ b/contracts/mixnet-vesting-integration-tests/Cargo.toml @@ -25,7 +25,7 @@ nym-vesting-contract = { path = "../vesting" } nym-crypto = { path = "../../common/crypto", features = ["asymmetric", "rand"] } # external dependencies -rand_chacha = "0.2" +rand_chacha = "0.3" [[test]] name = "mixnet-vesting-test" diff --git a/contracts/mixnet/Cargo.toml b/contracts/mixnet/Cargo.toml index 9f2ba07124..2b854def9f 100644 --- a/contracts/mixnet/Cargo.toml +++ b/contracts/mixnet/Cargo.toml @@ -44,7 +44,7 @@ time = { version = "0.3", features = ["macros"] } semver = { workspace = true, default-features = false } [dev-dependencies] -rand_chacha = "0.2" +rand_chacha = "0.3" nym-crypto = { path = "../../common/crypto", features = ["asymmetric", "rand"] } [build-dependencies] diff --git a/contracts/name-service/Cargo.toml b/contracts/name-service/Cargo.toml index c1bf210637..e3ec82c685 100644 --- a/contracts/name-service/Cargo.toml +++ b/contracts/name-service/Cargo.toml @@ -33,7 +33,7 @@ cw-multi-test = { workspace = true } nym-crypto = { path = "../../common/crypto", features = ["asymmetric", "rand"] } nym-sphinx-addressing = { path = "../../common/nymsphinx/addressing" } rand = "0.8.5" -rand_chacha = "0.2" +rand_chacha = "0.3" rstest = "0.17.0" [features] diff --git a/contracts/service-provider-directory/Cargo.toml b/contracts/service-provider-directory/Cargo.toml index e4a75c50f0..570b50e8aa 100644 --- a/contracts/service-provider-directory/Cargo.toml +++ b/contracts/service-provider-directory/Cargo.toml @@ -31,7 +31,7 @@ vergen = { version = "=7.4.3", default-features = false, features = ["build", "g anyhow = "1.0.40" cw-multi-test = { workspace = true } nym-crypto = { path = "../../common/crypto", features = ["asymmetric", "rand"] } -rand_chacha = "0.2" +rand_chacha = "0.3" rstest = "0.17.0" [features] diff --git a/gateway/Cargo.toml b/gateway/Cargo.toml index 1231076634..69efe08df8 100644 --- a/gateway/Cargo.toml +++ b/gateway/Cargo.toml @@ -30,7 +30,7 @@ humantime-serde = { workspace = true } ipnetwork = "0.16" log = { workspace = true } once_cell = { workspace = true } -rand = "0.7" +rand = { workspace = true } serde = { workspace = true, features = ["derive"] } serde_json = { workspace = true } sqlx = { workspace = true, features = [ diff --git a/gateway/gateway-requests/Cargo.toml b/gateway/gateway-requests/Cargo.toml index 770ce79cd4..9802a6c590 100644 --- a/gateway/gateway-requests/Cargo.toml +++ b/gateway/gateway-requests/Cargo.toml @@ -15,7 +15,7 @@ bs58 = { workspace = true } futures = { workspace = true } generic-array = { workspace = true, features = ["serde"] } log = { workspace = true } -rand = { version = "0.7.3", features = ["wasm-bindgen"] } +rand = { workspace = true } serde = { workspace = true, features = ["derive"] } serde_json = { workspace = true } thiserror = { workspace = true } diff --git a/gateway/gateway-requests/src/registration/handshake/shared_key.rs b/gateway/gateway-requests/src/registration/handshake/shared_key.rs index 4d4dce6e7f..64975fe4cd 100644 --- a/gateway/gateway-requests/src/registration/handshake/shared_key.rs +++ b/gateway/gateway-requests/src/registration/handshake/shared_key.rs @@ -82,8 +82,10 @@ impl SharedKeys { ) } }; - let mac = - compute_keyed_hmac::(self.mac_key(), &encrypted_data); + let mac = compute_keyed_hmac::( + self.mac_key().as_slice(), + &encrypted_data, + ); mac.into_bytes().into_iter().chain(encrypted_data).collect() } @@ -102,7 +104,7 @@ impl SharedKeys { let message_bytes = &enc_data[mac_size..]; if !recompute_keyed_hmac_and_verify_tag::( - self.mac_key(), + self.mac_key().as_slice(), message_bytes, mac_tag, ) { diff --git a/gateway/gateway-requests/src/types.rs b/gateway/gateway-requests/src/types.rs index 1da37fd0ab..6c564d4ae8 100644 --- a/gateway/gateway-requests/src/types.rs +++ b/gateway/gateway-requests/src/types.rs @@ -421,7 +421,7 @@ impl BinaryResponse { let message_bytes = &raw_req[mac_size..]; if !recompute_keyed_hmac_and_verify_tag::( - shared_keys.mac_key(), + shared_keys.mac_key().as_slice(), message_bytes, mac_tag, ) { diff --git a/mixnode/Cargo.toml b/mixnode/Cargo.toml index 387b379a23..a6f8012702 100644 --- a/mixnode/Cargo.toml +++ b/mixnode/Cargo.toml @@ -28,7 +28,7 @@ futures = { workspace = true } humantime-serde = { workspace = true } lazy_static = { workspace = true } log = { workspace = true } -rand = "0.7.3" +rand = { workspace = true } serde = { workspace = true, features = ["derive"] } serde_json = { workspace = true } sysinfo = "0.27.7" diff --git a/nym-api/Cargo.toml b/nym-api/Cargo.toml index 0146af7d70..049d518102 100644 --- a/nym-api/Cargo.toml +++ b/nym-api/Cargo.toml @@ -29,8 +29,7 @@ humantime-serde = { workspace = true } k256 = { workspace = true, features = ["ecdsa-core"] } # needed for the Verifier trait; pull whatever version is used by other dependencies log = { workspace = true } pin-project = { workspace = true } -rand = "0.8.5" -rand-07 = { package = "rand", version = "0.7.3" } # required for compatibility +rand = { workspace = true } reqwest = { workspace = true, features = ["json"] } rocket = { workspace = true, features = ["json"] } rocket_cors = { workspace = true } @@ -120,6 +119,5 @@ tempfile = { workspace = true } cw3 = { workspace = true } cw-utils = { workspace = true } rand_chacha = "0.3" -rand_chacha_02 = { package = "rand_chacha", version = "0.2" } sha2 = "0.9" diff --git a/nym-api/src/coconut/tests/fixtures.rs b/nym-api/src/coconut/tests/fixtures.rs index 36e416df19..38e964f395 100644 --- a/nym-api/src/coconut/tests/fixtures.rs +++ b/nym-api/src/coconut/tests/fixtures.rs @@ -27,11 +27,6 @@ pub fn test_rng(seed: [u8; 32]) -> ChaCha20Rng { ChaCha20Rng::from_seed(seed) } -pub fn test_rng_07(seed: [u8; 32]) -> rand_chacha_02::ChaCha20Rng { - use rand_chacha_02::rand_core::SeedableRng; - rand_chacha_02::ChaCha20Rng::from_seed(seed) -} - pub fn pseudorandom_account(rng: &mut ChaCha20Rng) -> AccountId { let mut dummy_account_key_hash = [0u8; 32]; rng.fill_bytes(&mut dummy_account_key_hash); @@ -42,13 +37,8 @@ pub fn dealer_fixture(mut rng: &mut ChaCha20Rng, id: NodeIndex) -> DealerDetails // we might possibly need that private key later on let keypair = DkgKeyPair::new(dkg::params(), &mut rng); - // lol, instantiate rng with an rng due to incompatibility, but even though it looks dodgy AF, - // it's 100% deterministic - let mut secondary_seed = [0u8; 32]; - rng.fill_bytes(&mut secondary_seed); - let addr = pseudorandom_account(rng); - let identity_keypair = identity::KeyPair::new(&mut test_rng_07(secondary_seed)); + let identity_keypair = identity::KeyPair::new(&mut rng); let bte_public_key_with_proof = bs58::encode(&keypair.public_key().to_bytes()).into_string(); let port = 8080 + id; @@ -156,7 +146,7 @@ impl TestingDkgControllerBuilder { let mut secondary_seed = [0u8; 32]; rng.fill_bytes(&mut secondary_seed); - let identity_keypair = identity::KeyPair::new(&mut test_rng_07(secondary_seed)); + let identity_keypair = identity::KeyPair::new(&mut test_rng(secondary_seed)); DealerDetails { address: Addr::unchecked(address.as_ref()), diff --git a/nym-api/src/coconut/tests/mod.rs b/nym-api/src/coconut/tests/mod.rs index 02c430d4c2..bd29db0412 100644 --- a/nym-api/src/coconut/tests/mod.rs +++ b/nym-api/src/coconut/tests/mod.rs @@ -49,8 +49,8 @@ use nym_validator_client::nyxd::Coin; use nym_validator_client::nyxd::{ AccountId, Algorithm, Event, EventAttribute, ExecTxResult, Fee, Hash, TxResponse, }; -use rand_07::rngs::OsRng; -use rand_07::RngCore; +use rand::rngs::OsRng; +use rand::RngCore; use rocket::http::Status; use rocket::local::asynchronous::Client; use std::collections::{BTreeMap, HashMap}; @@ -1336,7 +1336,7 @@ struct TestFixture { impl TestFixture { async fn new() -> Self { - let mut rng = crate::coconut::tests::fixtures::test_rng_07([69u8; 32]); + let mut rng = crate::coconut::tests::fixtures::test_rng([69u8; 32]); let params = Parameters::new(4).unwrap(); let coconut_keypair = nym_coconut::ttp_keygen(¶ms, 1, 1).unwrap().remove(0); let identity = identity::KeyPair::new(&mut rng); diff --git a/nym-api/src/network_monitor/chunker.rs b/nym-api/src/network_monitor/chunker.rs index ec91577866..a45a551502 100644 --- a/nym-api/src/network_monitor/chunker.rs +++ b/nym-api/src/network_monitor/chunker.rs @@ -8,7 +8,7 @@ use nym_sphinx::{ acknowledgements::AckKey, addressing::clients::Recipient, preparer::MessagePreparer, }; use nym_topology::NymTopology; -use rand_07::rngs::OsRng; +use rand::rngs::OsRng; use std::time::Duration; const DEFAULT_AVERAGE_PACKET_DELAY: Duration = Duration::from_millis(200); diff --git a/nym-api/src/network_monitor/mod.rs b/nym-api/src/network_monitor/mod.rs index 29298be436..cc308a627f 100644 --- a/nym-api/src/network_monitor/mod.rs +++ b/nym-api/src/network_monitor/mod.rs @@ -73,7 +73,7 @@ impl<'a> NetworkMonitorBuilder<'a> { // TODO: those keys change constant throughout the whole execution of the monitor. // and on top of that, they are used with ALL the gateways -> presumably this should change // in the future - let mut rng = rand_07::rngs::OsRng; + let mut rng = rand::rngs::OsRng; let identity_keypair = Arc::new(identity::KeyPair::new(&mut rng)); let encryption_keypair = Arc::new(encryption::KeyPair::new(&mut rng)); diff --git a/nym-api/src/network_monitor/monitor/preparer.rs b/nym-api/src/network_monitor/monitor/preparer.rs index 4e9cfda0fd..73a11b4d60 100644 --- a/nym-api/src/network_monitor/monitor/preparer.rs +++ b/nym-api/src/network_monitor/monitor/preparer.rs @@ -14,7 +14,7 @@ use nym_sphinx::addressing::clients::Recipient; use nym_sphinx::forwarding::packet::MixPacket; use nym_sphinx::params::{PacketSize, PacketType}; use nym_topology::{gateway, mix}; -use rand_07::{rngs::ThreadRng, seq::SliceRandom, thread_rng, Rng}; +use rand::{rngs::ThreadRng, seq::SliceRandom, thread_rng, Rng}; use std::collections::{HashMap, HashSet}; use std::fmt::{self, Display, Formatter}; diff --git a/nym-api/src/support/config/helpers.rs b/nym-api/src/support/config/helpers.rs index a124a8e4dd..9f965e7815 100644 --- a/nym-api/src/support/config/helpers.rs +++ b/nym-api/src/support/config/helpers.rs @@ -9,7 +9,6 @@ use crate::support::config::{ use anyhow::{Context, Result}; use nym_crypto::asymmetric::identity; use rand::rngs::OsRng; -use rand_07::rngs::OsRng as OsRng07; use std::{fs, io}; // TODO: once we upgrade ed25519 library, we could use the same rand library and use proper @@ -20,7 +19,7 @@ fn init_identity_keys(config: &config::NymApiPaths) -> Result<()> { &config.public_identity_key_file, ); - let mut rng = OsRng07; + let mut rng = OsRng; let keypair = identity::KeyPair::new(&mut rng); nym_pemstore::store_keypair(&keypair, &keypaths) .context("failed to store identity keys of the nym api")?; diff --git a/nym-connect/desktop/Cargo.lock b/nym-connect/desktop/Cargo.lock index 5bd30154dd..808e429faa 100644 --- a/nym-connect/desktop/Cargo.lock +++ b/nym-connect/desktop/Cargo.lock @@ -35,25 +35,12 @@ dependencies = [ [[package]] name = "aes" -version = "0.7.5" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e8b47f52ea9bae42228d07ec09eb676433d7c4ed1ebdf0f1d1c29ed446f1ab8" +checksum = "b169f7a6d4742236a0a00c541b845991d0ac43e546831af1249753ab4c3aa3a0" dependencies = [ "cfg-if", - "cipher 0.3.0", - "cpufeatures", - "ctr 0.8.0", - "opaque-debug 0.3.0", -] - -[[package]] -name = "aes" -version = "0.8.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac1f845298e95f983ff1944b728ae08b8cebab80d684f0a832ed0fc74dfa27e2" -dependencies = [ - "cfg-if", - "cipher 0.4.4", + "cipher", "cpufeatures", ] @@ -437,8 +424,8 @@ version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7e141fb0f8be1c7b45887af94c88b182472b57c96b56773250ae00cd6a14a164" dependencies = [ - "bs58 0.5.0", - "hmac 0.12.1", + "bs58 0.5.1", + "hmac", "k256", "once_cell", "pbkdf2", @@ -500,7 +487,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94cb07b0da6a73955f8fb85d24c466778e70cda767a568229b104f0264089330" dependencies = [ "byte-tools", - "crypto-mac 0.7.0", + "crypto-mac", "digest 0.8.1", "opaque-debug 0.2.3", ] @@ -616,9 +603,9 @@ checksum = "771fe0050b883fcc3ea2359b1a96bcfbc090b7116eae7c3c512c7a083fdf23d3" [[package]] name = "bs58" -version = "0.5.0" +version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f5353f36341f7451062466f0b755b96ac3a9547e4d7f6b70d603fc721a7d7896" +checksum = "bf88ba1141d185c399bee5288d850d63b8369520c1eafc32a0430b5b6c287bf4" dependencies = [ "sha2 0.10.8", "tinyvec", @@ -654,9 +641,9 @@ checksum = "17febce684fd15d89027105661fec94afb475cb995fbc59d2865198446ba2eea" [[package]] name = "byteorder" -version = "1.4.3" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "bytes" @@ -775,7 +762,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c3613f74bd2eac03dad61bd53dbe620703d4371614fe0bc3b9f04dd36fe4e818" dependencies = [ "cfg-if", - "cipher 0.4.4", + "cipher", "cpufeatures", ] @@ -787,7 +774,7 @@ checksum = "10cd79432192d1c0f4e1a0fef9527696cc039165d729fb41b3f4f4f354c2dc35" dependencies = [ "aead", "chacha20", - "cipher 0.4.4", + "cipher", "poly1305", "zeroize", ] @@ -805,15 +792,6 @@ dependencies = [ "winapi", ] -[[package]] -name = "cipher" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ee52072ec15386f770805afd189a01c8841be8696bed250fa2f13c4c0d6dfb7" -dependencies = [ - "generic-array 0.14.7", -] - [[package]] name = "cipher" version = "0.4.4" @@ -1055,7 +1033,7 @@ dependencies = [ "rand_core 0.6.4", "serde", "serde_json", - "signature 2.1.0", + "signature", "subtle-encoding", "tendermint", "tendermint-rpc", @@ -1248,16 +1226,6 @@ dependencies = [ "subtle 1.0.0", ] -[[package]] -name = "crypto-mac" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25fab6889090c8133f3deb8f73ba3c65a7f456f66436fc012a1b1e272b1e103e" -dependencies = [ - "generic-array 0.14.7", - "subtle 2.5.0", -] - [[package]] name = "cssparser" version = "0.27.2" @@ -1295,22 +1263,13 @@ dependencies = [ "syn 1.0.109", ] -[[package]] -name = "ctr" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "049bb91fb4aaf0e3c7efa6cd5ef877dbbbd15b39dad06d9948de4ec8a75761ea" -dependencies = [ - "cipher 0.3.0", -] - [[package]] name = "ctr" version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0369ee1ad671834580515889b80f2ea915f23b8be8d0daa4bbaf2ac5c7590835" dependencies = [ - "cipher 0.4.4", + "cipher", ] [[package]] @@ -1322,23 +1281,24 @@ dependencies = [ "byteorder", "digest 0.9.0", "rand_core 0.5.1", - "serde", "subtle 2.5.0", "zeroize", ] [[package]] name = "curve25519-dalek" -version = "4.1.1" +version = "4.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e89b8c6a2e4b1f45971ad09761aafb85514a84744b67a95e32c3cc1352d1f65c" +checksum = "0a677b8922c94e01bdbb12126b0bc852f00447528dee1782229af9c720c3f348" dependencies = [ "cfg-if", "cpufeatures", "curve25519-dalek-derive", + "digest 0.10.7", "fiat-crypto", "platforms", "rustc_version", + "serde", "subtle 2.5.0", "zeroize", ] @@ -1714,20 +1674,10 @@ dependencies = [ "elliptic-curve", "rfc6979", "serdect", - "signature 2.1.0", + "signature", "spki", ] -[[package]] -name = "ed25519" -version = "1.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" -dependencies = [ - "serde", - "signature 1.6.4", -] - [[package]] name = "ed25519" version = "2.2.2" @@ -1735,7 +1685,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "60f6d271ca33075c88028be6f04d502853d63a5ece419d269c15315d4fc1cf1d" dependencies = [ "pkcs8", - "signature 2.1.0", + "serde", + "signature", ] [[package]] @@ -1753,16 +1704,16 @@ dependencies = [ [[package]] name = "ed25519-dalek" -version = "1.0.1" +version = "2.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" +checksum = "4a3daa8e81a3963a60642bcc1f90a670680bd4a77535faa384e9d1c79d620871" dependencies = [ - "curve25519-dalek 3.2.0", - "ed25519 1.5.3", - "rand 0.7.3", + "curve25519-dalek 4.1.2", + "ed25519", + "rand_core 0.6.4", "serde", - "serde_bytes", - "sha2 0.9.9", + "sha2 0.10.8", + "subtle 2.5.0", "zeroize", ] @@ -2341,10 +2292,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" dependencies = [ "cfg-if", - "js-sys", "libc", "wasi 0.9.0+wasi-snapshot-preview1", - "wasm-bindgen", ] [[package]] @@ -2614,25 +2563,6 @@ dependencies = [ "tracing", ] -[[package]] -name = "h2" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" -dependencies = [ - "atomic-waker", - "bytes", - "fnv", - "futures-core", - "futures-sink", - "http 1.1.0", - "indexmap 2.0.0", - "slab", - "tokio", - "tokio-util", - "tracing", -] - [[package]] name = "handlebars" version = "3.5.5" @@ -2722,31 +2652,11 @@ checksum = "7ebdb29d2ea9ed0083cd8cece49bbd968021bd99b0849edb4a9a7ee0fdf6a4e0" [[package]] name = "hkdf" -version = "0.11.0" +version = "0.12.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01706d578d5c281058480e673ae4086a9f4710d8df1ad80a5b03e39ece5f886b" +checksum = "7b5f8eb2ad728638ea2c7d47a21db23b7b58a72ed6a38256b8a1849f15fbbdf7" dependencies = [ - "digest 0.9.0", - "hmac 0.11.0", -] - -[[package]] -name = "hkdf" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "791a029f6b9fc27657f6f188ec6e5e43f6911f6f878e0dc5501396e09809d437" -dependencies = [ - "hmac 0.12.1", -] - -[[package]] -name = "hmac" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a2a2320eb7ec0ebe8da8f744d7812d9fc4cb4d09344ac01898dbcb6a20ae69b" -dependencies = [ - "crypto-mac 0.11.0", - "digest 0.9.0", + "hmac", ] [[package]] @@ -2892,7 +2802,7 @@ dependencies = [ "futures-channel", "futures-core", "futures-util", - "h2 0.3.20", + "h2", "http 0.2.9", "http-body 0.4.5", "httparse", @@ -2915,7 +2825,6 @@ dependencies = [ "bytes", "futures-channel", "futures-util", - "h2 0.4.5", "http 1.1.0", "http-body 1.0.0", "httparse", @@ -2971,22 +2880,6 @@ dependencies = [ "tokio-native-tls", ] -[[package]] -name = "hyper-tls" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" -dependencies = [ - "bytes", - "http-body-util", - "hyper 1.2.0", - "hyper-util", - "native-tls", - "tokio", - "tokio-native-tls", - "tower-service", -] - [[package]] name = "hyper-util" version = "0.1.3" @@ -3266,7 +3159,7 @@ dependencies = [ "elliptic-curve", "once_cell", "sha2 0.10.8", - "signature 2.1.0", + "signature", ] [[package]] @@ -3401,9 +3294,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.20" +version = "0.4.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5e6163cb8c49088c2c36f57875e58ccd8c87c7427f7fbd50ea6710b2f3f2e8f" +checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" dependencies = [ "serde", ] @@ -3745,7 +3638,7 @@ dependencies = [ name = "nym-api-requests" version = "0.1.0" dependencies = [ - "bs58 0.5.0", + "bs58 0.5.1", "cosmrs", "cosmwasm-std", "ecdsa", @@ -3773,7 +3666,7 @@ dependencies = [ "nym-crypto", "nym-network-defaults", "nym-validator-client", - "rand 0.7.3", + "rand 0.8.5", "thiserror", "url", "zeroize", @@ -3801,7 +3694,7 @@ version = "1.1.15" dependencies = [ "async-trait", "base64 0.21.4", - "bs58 0.5.0", + "bs58 0.5.1", "cfg-if", "futures", "gloo-timers", @@ -3830,7 +3723,7 @@ dependencies = [ "nym-task", "nym-topology", "nym-validator-client", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde_json", "sha2 0.10.8", @@ -3904,7 +3797,7 @@ name = "nym-coconut" version = "0.5.0" dependencies = [ "bls12_381", - "bs58 0.5.0", + "bs58 0.5.1", "digest 0.9.0", "ff", "getrandom 0.2.10", @@ -3981,9 +3874,8 @@ dependencies = [ "nym-topology", "nym-validator-client", "pretty_env_logger", - "rand 0.7.3", "rand 0.8.5", - "reqwest 0.12.4", + "reqwest 0.11.22", "rust-embed", "sentry", "sentry-log", @@ -4009,7 +3901,7 @@ dependencies = [ name = "nym-contracts-common" version = "0.5.0" dependencies = [ - "bs58 0.5.0", + "bs58 0.5.1", "cosmwasm-schema", "cosmwasm-std", "schemars", @@ -4069,24 +3961,24 @@ dependencies = [ name = "nym-crypto" version = "0.4.0" dependencies = [ - "aes 0.8.3", + "aes", "blake3", - "bs58 0.5.0", - "cipher 0.4.4", - "ctr 0.9.2", + "bs58 0.5.1", + "cipher", + "ctr", "digest 0.10.7", "ed25519-dalek", "generic-array 0.14.7", - "hkdf 0.12.3", - "hmac 0.12.1", + "hkdf", + "hmac", "nym-pemstore", "nym-sphinx-types", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde_bytes", "subtle-encoding", "thiserror", - "x25519-dalek 1.1.1", + "x25519-dalek", "zeroize", ] @@ -4096,7 +3988,7 @@ version = "0.1.0" dependencies = [ "bitvec", "bls12_381", - "bs58 0.5.0", + "bs58 0.5.1", "ff", "group", "lazy_static", @@ -4171,7 +4063,7 @@ dependencies = [ "nym-sphinx", "nym-task", "nym-validator-client", - "rand 0.7.3", + "rand 0.8.5", "serde", "si-scale", "thiserror", @@ -4191,7 +4083,7 @@ dependencies = [ name = "nym-gateway-requests" version = "0.1.0" dependencies = [ - "bs58 0.5.0", + "bs58 0.5.1", "futures", "generic-array 0.14.7", "log", @@ -4200,7 +4092,7 @@ dependencies = [ "nym-crypto", "nym-pemstore", "nym-sphinx", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde_json", "thiserror", @@ -4363,10 +4255,10 @@ dependencies = [ "blake3", "chacha20", "chacha20poly1305", - "curve25519-dalek 3.2.0", + "curve25519-dalek 4.1.2", "getrandom 0.2.10", "log", - "rand 0.7.3", + "rand 0.8.5", "rayon", "sphinx-packet", "thiserror", @@ -4427,7 +4319,7 @@ dependencies = [ "nym-task", "nym-validator-client", "pin-project", - "rand 0.7.3", + "rand 0.8.5", "reqwest 0.12.4", "schemars", "serde", @@ -4483,7 +4375,7 @@ dependencies = [ "nym-sphinx-routing", "nym-sphinx-types", "nym-topology", - "rand 0.7.3", + "rand 0.8.5", "rand_distr", "thiserror", "tokio", @@ -4500,7 +4392,7 @@ dependencies = [ "nym-sphinx-routing", "nym-sphinx-types", "nym-topology", - "rand 0.7.3", + "rand 0.8.5", "thiserror", "zeroize", ] @@ -4519,14 +4411,14 @@ dependencies = [ name = "nym-sphinx-anonymous-replies" version = "0.1.0" dependencies = [ - "bs58 0.5.0", + "bs58 0.5.1", "nym-crypto", "nym-sphinx-addressing", "nym-sphinx-params", "nym-sphinx-routing", "nym-sphinx-types", "nym-topology", - "rand 0.7.3", + "rand 0.8.5", "serde", "thiserror", "wasm-bindgen", @@ -4540,7 +4432,7 @@ dependencies = [ "nym-sphinx-addressing", "nym-sphinx-params", "nym-sphinx-types", - "rand 0.7.3", + "rand 0.8.5", "thiserror", ] @@ -4557,7 +4449,7 @@ dependencies = [ "nym-sphinx-routing", "nym-sphinx-types", "nym-topology", - "rand 0.7.3", + "rand 0.8.5", "thiserror", ] @@ -4629,7 +4521,7 @@ name = "nym-topology" version = "0.1.0" dependencies = [ "async-trait", - "bs58 0.5.0", + "bs58 0.5.1", "log", "nym-api-requests", "nym-bin-common", @@ -4639,7 +4531,7 @@ dependencies = [ "nym-sphinx-addressing", "nym-sphinx-routing", "nym-sphinx-types", - "rand 0.7.3", + "rand 0.8.5", "semver 0.11.0", "serde", "serde_json", @@ -4714,10 +4606,12 @@ dependencies = [ "base64 0.21.4", "dashmap", "log", + "nym-config", "nym-crypto", + "nym-network-defaults", "serde", "thiserror", - "x25519-dalek 2.0.0", + "x25519-dalek", ] [[package]] @@ -4980,7 +4874,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" dependencies = [ "digest 0.10.7", - "hmac 0.12.1", + "hmac", ] [[package]] @@ -5517,12 +5411,12 @@ dependencies = [ [[package]] name = "rand_distr" -version = "0.3.0" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9e9532ada3929fb8b2e9dbe28d1e06c9b2cc65813f074fcb6bd5fbefeff9d56" +checksum = "32cb0b9bc82b0a0876c2dd994a7e7a2683d3e7390ca40e6886785ef0c7e3ee31" dependencies = [ "num-traits", - "rand 0.7.3", + "rand 0.8.5", ] [[package]] @@ -5655,12 +5549,12 @@ dependencies = [ "encoding_rs", "futures-core", "futures-util", - "h2 0.3.20", + "h2", "http 0.2.9", "http-body 0.4.5", "hyper 0.14.27", "hyper-rustls 0.24.1", - "hyper-tls 0.5.0", + "hyper-tls", "ipnet", "js-sys", "log", @@ -5679,6 +5573,7 @@ dependencies = [ "tokio", "tokio-native-tls", "tokio-rustls 0.24.1", + "tokio-socks", "tokio-util", "tower-service", "url", @@ -5697,22 +5592,18 @@ checksum = "566cafdd92868e0939d3fb961bd0dc25fcfaaed179291093b3d43e6b3150ea10" dependencies = [ "base64 0.22.1", "bytes", - "encoding_rs", "futures-core", "futures-util", - "h2 0.4.5", "http 1.1.0", "http-body 1.0.0", "http-body-util", "hyper 1.2.0", "hyper-rustls 0.26.0", - "hyper-tls 0.6.0", "hyper-util", "ipnet", "js-sys", "log", "mime", - "native-tls", "once_cell", "percent-encoding", "pin-project-lite", @@ -5723,11 +5614,8 @@ dependencies = [ "serde_json", "serde_urlencoded", "sync_wrapper", - "system-configuration", "tokio", - "tokio-native-tls", "tokio-rustls 0.25.0", - "tokio-socks", "tower-service", "url", "wasm-bindgen", @@ -5743,7 +5631,7 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f8dd2a808d456c4a54e300a23e9f5a67e122c3024119acbfd73e3bf664491cb2" dependencies = [ - "hmac 0.12.1", + "hmac", "subtle 2.5.0", ] @@ -6513,12 +6401,6 @@ dependencies = [ "libc", ] -[[package]] -name = "signature" -version = "1.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" - [[package]] name = "signature" version = "2.1.0" @@ -6606,25 +6488,26 @@ dependencies = [ [[package]] name = "sphinx-packet" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc43eda802856ee82a7555c7b75ceb9e07451741c7a2f5f23d036020e01189d4" +checksum = "dabeca95bf5fd0563d6be7ebcb1c6a9fcb135746a0ba9050c47dc68c8607e595" dependencies = [ - "aes 0.7.5", + "aes", "arrayref", "blake2", - "bs58 0.4.0", + "bs58 0.5.1", "byteorder", "chacha", - "curve25519-dalek 3.2.0", - "digest 0.9.0", - "hkdf 0.11.0", - "hmac 0.11.0", + "ctr", + "curve25519-dalek 4.1.2", + "digest 0.10.7", + "hkdf", + "hmac", "lioness", "log", - "rand 0.7.3", + "rand 0.8.5", "rand_distr", - "sha2 0.9.9", + "sha2 0.10.8", "subtle 2.5.0", ] @@ -7231,7 +7114,7 @@ checksum = "bc2294fa667c8b548ee27a9ba59115472d0a09c2ba255771092a7f1dcf03a789" dependencies = [ "bytes", "digest 0.10.7", - "ed25519 2.2.2", + "ed25519", "ed25519-consensus", "flex-error", "futures", @@ -7246,7 +7129,7 @@ dependencies = [ "serde_json", "serde_repr", "sha2 0.10.8", - "signature 2.1.0", + "signature", "subtle 2.5.0", "subtle-encoding", "tendermint-proto", @@ -8708,25 +8591,13 @@ dependencies = [ "pkg-config", ] -[[package]] -name = "x25519-dalek" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a0c105152107e3b96f6a00a65e86ce82d9b125230e1c4302940eca58ff71f4f" -dependencies = [ - "curve25519-dalek 3.2.0", - "rand_core 0.5.1", - "serde", - "zeroize", -] - [[package]] name = "x25519-dalek" version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fb66477291e7e8d2b0ff1bcb900bf29489a9692816d79874bea351e7a8b6de96" dependencies = [ - "curve25519-dalek 4.1.1", + "curve25519-dalek 4.1.2", "rand_core 0.6.4", "serde", "zeroize", diff --git a/nym-connect/desktop/src-tauri/Cargo.toml b/nym-connect/desktop/src-tauri/Cargo.toml index bace910d79..382203bb28 100644 --- a/nym-connect/desktop/src-tauri/Cargo.toml +++ b/nym-connect/desktop/src-tauri/Cargo.toml @@ -30,15 +30,24 @@ itertools = "0.10.5" log = { version = "0.4", features = ["serde"] } pretty_env_logger = "0.4.0" rand = "0.8" -rand-07 = { package = "rand", version = "0.7.3" } -reqwest = { version = "0.12.4", features = ["json", "socks"] } +reqwest = { version = "0.11.22", features = ["json", "socks"] } rust-embed = { version = "6.4.2", features = ["include-exclude"] } serde = { version = "1.0", features = ["derive"] } serde_json = "1.0" serde_repr = "0.1" tap = "1.0.1" # 07.07.23: JS: I changed the version from ^1.2.2 to fix up indirect import of web-sys -tauri = { version = "1.4.1", features = ["clipboard-write-text", "macos-private-api", "notification-all", "shell-open", "system-tray", "updater", "window-close", "window-minimize", "window-start-dragging"] } +tauri = { version = "1.4.1", features = [ + "clipboard-write-text", + "macos-private-api", + "notification-all", + "shell-open", + "system-tray", + "updater", + "window-close", + "window-minimize", + "window-start-dragging", +] } #tendermint-rpc = "0.23.0" thiserror = "1.0" time = { version = "0.3.30", features = ["local-offset"] } diff --git a/nym-connect/desktop/src-tauri/src/config/mod.rs b/nym-connect/desktop/src-tauri/src/config/mod.rs index 79b70f814b..adc00b48cd 100644 --- a/nym-connect/desktop/src-tauri/src/config/mod.rs +++ b/nym-connect/desktop/src-tauri/src/config/mod.rs @@ -20,7 +20,7 @@ use nym_config::{ }; use nym_crypto::asymmetric::identity; use nym_socks5_client_core::config::Config as Socks5CoreConfig; -use rand_07::rngs::OsRng; +use rand::rngs::OsRng; use serde::{Deserialize, Serialize}; use std::path::{Path, PathBuf}; use std::{fs, io}; @@ -214,7 +214,7 @@ pub async fn init_socks5_config(provider_address: String, chosen_gateway_id: Str let gateway_setup = if !already_init { let selection_spec = GatewaySelectionSpecification::new(Some(chosen_gateway_id), None, false); - let mut rng = rand_07::thread_rng(); + let mut rng = rand::thread_rng(); let available_gateways = current_gateways(&mut rng, &config.core.base.client.nym_api_urls).await?; GatewaySetup::New { diff --git a/nym-connect/desktop/src-tauri/src/operations/directory/gateways.rs b/nym-connect/desktop/src-tauri/src/operations/directory/gateways.rs index fca43e8fff..b868054b66 100644 --- a/nym-connect/desktop/src-tauri/src/operations/directory/gateways.rs +++ b/nym-connect/desktop/src-tauri/src/operations/directory/gateways.rs @@ -87,7 +87,7 @@ async fn select_gateway_by_latency(gateways: Vec) -> Resul .filter_map(|g| g.gateway_bond.try_into().ok()) .collect(); - let mut rng = rand_07::rngs::OsRng; + let mut rng = rand::rngs::OsRng; let selected_gateway = nym_client_core::init::helpers::choose_gateway_by_latency( &mut rng, &gateways_as_nodes, diff --git a/nym-node/Cargo.toml b/nym-node/Cargo.toml index dc20a99209..c80b926385 100644 --- a/nym-node/Cargo.toml +++ b/nym-node/Cargo.toml @@ -22,7 +22,7 @@ colored = { workspace = true } clap = { workspace = true, features = ["cargo", "env"] } humantime-serde = { workspace = true } ipnetwork = "0.16.0" -rand = "0.7.3" +rand = { workspace = true } serde = { workspace = true, features = ["derive"] } serde_json.workspace = true thiserror.workspace = true diff --git a/nym-node/nym-node-http-api/Cargo.toml b/nym-node/nym-node-http-api/Cargo.toml index 459765265e..65900fe68a 100644 --- a/nym-node/nym-node-http-api/Cargo.toml +++ b/nym-node/nym-node-http-api/Cargo.toml @@ -23,7 +23,7 @@ utoipa-swagger-ui = { workspace = true, features = ["axum"] } colored = { workspace = true } ipnetwork = "0.16" -rand = "0.7.3" +rand = { workspace = true } # Wireguard: fastrand = "2" diff --git a/nym-node/nym-node-requests/Cargo.toml b/nym-node/nym-node-requests/Cargo.toml index dd95f2a0e6..405700fbb4 100644 --- a/nym-node/nym-node-requests/Cargo.toml +++ b/nym-node/nym-node-requests/Cargo.toml @@ -37,7 +37,7 @@ nym-bin-common = { path = "../../common/bin-common", features = ["bin_info_schem [dev-dependencies] tokio = { workspace = true, features = ["full"] } -rand_chacha = "0.2" +rand_chacha = "0.3" nym-crypto = { path = "../../common/crypto", features = ["rand"] } diff --git a/nym-outfox/Cargo.toml b/nym-outfox/Cargo.toml index 9c0ac0563c..e992866177 100644 --- a/nym-outfox/Cargo.toml +++ b/nym-outfox/Cargo.toml @@ -19,7 +19,7 @@ chacha20poly1305 = { workspace = true } getrandom = { workspace = true, features = ["js"] } thiserror = { workspace = true } sphinx-packet = { workspace = true } -rand = "0.7.3" +rand = { workspace = true } log = { workspace = true } [dev-dependencies] diff --git a/nym-outfox/src/format.rs b/nym-outfox/src/format.rs index 4a9261bd3f..b6a7db01f4 100644 --- a/nym-outfox/src/format.rs +++ b/nym-outfox/src/format.rs @@ -241,7 +241,7 @@ impl MixStageParameters { }); } - let user_public_key = (&ED25519_BASEPOINT_TABLE * &user_secret_key).to_montgomery(); + let user_public_key = (ED25519_BASEPOINT_TABLE * &user_secret_key).to_montgomery(); let shared_key = user_secret_key * mix_public_key; // Copy rounting data into buffer diff --git a/nym-outfox/tests/unittests.rs b/nym-outfox/tests/unittests.rs index d89f6f85fe..8c258c4b7f 100644 --- a/nym-outfox/tests/unittests.rs +++ b/nym-outfox/tests/unittests.rs @@ -34,7 +34,7 @@ mod tests { let mix_secret = randombytes(32); let mix_secret_scalar = Scalar::from_bytes_mod_order(mix_secret.clone().try_into().unwrap()); - let mix_public_key = (&ED25519_BASEPOINT_TABLE * &mix_secret_scalar).to_montgomery(); + let mix_public_key = (ED25519_BASEPOINT_TABLE * &mix_secret_scalar).to_montgomery(); let routing = [0; 32]; let destination = [0; 32]; diff --git a/nym-wallet/Cargo.lock b/nym-wallet/Cargo.lock index fbbe326241..2bb7e00138 100644 --- a/nym-wallet/Cargo.lock +++ b/nym-wallet/Cargo.lock @@ -35,25 +35,12 @@ dependencies = [ [[package]] name = "aes" -version = "0.7.5" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e8b47f52ea9bae42228d07ec09eb676433d7c4ed1ebdf0f1d1c29ed446f1ab8" +checksum = "b169f7a6d4742236a0a00c541b845991d0ac43e546831af1249753ab4c3aa3a0" dependencies = [ "cfg-if", - "cipher 0.3.0", - "cpufeatures", - "ctr 0.8.0", - "opaque-debug 0.3.0", -] - -[[package]] -name = "aes" -version = "0.8.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac1f845298e95f983ff1944b728ae08b8cebab80d684f0a832ed0fc74dfa27e2" -dependencies = [ - "cfg-if", - "cipher 0.4.4", + "cipher", "cpufeatures", ] @@ -64,9 +51,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "209b47e8954a928e1d72e86eca7000ebb6655fe1436d33eefc2201cad027e237" dependencies = [ "aead", - "aes 0.8.3", - "cipher 0.4.4", - "ctr 0.9.2", + "aes", + "cipher", + "ctr", "ghash", "subtle 2.5.0", ] @@ -303,8 +290,8 @@ version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7e141fb0f8be1c7b45887af94c88b182472b57c96b56773250ae00cd6a14a164" dependencies = [ - "bs58 0.5.0", - "hmac 0.12.1", + "bs58 0.5.1", + "hmac", "k256", "once_cell", "pbkdf2", @@ -366,7 +353,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94cb07b0da6a73955f8fb85d24c466778e70cda767a568229b104f0264089330" dependencies = [ "byte-tools", - "crypto-mac 0.7.0", + "crypto-mac", "digest 0.8.1", "opaque-debug 0.2.3", ] @@ -453,9 +440,9 @@ checksum = "771fe0050b883fcc3ea2359b1a96bcfbc090b7116eae7c3c512c7a083fdf23d3" [[package]] name = "bs58" -version = "0.5.0" +version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f5353f36341f7451062466f0b755b96ac3a9547e4d7f6b70d603fc721a7d7896" +checksum = "bf88ba1141d185c399bee5288d850d63b8369520c1eafc32a0430b5b6c287bf4" dependencies = [ "sha2 0.10.8", "tinyvec", @@ -491,9 +478,9 @@ checksum = "17febce684fd15d89027105661fec94afb475cb995fbc59d2865198446ba2eea" [[package]] name = "byteorder" -version = "1.4.3" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "bytes" @@ -607,15 +594,6 @@ dependencies = [ "keystream", ] -[[package]] -name = "cipher" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ee52072ec15386f770805afd189a01c8841be8696bed250fa2f13c4c0d6dfb7" -dependencies = [ - "generic-array 0.14.7", -] - [[package]] name = "cipher" version = "0.4.4" @@ -853,7 +831,7 @@ dependencies = [ "rand_core 0.6.4", "serde", "serde_json", - "signature 2.1.0", + "signature", "subtle-encoding", "tendermint", "thiserror", @@ -872,7 +850,7 @@ dependencies = [ "rand_core 0.6.4", "serde", "serde_json", - "signature 2.1.0", + "signature", "subtle-encoding", "tendermint", "tendermint-rpc", @@ -1016,16 +994,6 @@ dependencies = [ "subtle 1.0.0", ] -[[package]] -name = "crypto-mac" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25fab6889090c8133f3deb8f73ba3c65a7f456f66436fc012a1b1e272b1e103e" -dependencies = [ - "generic-array 0.14.7", - "subtle 2.5.0", -] - [[package]] name = "cssparser" version = "0.27.2" @@ -1063,22 +1031,13 @@ dependencies = [ "syn 1.0.109", ] -[[package]] -name = "ctr" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "049bb91fb4aaf0e3c7efa6cd5ef877dbbbd15b39dad06d9948de4ec8a75761ea" -dependencies = [ - "cipher 0.3.0", -] - [[package]] name = "ctr" version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0369ee1ad671834580515889b80f2ea915f23b8be8d0daa4bbaf2ac5c7590835" dependencies = [ - "cipher 0.4.4", + "cipher", ] [[package]] @@ -1090,23 +1049,24 @@ dependencies = [ "byteorder", "digest 0.9.0", "rand_core 0.5.1", - "serde", "subtle 2.5.0", "zeroize", ] [[package]] name = "curve25519-dalek" -version = "4.1.1" +version = "4.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e89b8c6a2e4b1f45971ad09761aafb85514a84744b67a95e32c3cc1352d1f65c" +checksum = "0a677b8922c94e01bdbb12126b0bc852f00447528dee1782229af9c720c3f348" dependencies = [ "cfg-if", "cpufeatures", "curve25519-dalek-derive", + "digest 0.10.7", "fiat-crypto", "platforms", "rustc_version", + "serde", "subtle 2.5.0", "zeroize", ] @@ -1466,20 +1426,10 @@ dependencies = [ "elliptic-curve", "rfc6979", "serdect", - "signature 2.1.0", + "signature", "spki", ] -[[package]] -name = "ed25519" -version = "1.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" -dependencies = [ - "serde", - "signature 1.6.4", -] - [[package]] name = "ed25519" version = "2.2.2" @@ -1487,7 +1437,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "60f6d271ca33075c88028be6f04d502853d63a5ece419d269c15315d4fc1cf1d" dependencies = [ "pkcs8", - "signature 2.1.0", + "serde", + "signature", ] [[package]] @@ -1505,16 +1456,16 @@ dependencies = [ [[package]] name = "ed25519-dalek" -version = "1.0.1" +version = "2.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" +checksum = "4a3daa8e81a3963a60642bcc1f90a670680bd4a77535faa384e9d1c79d620871" dependencies = [ - "curve25519-dalek 3.2.0", - "ed25519 1.5.3", - "rand 0.7.3", + "curve25519-dalek 4.1.2", + "ed25519", + "rand_core 0.6.4", "serde", - "serde_bytes", - "sha2 0.9.9", + "sha2 0.10.8", + "subtle 2.5.0", "zeroize", ] @@ -1970,10 +1921,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" dependencies = [ "cfg-if", - "js-sys", "libc", "wasi 0.9.0+wasi-snapshot-preview1", - "wasm-bindgen", ] [[package]] @@ -2299,22 +2248,11 @@ checksum = "7ebdb29d2ea9ed0083cd8cece49bbd968021bd99b0849edb4a9a7ee0fdf6a4e0" [[package]] name = "hkdf" -version = "0.11.0" +version = "0.12.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01706d578d5c281058480e673ae4086a9f4710d8df1ad80a5b03e39ece5f886b" +checksum = "7b5f8eb2ad728638ea2c7d47a21db23b7b58a72ed6a38256b8a1849f15fbbdf7" dependencies = [ - "digest 0.9.0", - "hmac 0.11.0", -] - -[[package]] -name = "hmac" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a2a2320eb7ec0ebe8da8f744d7812d9fc4cb4d09344ac01898dbcb6a20ae69b" -dependencies = [ - "crypto-mac 0.11.0", - "digest 0.9.0", + "hmac", ] [[package]] @@ -2781,7 +2719,7 @@ dependencies = [ "elliptic-curve", "once_cell", "sha2 0.10.8", - "signature 2.1.0", + "signature", ] [[package]] @@ -2859,9 +2797,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.20" +version = "0.4.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5e6163cb8c49088c2c36f57875e58ccd8c87c7427f7fbd50ea6710b2f3f2e8f" +checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" dependencies = [ "serde", ] @@ -3133,7 +3071,7 @@ dependencies = [ name = "nym-api-requests" version = "0.1.0" dependencies = [ - "bs58 0.5.0", + "bs58 0.5.1", "cosmrs 0.15.0 (git+https://github.com/jstuczyn/cosmos-rust?branch=nym-temp/all-validator-features)", "cosmwasm-std", "ecdsa", @@ -3169,7 +3107,7 @@ name = "nym-coconut" version = "0.5.0" dependencies = [ "bls12_381", - "bs58 0.5.0", + "bs58 0.5.1", "digest 0.9.0", "ff", "getrandom 0.2.10", @@ -3223,7 +3161,7 @@ dependencies = [ name = "nym-contracts-common" version = "0.5.0" dependencies = [ - "bs58 0.5.0", + "bs58 0.5.1", "cosmwasm-schema", "cosmwasm-std", "schemars", @@ -3245,16 +3183,16 @@ dependencies = [ name = "nym-crypto" version = "0.4.0" dependencies = [ - "bs58 0.5.0", + "bs58 0.5.1", "ed25519-dalek", "nym-pemstore", "nym-sphinx-types", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde_bytes", "subtle-encoding", "thiserror", - "x25519-dalek 1.1.1", + "x25519-dalek", "zeroize", ] @@ -3264,7 +3202,7 @@ version = "0.1.0" dependencies = [ "bitvec", "bls12_381", - "bs58 0.5.0", + "bs58 0.5.1", "ff", "group", "lazy_static", @@ -3455,7 +3393,7 @@ dependencies = [ "cosmrs 0.15.0 (git+https://github.com/jstuczyn/cosmos-rust?branch=nym-temp/all-validator-features)", "cosmwasm-std", "eyre", - "hmac 0.12.1", + "hmac", "itertools 0.11.0", "log", "nym-config", @@ -3472,7 +3410,7 @@ dependencies = [ "thiserror", "ts-rs", "url", - "x25519-dalek 2.0.0", + "x25519-dalek", ] [[package]] @@ -3577,10 +3515,12 @@ dependencies = [ "base64 0.21.4", "dashmap", "log", + "nym-config", "nym-crypto", + "nym-network-defaults", "serde", "thiserror", - "x25519-dalek 2.0.0", + "x25519-dalek", ] [[package]] @@ -3613,7 +3553,7 @@ dependencies = [ "nym-wallet-types", "once_cell", "pretty_env_logger", - "rand_chacha 0.2.2", + "rand_chacha 0.3.1", "reqwest 0.12.4", "serde", "serde_json", @@ -3853,7 +3793,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" dependencies = [ "digest 0.10.7", - "hmac 0.12.1", + "hmac", ] [[package]] @@ -4345,12 +4285,12 @@ dependencies = [ [[package]] name = "rand_distr" -version = "0.3.0" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9e9532ada3929fb8b2e9dbe28d1e06c9b2cc65813f074fcb6bd5fbefeff9d56" +checksum = "32cb0b9bc82b0a0876c2dd994a7e7a2683d3e7390ca40e6886785ef0c7e3ee31" dependencies = [ "num-traits", - "rand 0.7.3", + "rand 0.8.5", ] [[package]] @@ -4543,7 +4483,7 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f8dd2a808d456c4a54e300a23e9f5a67e122c3024119acbfd73e3bf664491cb2" dependencies = [ - "hmac 0.12.1", + "hmac", "subtle 2.5.0", ] @@ -5072,12 +5012,6 @@ dependencies = [ "libc", ] -[[package]] -name = "signature" -version = "1.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" - [[package]] name = "signature" version = "2.1.0" @@ -5165,25 +5099,26 @@ dependencies = [ [[package]] name = "sphinx-packet" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc43eda802856ee82a7555c7b75ceb9e07451741c7a2f5f23d036020e01189d4" +checksum = "dabeca95bf5fd0563d6be7ebcb1c6a9fcb135746a0ba9050c47dc68c8607e595" dependencies = [ - "aes 0.7.5", + "aes", "arrayref", "blake2 0.8.1", - "bs58 0.4.0", + "bs58 0.5.1", "byteorder", "chacha", - "curve25519-dalek 3.2.0", - "digest 0.9.0", + "ctr", + "curve25519-dalek 4.1.2", + "digest 0.10.7", "hkdf", - "hmac 0.11.0", + "hmac", "lioness", "log", - "rand 0.7.3", + "rand 0.8.5", "rand_distr", - "sha2 0.9.9", + "sha2 0.10.8", "subtle 2.5.0", ] @@ -5663,7 +5598,7 @@ checksum = "bc2294fa667c8b548ee27a9ba59115472d0a09c2ba255771092a7f1dcf03a789" dependencies = [ "bytes", "digest 0.10.7", - "ed25519 2.2.2", + "ed25519", "ed25519-consensus", "flex-error", "futures", @@ -5678,7 +5613,7 @@ dependencies = [ "serde_json", "serde_repr", "sha2 0.10.8", - "signature 2.1.0", + "signature", "subtle 2.5.0", "subtle-encoding", "tendermint-proto", @@ -6840,25 +6775,13 @@ dependencies = [ "pkg-config", ] -[[package]] -name = "x25519-dalek" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a0c105152107e3b96f6a00a65e86ce82d9b125230e1c4302940eca58ff71f4f" -dependencies = [ - "curve25519-dalek 3.2.0", - "rand_core 0.5.1", - "serde", - "zeroize", -] - [[package]] name = "x25519-dalek" version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fb66477291e7e8d2b0ff1bcb900bf29489a9692816d79874bea351e7a8b6de96" dependencies = [ - "curve25519-dalek 4.1.1", + "curve25519-dalek 4.1.2", "rand_core 0.6.4", "serde", "zeroize", diff --git a/nym-wallet/src-tauri/Cargo.toml b/nym-wallet/src-tauri/Cargo.toml index 69badaf8a4..75a4046264 100644 --- a/nym-wallet/src-tauri/Cargo.toml +++ b/nym-wallet/src-tauri/Cargo.toml @@ -64,7 +64,7 @@ nym-store-cipher = { path = "../../common/store-cipher", features = ["json"] } [dev-dependencies] nym-crypto = { path = "../../common/crypto", features = ["rand"] } -rand_chacha = "0.2" +rand_chacha = "0.3" tempfile = "3.3.0" ts-rs = "7.0.0" diff --git a/nym-wallet/src-tauri/src/error.rs b/nym-wallet/src-tauri/src/error.rs index 7f542d257c..1ed617dc4b 100644 --- a/nym-wallet/src-tauri/src/error.rs +++ b/nym-wallet/src-tauri/src/error.rs @@ -1,5 +1,4 @@ use nym_contracts_common::signing::SigningAlgorithm; -use nym_crypto::asymmetric::identity; use nym_crypto::asymmetric::identity::Ed25519RecoveryError; use nym_types::error::TypesError; use nym_validator_client::nym_api::error::NymAPIError; @@ -150,9 +149,6 @@ pub enum BackendError { #[error(transparent)] Ed25519Recovery(#[from] Ed25519RecoveryError), - #[error("failed to verify ed25519 signature: {0}")] - Ed25519SignatureError(#[from] identity::SignatureError), - #[error("This command ({name}) has been removed. Please try to use {alternative} instead.")] RemovedCommand { name: String, alternative: String }, } diff --git a/sdk/lib/socks5-listener/Cargo.toml b/sdk/lib/socks5-listener/Cargo.toml index 7ce61839e7..6463d4eb74 100644 --- a/sdk/lib/socks5-listener/Cargo.toml +++ b/sdk/lib/socks5-listener/Cargo.toml @@ -26,7 +26,7 @@ nym-socks5-client-core = { path = "../../../common/socks5-client-core", default- serde = { workspace = true } tokio = { workspace = true, features = ["sync", "time"] } log = { workspace = true } -rand = "0.7.3" +rand = { workspace = true } safer-ffi = { workspace = true } diff --git a/sdk/rust/nym-sdk/Cargo.toml b/sdk/rust/nym-sdk/Cargo.toml index 93d7b9c4cc..b657db8570 100644 --- a/sdk/rust/nym-sdk/Cargo.toml +++ b/sdk/rust/nym-sdk/Cargo.toml @@ -32,7 +32,7 @@ http = { workspace = true } futures = { workspace = true } log = { workspace = true } -rand = { version = "0.7.3" } +rand = { workspace = true } tap = { workspace = true } thiserror = { workspace = true } url = { workspace = true } diff --git a/service-providers/network-requester/Cargo.toml b/service-providers/network-requester/Cargo.toml index 2c236f6487..e023108192 100644 --- a/service-providers/network-requester/Cargo.toml +++ b/service-providers/network-requester/Cargo.toml @@ -28,7 +28,7 @@ ipnetwork = "0.20.0" log = { workspace = true } pretty_env_logger = { workspace = true } publicsuffix = { workspace = true } -rand = "0.7.3" +rand = { workspace = true } regex = { workspace = true } reqwest = { workspace = true, features = ["json"] } serde = { workspace = true, features = ["derive"] } diff --git a/wasm/client/Cargo.toml b/wasm/client/Cargo.toml index 0674a1ebf6..48589a20c2 100644 --- a/wasm/client/Cargo.toml +++ b/wasm/client/Cargo.toml @@ -16,7 +16,7 @@ crate-type = ["cdylib", "rlib"] anyhow = { workspace = true } futures = { workspace = true } js-sys = { workspace = true } -rand = { version = "0.7.3", features = ["wasm-bindgen"] } +rand = { workspace = true } serde = { workspace = true, features = ["derive"] } serde_json = { workspace = true } serde-wasm-bindgen = { workspace = true } diff --git a/wasm/mix-fetch/Cargo.toml b/wasm/mix-fetch/Cargo.toml index 373b6d423f..fd187f04e1 100644 --- a/wasm/mix-fetch/Cargo.toml +++ b/wasm/mix-fetch/Cargo.toml @@ -17,7 +17,7 @@ crate-type = ["cdylib", "rlib"] async-trait = { workspace = true } futures = { workspace = true } js-sys = { workspace = true } -rand = { version = "0.7.3", features = ["wasm-bindgen"] } +rand = { workspace = true } serde = { workspace = true, features = ["derive"] } serde-wasm-bindgen = { workspace = true } tokio = { workspace = true, features = ["sync"] } diff --git a/wasm/node-tester/Cargo.toml b/wasm/node-tester/Cargo.toml index fd295cd0e3..b2330c04ae 100644 --- a/wasm/node-tester/Cargo.toml +++ b/wasm/node-tester/Cargo.toml @@ -16,7 +16,7 @@ crate-type = ["cdylib", "rlib"] [dependencies] futures = { workspace = true } js-sys = { workspace = true } -rand = { version = "0.7.3", features = ["wasm-bindgen"] } +rand = { workspace = true } serde = { workspace = true, features = ["derive"] } serde-wasm-bindgen = { workspace = true } tokio = { workspace = true, features = ["sync"] }