From c0a03fb8f8fcfcbb4f6ce813afe04f6c66751cdc Mon Sep 17 00:00:00 2001 From: Thomas Braun Date: Wed, 18 Dec 2024 18:03:47 -0500 Subject: [PATCH] chore: cleanup --- crates/networking/src/handlers/connections.rs | 1 - crates/networking/src/handlers/p2p.rs | 3 --- 2 files changed, 4 deletions(-) diff --git a/crates/networking/src/handlers/connections.rs b/crates/networking/src/handlers/connections.rs index c37795d..bf66860 100644 --- a/crates/networking/src/handlers/connections.rs +++ b/crates/networking/src/handlers/connections.rs @@ -23,7 +23,6 @@ impl NetworkService<'_> { { let my_peer_id = *self.swarm.local_peer_id(); let msg = my_peer_id.to_bytes(); - //let hash = blake3_256(&msg); match ::sign_with_secret(&mut self.secret_key.clone(), &msg) { Ok(signature) => { let handshake = MyBehaviourRequest::Handshake { diff --git a/crates/networking/src/handlers/p2p.rs b/crates/networking/src/handlers/p2p.rs index e92a88f..eb39e3d 100644 --- a/crates/networking/src/handlers/p2p.rs +++ b/crates/networking/src/handlers/p2p.rs @@ -90,7 +90,6 @@ impl NetworkService<'_> { gadget_logging::trace!("Received handshake from peer: {peer}"); // Verify the signature let msg = peer.to_bytes(); - //let hash = blake3_256(&msg); let valid = ::verify(&public_key, &msg, &signature); if !valid { gadget_logging::warn!("Invalid initial handshake signature from peer: {peer}"); @@ -109,7 +108,6 @@ impl NetworkService<'_> { // Send response with our public key let my_peer_id = self.swarm.local_peer_id(); let msg = my_peer_id.to_bytes(); - //let hash = blake3_256(&msg); match ::sign_with_secret(&mut self.secret_key.clone(), &msg) { Ok(signature) => self.swarm.behaviour_mut().p2p.send_response( channel, @@ -168,7 +166,6 @@ impl NetworkService<'_> { } => { gadget_logging::trace!("Received handshake-ack message from peer: {peer}"); let msg = peer.to_bytes(); - //let hash = blake3_256(&msg); let valid = ::verify(&public_key, &msg, &signature); if !valid { gadget_logging::warn!(