specifications

Specification and standard documents
git clone git://git.finwo.net/misc/specifications
Log | Files | Refs | README | LICENSE

0005-mesh-routing.txt (2738B)


      1 idea sources:
      2   cjdns
      3   mainline-dht
      4 
      5 aims to replace wide-area-networks
      6 
      7 each node has interface count
      8 node's address width = interface count + 1 fitting binary number
      9 node with 8 interfaces has an address width of 4 bits
     10   0     = invalid
     11   1     = self
     12   2,..9 = interfaces
     13 
     14 
     15 routing label usage:
     16   "interface to route to" is MSB (first bits on wire), to forward at "wirespeed"
     17   when forwarding, the "hop" adds it's receiving port in reverse to the LSB while removing it's interface from the MSB
     18   to respond, reverse the whole routing label to reverse the path
     19 
     20   Assuming 32-bit routing labels, sending a message from Alice to Charlie via Bob, the label would look as follows entring alice's routing core
     21     Entering Alice's routing core:
     22       0110 110000 000001 0000000000000000
     23       \--/                                   Alice(6) -> Bob(123)
     24            \----/                            Bob(48) -> Charlie(33)
     25                   \----/                     Charlie(1) "self"
     26                          \--------------/    Empty space
     27     Received by Bob on interface 123
     28       110000 000001 0000000000000000 1000
     29       \----/                                 Bob(48) -> Charlie(33)
     30              \----/                          Charlie(1) "self"
     31                                      \--/    Alice(1) reversed "self"
     32     Received by Charlie on interface 33
     33       000001 000000000000000 1000 1101111
     34       \----/                                Charlie(1) "self"
     35                               \--/          Alice(1) reversed "self"
     36                                    \----/   Bob(123) reversed
     37     Charlie's core registers this as (flipped) return path
     38       000000000000000 1000 1101111 100001
     39                       \--/                  Alice(1) reversed "self"
     40                            \-----/          Bob(123) reversed
     41                                    \----/   Charlie(33) reversed
     42 
     43 
     44 Node identifiers: see SD0004 (draft)
     45 
     46 Path discovery:
     47   Broadcast every N seconds presence on network (B.A.T.M.A.N. protocol)? -> too much data in large networks
     48   Broadcast "who has node X"? -> might work, still a lot of meta in large networks, includes "fastest path" detection
     49   Dijkstra's path finding, adding discovered neighbours to the "unvisited" list
     50     Harder, will take longer, but removes overhead on further parts of the network
     51     All nodes must track RTT and IDs for all their neighbours
     52     Path sharing (Charlie alreay knows a path to Fred) might speed this up but will not be the ideal path
     53 
     54 Hard problem to solve:
     55   node identifiers (look at asymmetric-diffie-hellman?)
     56   native encryption
     57   shortest path to node with ID X
     58   service discovery
     59     simply searching network for service is slow AF
     60   named alt-net gateways