skip bad proof of possession deposits
This commit is contained in:
parent
fbb70e91eb
commit
b2a3ee4bbc
|
@ -1235,7 +1235,7 @@ def process_deposit(state: BeaconState, deposit: Deposit) -> None:
|
||||||
"""
|
"""
|
||||||
deposit_input = deposit.deposit_data.deposit_input
|
deposit_input = deposit.deposit_data.deposit_input
|
||||||
|
|
||||||
assert bls_verify(
|
proof_is_valid = bls_verify(
|
||||||
pubkey=deposit_input.pubkey,
|
pubkey=deposit_input.pubkey,
|
||||||
message_hash=signed_root(deposit_input, "proof_of_possession"),
|
message_hash=signed_root(deposit_input, "proof_of_possession"),
|
||||||
signature=deposit_input.proof_of_possession,
|
signature=deposit_input.proof_of_possession,
|
||||||
|
@ -1246,6 +1246,9 @@ def process_deposit(state: BeaconState, deposit: Deposit) -> None:
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
if not proof_is_valid:
|
||||||
|
return
|
||||||
|
|
||||||
validator_pubkeys = [v.pubkey for v in state.validator_registry]
|
validator_pubkeys = [v.pubkey for v in state.validator_registry]
|
||||||
pubkey = deposit_input.pubkey
|
pubkey = deposit_input.pubkey
|
||||||
amount = deposit.deposit_data.amount
|
amount = deposit.deposit_data.amount
|
||||||
|
|
Loading…
Reference in New Issue