Skip to content

24

Choose a tag to compare

@pg83 pg83 released this 14 Sep 17:14
· 80 commits to master since this release

Graph vertices are 32-bit ids: the owner's registry index in the high byte and a counter below it. Counter 0 is the node's mesh-IP vertex, registry endpoints take the following counters in registry order, and runtime vertices (implicit listeners, one source per connection attempt) are allocated from 1024. Descriptions travel only in the owner's graph record; packets carry a 4-byte source id and routing works in ids alone.

Outgoing UDP leaves the node's listener socket on its interface, so a forwarded listener's traffic uses its forwarded mapping. Every interface address without a configured UDP listener gets an implicit socket advertised like a listener. Nodes report next to each incoming UDP link the wire address the packets actually arrive from, and a node dialing a private listener off its own networks sends to that observed NAT mapping, so two nodes behind cone NAT connect directly through any common peer without STUN or coordination messages.

The nonce is no longer sent: packet ids come from one counter per node started from the clock, and the id word doubles as the nonce. The header is 9 bytes, with the packet kind in the low bits of the id word and the sender index in one byte; the inner data byte holds hop count and cursor.

Nodes on releases before 24 cannot exchange any packets with this release; update peers together.