CONNECTIVITY 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. This document describes how nodes in a VPN find and connect to eachother and
  2. maintain a stable network.
  3. Copyright 2001-2006 Guus Sliepen <guus@tinc-vpn.org>
  4. Permission is granted to make and distribute verbatim copies of
  5. this documentation provided the copyright notice and this
  6. permission notice are preserved on all copies.
  7. Permission is granted to copy and distribute modified versions of
  8. this documentation under the conditions for verbatim copying,
  9. provided that the entire resulting derived work is distributed
  10. under the terms of a permission notice identical to this one.
  11. 1. Synchronisation
  12. ==================
  13. Each tinc daemon has zero or more connections to other tinc daemons. It will
  14. try to keep its own information synchronised with the other tinc daemons. If
  15. one of its peers sends information, the tinc daemon will check if it is new
  16. information. If so, it will update its own information and forward the new
  17. information to all the other peers.
  18. This scheme will make sure that after a short amount of time all tinc daemons
  19. share the same information. It will also almost completely prevent information
  20. from looping, because "new" information that is already known is ignored and
  21. not forwarded any further. However, since information can also be deleted
  22. there's the possibility of a looping sequence of add/delete messages. This is
  23. resolved by additionaly adding a unique identifier to each broadcasted message.
  24. Messages are dropped if the same message with that identifier has already been
  25. seen.
  26. 2. Routing
  27. ==========
  28. Every node tells its peers to which other peers it is connected. This way
  29. every node will eventually know every connection every node has on the VPN.
  30. Each node will use graph algorithms to determine if other nodes are reachable or not and
  31. what the best route is to other nodes.
  32. Because all nodes share the same information, using a deterministic algorithm
  33. each node will calculate the same minimum spanning tree for the entire VPN.
  34. The MST will be used to send broadcast VPN packets.