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 theServerError
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. AUnicast
will be targeted to itsIpv4Addr
associated value. If aMacAddr
is supplied, the target may not yet have theIpv4Addr
assigned, so the response should be manually directed to theMacAddr
, 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 aMessage
needs to be delivered back to the client. The server may optionally send a destinationIpv4Addr
(if the protocol warrants it) to direct the responseMessage
to. The other two variants indicate a successful processing of a clientDecline
orRelease
. ImplementsPartialEq
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§
- An interface for storing and loading DHCP server data.
- The ability to dispatch fuchsia.net.dhcp.Server protocol requests and return a value.
Functions§
- Builds a DHCPOFFER in response to the given DHCPDISCOVER using the provided
offer_options
andoptions_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
DhcpOption
s.
Type Aliases§
- A mapping of clients to their lease records.