1{
2 lib,
3 fetchurl,
4 buildDunePackage,
5 domain-name,
6 fmt,
7 logs,
8 kdf,
9 mirage-crypto,
10 mirage-crypto-ec,
11 mirage-crypto-pk,
12 mirage-crypto-rng,
13 x509,
14 ipaddr,
15 alcotest,
16 ounit2,
17}:
18
19buildDunePackage rec {
20 pname = "tls";
21 version = "2.0.1";
22
23 src = fetchurl {
24 url = "https://github.com/mirleft/ocaml-tls/releases/download/v${version}/tls-${version}.tbz";
25 hash = "sha256-a6uNo61SjT8xLXtO4h2kxZw0qRrj5c9CNHFauaGCDq0=";
26 };
27
28 minimalOCamlVersion = "4.08";
29
30 propagatedBuildInputs = [
31 domain-name
32 fmt
33 logs
34 kdf
35 mirage-crypto
36 mirage-crypto-ec
37 mirage-crypto-pk
38 mirage-crypto-rng
39 x509
40 ipaddr
41 ];
42
43 doCheck = true;
44 checkInputs = [
45 alcotest
46 ounit2
47 ];
48
49 meta = with lib; {
50 homepage = "https://github.com/mirleft/ocaml-tls";
51 description = "TLS in pure OCaml";
52 license = licenses.bsd2;
53 maintainers = with maintainers; [ sternenseemann ];
54 };
55}