package tls

  1. Overview
  2. Docs
include module type of struct include X509.Private_key end
val generate : ?seed:Cstruct.t -> ?bits:int -> X509.Key_type.t -> t
val of_cstruct : Cstruct.t -> X509.Key_type.t -> (t, [> `Msg of string ]) Stdlib.result
val of_string : ?seed_or_data:[ `Data | `Seed ] -> ?bits:int -> X509.Key_type.t -> string -> (t, [> `Msg of string ]) Stdlib.result
val key_type : t -> X509.Key_type.t
val public : t -> X509.Public_key.t
val sign : Mirage_crypto.Hash.hash -> ?scheme:X509.Key_type.signature_scheme -> t -> [ `Digest of Cstruct.t | `Message of Cstruct.t ] -> (Cstruct.t, [> `Msg of string ]) Stdlib.result
val decode_der : Cstruct.t -> (t, [> `Msg of string ]) Stdlib.result
val encode_der : t -> Cstruct.t
val decode_pem : Cstruct.t -> (t, [> `Msg of string ]) Stdlib.result
val encode_pem : t -> Cstruct.t
val sexp_of_t : 'a -> Sexplib.Sexp.t
OCaml

Innovation. Community. Security.