This page presents a list of the components involved in re6st (node and registry).
See P-RE6ST.Re6st.Control.Flow.Summary to get a summary of the control flow of re6st.
Re6st Node
Registry client (HTTP / HTTPS)
Makes RPC (Remote Procedure Calls) to registry
At startup:
- Request token, certificate, certificate authority Get bootstrap peer Get country Get parameters (network, OpenVPN diffie hellman)
- When certificate will expire soon: renew certificate
If network parameters change:
HTTP / HTTPS because initally nodes don't have IPv6 and only know the registry URL
Node communication (through re6st, port 326)
- Initial hello handshake, protocol exchange
- Ask peer's openVPN server address
- Ask peer to kill tunnel
Tunnel management
- Create new openVPN tunnels
- Destroy tunnels with worst score
- Get tunnel scores by querying babel
OpenVPN
- OpenVPN client processes: connect to a remote openVPN server address (IP, port, protocol)
- OpenVPN server processes: accept connections from openVPN clients
Cache
Cache stores results from registry RPC, and connection attempts:
- cache.db
- Store peer OpenVPN addresses and country
- Store network configuration
- volatile
- Store number of openVPN connection attempts to each peer address
Routing
Babeld is given a list of interfaces, and it will:
- discover the other re6st nodes through these interfaces
- compute distance to each re6st node
- add routes in the kernel for each node
- add default gateway if
--default
is enabled
Registry
HTTP Server
Answer RPC from re6st nodes
Database
- Store network configuration
- Store node certificates
- Store tokens