mirror of
https://github.com/outbackdingo/firezone.git
synced 2026-01-28 02:18:50 +00:00
For our test-suite, we need to sample a unique, non-overlapping IP for each component that is being simulated (client, gateways and relays). These are sampled from a predefined range. Currently, we only consider the first 100 IPs of this range and pick it from an allocated `Vec`. This isn't ideal for performance and increases the likelihood of two hosts having the same IP. IPv4 and IPv6 addresses can also just be represented as numbers. Instead of sampling a random IP from a list, we can simply sample a random number between the first and last address of the particular IP network to achieve the same effect.
Connlib
Firezone's connectivity library shared by all clients.
Building Connlib
You shouldn't need to build connlib directly; it's typically built as a dependency of one of the other Firezone components. See READMEs in those directories for relevant instructions.