Skip to content

Internet Support

Jeremy Soller requested to merge dns into master

Problem:

Redox was horrendously disconnected

Solution:

Improve networking support, add primitives for accessing the internet

One can use this by running the redox_online.sh test script. If it shows this file, it has worked: http://static.redox-os.org/test.md

Changes introduced by this pull request:

  • Added a network configuration scheme, netcfg: with files like dns, ip, ip_router, ip_subnet, and mac
  • Increase kernel networking buffer sizes to 64KB
  • Improved the kernel networking stack to fix errors in UDP, and IP
  • Add routing by checking for addresses outside of network, and using configured router
  • Add a option to the kernel blocking construct WaitCondition to wait for a duration, which will be used to implement timeouts
  • Add a netutils repository where network-related utilities will be placed
  • Added dhcp client, dhcpd, that can set the IP address, router, subnet mask, and DNS servers when running in VirtualBox or QEMU (and on real hardware if everything is perfect)
  • Added a dns client, dnsd, that can query a hostname and return associated IP addresses
  • Fixed the wget command so that it can now

Drawbacks:

Networking could potentially cause deadlocks, if expected packets are not received

TODOs:

  • Allow timeouts so that deadlocks are not severe
  • Improve the TCP scheme so that multiple segments can be joined in the correct order
  • Run DNS as a service, in the background, and use that to implement lookup_host

Fixes:

This allows Redox to access the internet

Merge request reports