package tls

  1. Overview
  2. Docs
Transport Layer Security purely in OCaml

Install

Dune Dependency

Authors

Maintainers

Sources

tls-v0.15.2.tbz
sha256=b76371757249bbeabb12c333de4ea2a09c095767bdbbc83322538c0da1fc1e36
sha512=e6e089a853848e82647bc3f6ecaa3a95cdb559e50b7ad9d06064c1fd0c931b0e942ff0877c8066ec79b6b42a29512449ba1a5c6de1f1502cdbfc3397546f417c

doc/tls.lwt/Tls_lwt/index.html

Module Tls_lwtSource

Effectful operations using Lwt for pure TLS.

The pure TLS is state and buffer in, state and buffer out. This module uses Lwt for communication over the network.

This module implements a high-level API and a low-level API (in Unix). Most applications should use the high-level API described below.

Sourceexception Tls_alert of Tls.Packet.alert_type

Tls_alert exception received from the other endpoint

Sourceexception Tls_failure of Tls.Engine.failure

Tls_failure exception while processing incoming data

Sourcemodule Unix : sig ... end

Low-level API

High-level API

accept_ext server fd is (ic, oc), sockaddr, the input and output channel from an accepted connection on the given fd, after upgrading to TLS using the server configuration.

accept own_cert fd is (ic, oc), sockaddr, the input and output channel from the accepted connection on fd, using the default configuration with the given own_cert.

Sourceval connect_ext : Tls.Config.client -> (string * int) -> (ic * oc) Lwt.t

connect_ext client (host, port) is ic, oc, the input and output channel of a TLS connection to host on port using the client configuration.

Sourceval connect : X509.Authenticator.t -> (string * int) -> (ic * oc) Lwt.t

connect authenticator (host, port) is ic, oc, the input and output channel of a TLS connection to host on port using the default configuration and the authenticator.

Sourceval of_t : ?close:(unit -> unit Lwt.t) -> Unix.t -> ic * oc

of_t t is ic, oc, the input and output channel. close defaults to !Unix.close.

OCaml

Innovation. Community. Security.