package tcpip

  1. Overview
  2. No Docs
OCaml TCP/IP networking stack, used in MirageOS

Install

Dune Dependency

Authors

Maintainers

Sources

tcpip-9.0.1.tbz
sha256=fac07ce986811cf5e3d71373d92b631cc30fbef548d6da21b0917212dcf90b03
sha512=01de13f560d58b1524c39619e4e4cb6ebbf069155eb43d0f264aa12b00e0cc8c39792719e3ca46585dd596b692b8e1e3f8c132f005ed9e2d77747c0c158bf4d9

doc/tcpip.ipv4/Static_ipv4/Make/argument-2-A/index.html

Parameter Make.A

type t

The type representing the internal state of the ARP layer.

val disconnect : t -> unit Lwt.t

Disconnect from the ARP layer. While this might take some time to complete, it can never result in an error.

type error = private [>
  1. | `Timeout
]

The type for ARP errors.

val pp_error : error Fmt.t

pp_error is the pretty-printer for errors.

val pp : t Fmt.t

Prettyprint cache contents

val get_ips : t -> Ipaddr.V4.t list

get_ips arp gets the bound IP address list in the arp value.

val set_ips : t -> Ipaddr.V4.t list -> unit Lwt.t

set_ips arp sets the bound IP address list, which will transmit a GARP packet also.

val remove_ip : t -> Ipaddr.V4.t -> unit Lwt.t

remove_ip arp ip removes ip to the bound IP address list in the arp value, which will transmit a GARP packet for any remaining IPs in the bound IP address list after the removal.

val add_ip : t -> Ipaddr.V4.t -> unit Lwt.t

add_ip arp ip adds ip to the bound IP address list in the arp value, which will transmit a GARP packet also.

val query : t -> Ipaddr.V4.t -> (Macaddr.t, error) result Lwt.t

query arp ip queries the cache in arp for an ARP entry corresponding to ip, which may result in the sender sleeping waiting for a response.

val input : t -> Cstruct.t -> unit Lwt.t

input arp frame will handle an ARP frame. If it is a response, it will update its cache, otherwise will try to satisfy the request.

OCaml

Innovation. Community. Security.