Update gossip_methods.rs
This commit is contained in:
parent
05c1291d8a
commit
1319683736
@ -1215,9 +1215,20 @@ impl<T: BeaconChainTypes> Worker<T> {
|
|||||||
"peer" => %peer_id,
|
"peer" => %peer_id,
|
||||||
"error" => ?e
|
"error" => ?e
|
||||||
);
|
);
|
||||||
self.propagate_validation_result(message_id, peer_id, MessageAcceptance::Reject);
|
// We ignore pre-capella messages without penalizing peers.
|
||||||
|
if matches!(e, BeaconChainError::BlsToExecutionChangeBadFork(_)) {
|
||||||
|
self.propagate_validation_result(
|
||||||
|
message_id,
|
||||||
|
peer_id,
|
||||||
|
MessageAcceptance::Ignore,
|
||||||
|
);
|
||||||
|
} else {
|
||||||
// We penalize the peer slightly to prevent overuse of invalids.
|
// We penalize the peer slightly to prevent overuse of invalids.
|
||||||
if !matches!(e, BeaconChainError::BlsToExecutionChangeBadFork(_)) {
|
self.propagate_validation_result(
|
||||||
|
message_id,
|
||||||
|
peer_id,
|
||||||
|
MessageAcceptance::Reject,
|
||||||
|
);
|
||||||
self.gossip_penalize_peer(
|
self.gossip_penalize_peer(
|
||||||
peer_id,
|
peer_id,
|
||||||
PeerAction::HighToleranceError,
|
PeerAction::HighToleranceError,
|
||||||
|
Loading…
Reference in New Issue
Block a user