Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
R re6stnet
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 2
    • Issues 2
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge requests 4
    • Merge requests 4
  • Operations
    • Operations
    • Incidents
  • Analytics
    • Analytics
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • nexedi
  • re6stnet
  • Merge requests
  • !27

Closed
Created Feb 10, 2021 by Joanne Hugé@jhugeMaintainer
  • Report abuse
Report abuse

WIP: Add version protocol in hello handshakes and add country in addresses

  • Overview 5
  • Commits 4
  • Changes 6

We recently discovered that the ip geolocation database present for each re6st node doesn't match the correct country for some IP's. This implies problems when using the --same-country option. ​ To solve this, the country associated to an IP can be added to the (ip, port, protocol) address tuple which nodes exchange between themselves in order to allow tunnel creations. We can then add a --country option allowing nodes to advertise the country they want, thus bypassing our current ip geolocation methods. ​ However, we need to ensure nodes who won't immediately update will still be able to make tunnels and communicate with other re6st nodes. In order to ease compatibility between different re6st inter-node or node-registry protocols, nodes and registries should know the protocol of the peer they are communicating with as early as possible. For inter-node communication, I added the protocol in seqno 1 and seqno 2 (since seqno 0 can be skipped), and for node-registry communication, I added the protocol as an optional argument to the hello RPC. ​ This means a handhsake initiated from an old node to a new node will fail. To ease tunnel creation, I prevent the registry from sending countries to old nodes during bootstrapping. One drawback is that unwanted tunnels which break the --same-country rule may be created during bootstrapping. ​ /cc @tomo @jm

Assignee
Assign to
Reviewer
Request review from
None
Milestone
None
Assign milestone
Time tracking
Source branch: protocol
GitLab Nexedi Edition | About GitLab | About Nexedi | 沪ICP备2021021310号-2 | 沪ICP备2021021310号-7