package capnp-rpc-lwt

  1. Overview
  2. Docs
type t

The digest of a public key, used to recognise a vat. This appears in URIs as e.g. 'capnp://sha256:1234@host/'.

val insecure : t

A special value indicating no authentication should be performed.

val from_uri : Uri.t -> (t, [> `Msg of string ]) Pervasives.result

from_uri t is the parsed digest information in t.

val add_to_uri : t -> Uri.t -> Uri.t

add_to_uri t uri is uri with the user and password fields set to the correct values for t. Note that although we use the "password" field, this is not secret.

val authenticator : t -> X509_lwt.authenticator option

authenticator t is an authenticator that checks that the peer's public key matches t. Returns None if t is insecure. Note: it currently also requires the DN field to be "capnp".

val of_certificate : X509.t -> t

of_certificate cert is a digest of cert's public key.

val equal : t -> t -> bool
val pp : t Fmt.t
module Map : Asetmap.Map.S with type key = t
OCaml

Innovation. Community. Security.