From 21ecd64ff86c555ef0c1fa5f543f0b7660aa44e0 Mon Sep 17 00:00:00 2001 From: Christien Rioux Date: Sat, 15 Jul 2023 20:03:58 -0400 Subject: [PATCH] loosen up on dropped rpcs --- veilid-core/src/rpc_processor/mod.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/veilid-core/src/rpc_processor/mod.rs b/veilid-core/src/rpc_processor/mod.rs index ec496eb9..3f73c048 100644 --- a/veilid-core/src/rpc_processor/mod.rs +++ b/veilid-core/src/rpc_processor/mod.rs @@ -1470,7 +1470,9 @@ impl RPCProcessor { Ok(v) => v, Err(e) => { // Punish nodes that send direct undecodable crap - address_filter.punish_node_id(sender_node_id); + if matches!(e, RPCError::Protocol(_) | RPCError::InvalidFormat(_)) { + address_filter.punish_node_id(sender_node_id); + } return Ok(NetworkResult::invalid_message(e)); } };