2019-09-17 12:24:04 +00:00
|
|
|
{ stdenv, fetchFromGitHub, rustPlatform, darwin }:
|
2019-04-12 09:25:26 +00:00
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "boringtun";
|
2019-09-28 04:00:00 +00:00
|
|
|
version = "0.2.0";
|
2019-04-12 09:25:26 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "cloudflare";
|
|
|
|
repo = pname;
|
2019-09-28 04:00:00 +00:00
|
|
|
rev = "v${version}";
|
|
|
|
sha256 = "1mijy51hd8c4as9g4ivpfxismc9m5m3nhibfvclh3wrlcmp1ha9c";
|
2019-04-12 09:25:26 +00:00
|
|
|
};
|
|
|
|
|
2020-02-26 03:18:50 +00:00
|
|
|
cargoSha256 = "1kbbkbrfjff4yicwanydmcjr2av6s6wrsgafpvbh255vvkd7mr6x";
|
2019-04-12 09:25:26 +00:00
|
|
|
|
2019-09-17 12:24:04 +00:00
|
|
|
buildInputs = stdenv.lib.optional stdenv.isDarwin darwin.apple_sdk.frameworks.Security;
|
|
|
|
|
2019-04-12 09:25:26 +00:00
|
|
|
# Testing this project requires sudo, Docker and network access, etc.
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Userspace WireGuard® implementation in Rust";
|
|
|
|
homepage = https://github.com/cloudflare/boringtun;
|
|
|
|
license = licenses.bsd3;
|
2019-09-28 04:01:00 +00:00
|
|
|
maintainers = with maintainers; [ xrelkd marsam ];
|
2019-04-12 09:25:26 +00:00
|
|
|
platforms = platforms.linux ++ platforms.darwin;
|
|
|
|
};
|
|
|
|
}
|