Module Dhcp_ipv4.Make

Parameters

module R : Mirage_random.S
module C : Mirage_clock.MCLOCK
module Time : Mirage_time.S
module Network : Mirage_net.S
module E : Ethernet.S
module Arp : Arp.S

Signature

include Tcpip.Ip.S with type ipaddr = Ipaddr.V4.t
type nonrec error = private [>
| Tcpip.Ip.error
]
val pp_error : error Fmt.t
type ipaddr = Ipaddr.V4.t
val pp_ipaddr : ipaddr Fmt.t
type t
val disconnect : t -> unit Lwt.t
type callback = src:ipaddr -> dst:ipaddr -> Cstruct.t -> unit Lwt.t
val input : t -> tcp:callback -> udp:callback -> default:(proto:int -> callback) -> Cstruct.t -> unit Lwt.t
val write : t -> ?fragment:bool -> ?ttl:int -> ?src:ipaddr -> ipaddr -> Tcpip.Ip.proto -> ?size:int -> (Cstruct.t -> int) -> Cstruct.t list -> (unit, error) Stdlib.result Lwt.t
val pseudoheader : t -> ?src:ipaddr -> ipaddr -> Tcpip.Ip.proto -> int -> Cstruct.t
val src : t -> dst:ipaddr -> ipaddr
val get_ip : t -> ipaddr list
val mtu : t -> dst:ipaddr -> int
val connect : Network.t -> E.t -> Arp.t -> t Lwt.t

Connect to an ipv4 device using information from a DHCP lease.