Skip to content

Study time synchronization issues #1024

Open
@TheQuantumPhysicist

Description

@TheQuantumPhysicist

PR #1017 is an attempt at fixing time synchronization issues between nodes. However, this is not enough. Here are a few issues:

  • Nodes can have clocks that drift over time
  • A block far in the future shouldn't always result in banning the peer, but should instead try again later. Currently an invalid block (due to being a little in the future, more than the limit) will make the block invalid, but then will result in subsequent blocks to have no parent, and hence being orphan, resulting in banning the peer.
  • There has to be an error with zero ban score for blocks not too far in the future (a few minutes) and a ban on blocks way too far in the future.
  • The strategy implemented in Clock sync fixes #1017 is problematic because it ruins the usage of mocked time. Waiting isn't really the best wait to do this. The handle_header_list check that delays time should go eventually.

Metadata

Metadata

Assignees

Labels

ConsensusConsensus related issuesbugSomething isn't workingp2pp2p related issuessecuritySecurity-related issues

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions