package mnet

  1. Overview
  2. Docs
An implementation of TCP (Transmission Control Protocol) in OCaml for Miou & Solo5

Install

dune-project
 Dependency

Authors

Maintainers

Sources

mnet-0.0.7.tbz
sha256=efcef0d0452c6b6b5d5a618bff47250fd873d4cd317d0a51ee349c4a5cb84d9a
sha512=5c0d2b5a1967c592138525f6f706457b45833f4f86a98c7cede0128edce4104e227361025bacc4c888bf73499c8438df95d51f990f93515cd4a2ce5f89e01caa

doc/mnet.fragments/Fragments/index.html

Module FragmentsSource

Fragments is a module that implements an IPv4/IPv6 packet reassembly algorithm with a limit on memory consumption (using an LRU) and lifetime.

The first thing to note about IPv4 and IPv6 protocols is that fragmentation is usually quite rare (in the sense that the TCP or QUIC protocol should be able to exchange packets of the correct size). However, there may be cases of fragmentation. A fairly simple example to simulate fragmentation is to ping with a size greater than 1500 bytes (which is the default size for an Ethernet interface).

Sourcemodule SBstr = Slice_bstr
Sourcetype payload =
  1. | Slice of SBstr.t
  2. | String of string

The type of content in an IPv4/IPv6 packet. It should be noted (the happy path) that if the data is a slice, it corresponds (without copying) to the Ethernet frame: this case signals to the user that there has been no fragmentation. Otherwise, the content is a reassembly (which necessarily involves copying) of the packets received.

Sourcemodule Make (Key : Hashtbl.HashedType) : sig ... end