You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Doppelganger protection produces false positives if validator publishes attestation in current epoch N with an inclusion delay/(or duplicate inclusion) in epoch N + 1.
This is due to the fact that liveness of validator is checked based on attestation seen in block attesters cache
There are multiple factors which increase the chance to produce false positives
validator client is restarted towards the end of epoch
increased inclusion delay due to bad network conditions (e.g. on goerli)
inaccurate source, target, or head vote of last attestation?
number of validator keys
This is issue can be fully mitigated by setting next epoch to check to N + 2 at the cost of missing more validator duties.
Expected behavior
Doppelganger protection must not produce false positives.
Steps to reproduce
Enable doppelganger protection by setting --doppelgangerProtectionEnabled and restart validator client near the end of epoch (slot 28-31), it is important to make sure it is still started in the same epoch.
Additional context
Examples of false positives on goerli
Stopped validator client end of epoch 184455 (slot=5902590) and started it in same epoch (slot=5902591)
Based on data from beaconcha.in there has not been an inclusion delay
However, the attestation is included in multiple blocks, first in slot 5902580 which is epoch 184455 but also in slot 5902593 which is epoch 184456. The 2nd inclusion likely caused seenBlockAttesters=true.
This is from a another test run, it is expected for this validator that doppelganger protection detected a false positive as attestation inclusion was delayed to next epoch.
Last signed attestation epoch=184287
Jun-20 15:22:14.842[] debug: Signed attestation slot=5897211, index=41, head=0x77443f93430711ab246de346bccbbf8d230089b79e76a399ef7c173878ac6673, validatorIndex=46101
Registered validator on epoch=184287
Jun-20 15:23:06.515[] info: Registered validator for doppelganger remainingEpochs=1, pubkeyHex=0x8186135e9b5cbba537b93a7a79a615e55b841e61abda623f28de0bcd893a7cf8285e808f48376fc6f97f600e57d65af
Last attestation epoch=184287, slot=5897211, inclusion_slot=5897222 (epoch=184288)
The suggested solution to set the next epoch to check to N + 2 won't be required to prevent false positives. The only way to reproduce this issue previously was by restarting the validator client close to the end of the current epoch but in this case we now skip doppelganger protection.
Describe the bug
Doppelganger protection produces false positives if validator publishes attestation in current epoch N with an inclusion delay/(or duplicate inclusion) in epoch N + 1.
This is due to the fact that liveness of validator is checked based on attestation seen in block attesters cache
lodestar/packages/beacon-node/src/chain/chain.ts
Line 315 in 61c838b
which is set when importing block
lodestar/packages/beacon-node/src/chain/blocks/importBlock.ts
Line 137 in 61c838b
This is expected to happen because the doppelganger service set epoch N + 1 as the next epoch to check
lodestar/packages/validator/src/services/doppelgangerService.ts
Line 69 in 61c838b
There are multiple factors which increase the chance to produce false positives
This is issue can be fully mitigated by setting next epoch to check to N + 2 at the cost of missing more validator duties.
Expected behavior
Doppelganger protection must not produce false positives.
Steps to reproduce
Enable doppelganger protection by setting
--doppelgangerProtectionEnabled
and restart validator client near the end of epoch (slot 28-31), it is important to make sure it is still started in the same epoch.Additional context
Examples of false positives on goerli
Stopped validator client end of epoch 184455 (slot=5902590) and started it in same epoch (slot=5902591)
Started doppelganger protection
Registration of validators
Liveness response that triggered detection
Doppelganger error
Validator 461381
The attestation of epoch N was included multiple times in epoch N and N + 1 causing the false positive.
Last signed attestation
Registration of validator
validatorSeenAtEpoch
response on beacon nodeBased on data from beaconcha.in there has not been an inclusion delay
However, the attestation is included in multiple blocks, first in slot 5902580 which is epoch 184455 but also in slot 5902593 which is epoch 184456. The 2nd inclusion likely caused
seenBlockAttesters=true
.Validator 461016
This is from a another test run, it is expected for this validator that doppelganger protection detected a false positive as attestation inclusion was delayed to next epoch.
Last signed attestation epoch=184287
Registered validator on epoch=184287
Last attestation epoch=184287, slot=5897211, inclusion_slot=5897222 (epoch=184288)
More examples can be found here: doppelganger-false-positives.md
Operating system
Linux
Lodestar version or commit hash
unstable (f677434)
The text was updated successfully, but these errors were encountered: