nodes are not connecting to themselves anymore
Signed-off-by: Valentyn Faychuk <valy@detee.ltd>
This commit is contained in:
parent
3b960ed596
commit
1916d9037d
20
Cargo.lock
generated
20
Cargo.lock
generated
@ -1470,20 +1470,6 @@ dependencies = [
|
||||
"parking_lot_core",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "dashmap"
|
||||
version = "6.1.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "5041cc499144891f3790297212f32a74fb938e5136a14943f338ef9e0ae276cf"
|
||||
dependencies = [
|
||||
"cfg-if",
|
||||
"crossbeam-utils",
|
||||
"hashbrown 0.14.5",
|
||||
"lock_api",
|
||||
"once_cell",
|
||||
"parking_lot_core",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "data-encoding"
|
||||
version = "2.6.0"
|
||||
@ -2113,13 +2099,11 @@ dependencies = [
|
||||
"actix-web",
|
||||
"async-stream",
|
||||
"chrono",
|
||||
"dashmap 6.1.0",
|
||||
"detee-sgx",
|
||||
"env_logger 0.11.5",
|
||||
"hyper 1.4.1",
|
||||
"hyper-rustls 0.27.3",
|
||||
"hyper-util",
|
||||
"once_cell",
|
||||
"prost",
|
||||
"prost-types",
|
||||
"public-ip",
|
||||
@ -4277,7 +4261,7 @@ checksum = "67169e4f1faabb717ce81b5ca93960da21e3ac5c9b75cb6792f9b3ce38db459f"
|
||||
dependencies = [
|
||||
"async-trait",
|
||||
"bincode",
|
||||
"dashmap 5.5.3",
|
||||
"dashmap",
|
||||
"futures",
|
||||
"futures-util",
|
||||
"indexmap 2.6.0",
|
||||
@ -4753,7 +4737,7 @@ dependencies = [
|
||||
"async-channel",
|
||||
"bytes",
|
||||
"crossbeam-channel",
|
||||
"dashmap 5.5.3",
|
||||
"dashmap",
|
||||
"futures-util",
|
||||
"histogram",
|
||||
"indexmap 2.6.0",
|
||||
|
@ -122,7 +122,7 @@ impl State {
|
||||
|
||||
fn delete_mratls_conn(&self, ip: &str) {
|
||||
if let Ok(mut conns) = self.conns.write() {
|
||||
conns.insert(ip.to_string());
|
||||
conns.remove(ip);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -14,7 +14,7 @@ pub async fn grpc_new_conn(
|
||||
ra_cfg: RaTlsConfig,
|
||||
tx: Sender<InternalNodeUpdate>,
|
||||
) {
|
||||
if Ipv4Addr::from_str(&node_ip).is_err() {
|
||||
if Ipv4Addr::from_str(&node_ip).is_err() || node_ip == state.get_my_ip() {
|
||||
println!("IPv4 address is invalid: {node_ip}");
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user