sdk
sdk copied to clipboard
Allow TCP stack to be initialized with static configuration and DHCP
Currently we support a mixed mode, where we always use DHCP and a routable static IP address as the fallback. This makes it rather complicated to reason about the state of the network interface and stack (see discussion in https://codereview.chromium.org/2024143003/).
Instead, the network library should support two ways to initialize the stack:
- provide a static IP. This IP is always assigned to the network interface, even if there is no physical connection.
- DHCP. No IP address is assigned to the network interface until a valid DHCP configuration has been received and after the lease has expired.