From e388e67357a880febcc807a15ba9614b78132122 Mon Sep 17 00:00:00 2001 From: benedettadavico Date: Wed, 17 Sep 2025 12:40:40 +0200 Subject: [PATCH 1/5] bump versions --- Cargo.lock | 12 ++++++------ clients/native/Cargo.toml | 2 +- clients/socks5/Cargo.toml | 2 +- nym-api/Cargo.toml | 2 +- service-providers/network-requester/Cargo.toml | 2 +- tools/nym-cli/Cargo.toml | 2 +- tools/nymvisor/Cargo.toml | 2 +- 7 files changed, 12 insertions(+), 12 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 50b104fe5d..da3593f540 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -4883,7 +4883,7 @@ dependencies = [ [[package]] name = "nym-api" -version = "1.1.65" +version = "1.1.66" dependencies = [ "anyhow", "async-trait", @@ -5095,7 +5095,7 @@ dependencies = [ [[package]] name = "nym-cli" -version = "1.1.62" +version = "1.1.63" dependencies = [ "anyhow", "base64 0.22.1", @@ -5178,7 +5178,7 @@ dependencies = [ [[package]] name = "nym-client" -version = "1.1.62" +version = "1.1.63" dependencies = [ "bs58", "clap", @@ -6316,7 +6316,7 @@ dependencies = [ [[package]] name = "nym-network-requester" -version = "1.1.63" +version = "1.1.64" dependencies = [ "addr", "anyhow", @@ -6853,7 +6853,7 @@ dependencies = [ [[package]] name = "nym-socks5-client" -version = "1.1.62" +version = "1.1.63" dependencies = [ "bs58", "clap", @@ -7611,7 +7611,7 @@ dependencies = [ [[package]] name = "nymvisor" -version = "0.1.27" +version = "0.1.28" dependencies = [ "anyhow", "bytes", diff --git a/clients/native/Cargo.toml b/clients/native/Cargo.toml index 3736fc047c..9ac6a9ae3a 100644 --- a/clients/native/Cargo.toml +++ b/clients/native/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "nym-client" -version = "1.1.62" +version = "1.1.63" authors = ["Dave Hrycyszyn ", "Jędrzej Stuczyński "] description = "Implementation of the Nym Client" edition = "2021" diff --git a/clients/socks5/Cargo.toml b/clients/socks5/Cargo.toml index a4b1af15be..e2ed20d193 100644 --- a/clients/socks5/Cargo.toml +++ b/clients/socks5/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "nym-socks5-client" -version = "1.1.62" +version = "1.1.63" authors = ["Dave Hrycyszyn "] description = "A SOCKS5 localhost proxy that converts incoming messages to Sphinx and sends them to a Nym address" edition = "2021" diff --git a/nym-api/Cargo.toml b/nym-api/Cargo.toml index ae07fc671c..95d74bdb42 100644 --- a/nym-api/Cargo.toml +++ b/nym-api/Cargo.toml @@ -4,7 +4,7 @@ [package] name = "nym-api" license = "GPL-3.0" -version = "1.1.65" +version = "1.1.66" authors.workspace = true edition = "2021" rust-version.workspace = true diff --git a/service-providers/network-requester/Cargo.toml b/service-providers/network-requester/Cargo.toml index e9829ca4ef..d13c60bc1f 100644 --- a/service-providers/network-requester/Cargo.toml +++ b/service-providers/network-requester/Cargo.toml @@ -4,7 +4,7 @@ [package] name = "nym-network-requester" license = "GPL-3.0" -version = "1.1.63" +version = "1.1.64" authors.workspace = true edition.workspace = true rust-version = "1.70" diff --git a/tools/nym-cli/Cargo.toml b/tools/nym-cli/Cargo.toml index 8b46302ef6..8faf013dad 100644 --- a/tools/nym-cli/Cargo.toml +++ b/tools/nym-cli/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "nym-cli" -version = "1.1.62" +version = "1.1.63" authors.workspace = true edition = "2021" license.workspace = true diff --git a/tools/nymvisor/Cargo.toml b/tools/nymvisor/Cargo.toml index e2752b4095..e1607edab0 100644 --- a/tools/nymvisor/Cargo.toml +++ b/tools/nymvisor/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "nymvisor" -version = "0.1.27" +version = "0.1.28" authors.workspace = true repository.workspace = true homepage.workspace = true From 810b0628bbd27bdb67e181156fa79bfcf10dab97 Mon Sep 17 00:00:00 2001 From: benedettadavico Date: Wed, 24 Sep 2025 14:06:42 +0200 Subject: [PATCH 2/5] testing fixes --- .../websocket/connection_handler/fresh.rs | 79 ++++++++++--------- 1 file changed, 43 insertions(+), 36 deletions(-) diff --git a/gateway/src/node/client_handling/websocket/connection_handler/fresh.rs b/gateway/src/node/client_handling/websocket/connection_handler/fresh.rs index ab308e7f8e..b7fe12fc3a 100644 --- a/gateway/src/node/client_handling/websocket/connection_handler/fresh.rs +++ b/gateway/src/node/client_handling/websocket/connection_handler/fresh.rs @@ -922,47 +922,54 @@ impl FreshHandler { S: AsyncRead + AsyncWrite + Unpin + Send, R: CryptoRng + RngCore + Send, { - let initial_request = match self.wait_for_initial_message().await { - Ok(req) => req, - Err(err) => { - self.send_and_forget_error_response(err).await; + let shutdown = self.shutdown.clone(); + loop { + if shutdown.is_cancelled() { + trace!("received cancellation before authentication"); return None; } - }; - // see if we managed to register the client through this request - let maybe_auth_res = match self.handle_initial_client_request(initial_request).await { - Ok(maybe_auth_res) => maybe_auth_res, - Err(err) => { - debug!("initial client request handling error: {err}"); - self.send_and_forget_error_response(err).await; - return None; + let req = self.wait_for_initial_message().await; + let initial_request = match req { + Ok(req) => req, + Err(err) => { + self.send_and_forget_error_response(err).await; + return None; + } + }; + + // see if we managed to register the client through this request + let maybe_auth_res = match self.handle_initial_client_request(initial_request).await { + Ok(maybe_auth_res) => maybe_auth_res, + Err(err) => { + debug!("initial client request handling error: {err}"); + self.send_and_forget_error_response(err).await; + return None; + } + }; + + if let Some(registration_details) = maybe_auth_res { + let (mix_sender, mix_receiver) = mpsc::unbounded(); + // Channel for handlers to ask other handlers if they are still active. + let (is_active_request_sender, is_active_request_receiver) = mpsc::unbounded(); + self.shared_state.active_clients_store.insert_remote( + registration_details.address, + mix_sender, + is_active_request_sender, + registration_details.session_request_timestamp, + ); + + return AuthenticatedHandler::upgrade( + self, + registration_details, + mix_receiver, + is_active_request_receiver, + ) + .await + .inspect_err(|err| error!("failed to upgrade client handler: {err}")) + .ok(); } - }; - - if let Some(registration_details) = maybe_auth_res { - let (mix_sender, mix_receiver) = mpsc::unbounded(); - // Channel for handlers to ask other handlers if they are still active. - let (is_active_request_sender, is_active_request_receiver) = mpsc::unbounded(); - self.shared_state.active_clients_store.insert_remote( - registration_details.address, - mix_sender, - is_active_request_sender, - registration_details.session_request_timestamp, - ); - - AuthenticatedHandler::upgrade( - self, - registration_details, - mix_receiver, - is_active_request_receiver, - ) - .await - .inspect_err(|err| error!("failed to upgrade client handler: {err}")) - .ok(); } - - None } pub(crate) async fn wait_for_initial_message( From 7bf5553fd11dded7ca3c8b2017bd2fdae38e22f4 Mon Sep 17 00:00:00 2001 From: benedetta davico <46782255+benedettadavico@users.noreply.github.com> Date: Wed, 24 Sep 2025 14:15:23 +0200 Subject: [PATCH 3/5] Update ci-build-upload-binaries.yml --- .github/workflows/ci-build-upload-binaries.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-build-upload-binaries.yml b/.github/workflows/ci-build-upload-binaries.yml index 3986f1ddae..90ad59c627 100644 --- a/.github/workflows/ci-build-upload-binaries.yml +++ b/.github/workflows/ci-build-upload-binaries.yml @@ -21,7 +21,7 @@ jobs: strategy: fail-fast: false matrix: - platform: [ arc-ubuntu-22.04 ] + platform: [ arc-linux-latest ] runs-on: ${{ matrix.platform }} env: From 7147ba56e26aa816440c3133e99e213342f80d2a Mon Sep 17 00:00:00 2001 From: benedettadavico Date: Wed, 24 Sep 2025 14:40:53 +0200 Subject: [PATCH 4/5] adding log --- .../websocket/connection_handler/fresh.rs | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/gateway/src/node/client_handling/websocket/connection_handler/fresh.rs b/gateway/src/node/client_handling/websocket/connection_handler/fresh.rs index b7fe12fc3a..78a1598216 100644 --- a/gateway/src/node/client_handling/websocket/connection_handler/fresh.rs +++ b/gateway/src/node/client_handling/websocket/connection_handler/fresh.rs @@ -922,12 +922,14 @@ impl FreshHandler { S: AsyncRead + AsyncWrite + Unpin + Send, R: CryptoRng + RngCore + Send, { - let shutdown = self.shutdown.clone(); + let mut loop_iter: usize = 0; loop { - if shutdown.is_cancelled() { - trace!("received cancellation before authentication"); - return None; - } + loop_iter += 1; + debug!( + remote = %self.peer_address, + iteration = loop_iter, + "running loop" + ); let req = self.wait_for_initial_message().await; let initial_request = match req { From 7bcd3fe75487f9a75de8ab2f59c34743abf48edd Mon Sep 17 00:00:00 2001 From: Simon Wicky Date: Wed, 24 Sep 2025 15:14:42 +0200 Subject: [PATCH 5/5] fixy fix --- .../client_handling/websocket/connection_handler/fresh.rs | 8 -------- 1 file changed, 8 deletions(-) diff --git a/gateway/src/node/client_handling/websocket/connection_handler/fresh.rs b/gateway/src/node/client_handling/websocket/connection_handler/fresh.rs index 78a1598216..54d6e02f6e 100644 --- a/gateway/src/node/client_handling/websocket/connection_handler/fresh.rs +++ b/gateway/src/node/client_handling/websocket/connection_handler/fresh.rs @@ -922,15 +922,7 @@ impl FreshHandler { S: AsyncRead + AsyncWrite + Unpin + Send, R: CryptoRng + RngCore + Send, { - let mut loop_iter: usize = 0; loop { - loop_iter += 1; - debug!( - remote = %self.peer_address, - iteration = loop_iter, - "running loop" - ); - let req = self.wait_for_initial_message().await; let initial_request = match req { Ok(req) => req,