Module dhcpv4::server

source ·

Structs§

  • This struct is used to hold the error returned by the server’s DataStore manipulation methods. We manually implement PartialEq so this struct could be included in the ServerError enum, which are asserted for equality in tests.
  • A record of a DHCP client’s configuration settings.
  • Parameters needed in order to build a DHCPOFFER.
  • A minimal DHCP server.

Enums§

  • The destinations to which a response can be targeted. A Broadcast will be targeted to the IPv4 Broadcast address. A Unicast will be targeted to its Ipv4Addr associated value. If a MacAddr is supplied, the target may not yet have the Ipv4Addr assigned, so the response should be manually directed to the MacAddr, typically by updating the ARP cache.
  • This enumerates the actions a DHCP server can take in response to a received client message. A SendResponse(Message, Ipv4Addr) indicates that a Message needs to be delivered back to the client. The server may optionally send a destination Ipv4Addr (if the protocol warrants it) to direct the response Message to. The other two variants indicate a successful processing of a client Decline or Release. Implements PartialEq for test assertions.
  • A wrapper around the error types which can be returned by DHCP Server in response to client requests. Implements PartialEq for test assertions.

Constants§

  • The default string used by the Server to identify itself to the Stash service.

Traits§

Functions§

  • Builds a DHCPOFFER in response to the given DHCPDISCOVER using the provided offer_options and options_repo.
  • Given the DHCP options set by the client, retrieves the values of the DHCP options requested by the client.
  • Helper for constructing a repo of DhcpOptions.

Type Aliases§