mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-02 20:03:16 +00:00
573ee6b58c
https://github.com/emikulic/darkhttpd/releases/tag/v1.14 Fixes CVE-2020-25691.
35 lines
791 B
Nix
35 lines
791 B
Nix
{ lib
|
|
, stdenv
|
|
, fetchFromGitHub
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "darkhttpd";
|
|
version = "1.14";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "emikulic";
|
|
repo = pname;
|
|
rev = "v${version}";
|
|
sha256 = "sha256-J/tjT3Rfhk5++jbmLBrZu9O4GgTBqeycuz82NliCBxw=";
|
|
};
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
install -Dm555 -t $out/bin darkhttpd
|
|
install -Dm444 -t $out/share/doc/${pname} README.md
|
|
head -n 18 darkhttpd.c > $out/share/doc/${pname}/LICENSE
|
|
runHook postInstall
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "Small and secure static webserver";
|
|
homepage = "https://unix4lyfe.org/darkhttpd/";
|
|
license = licenses.bsd3;
|
|
maintainers = with maintainers; [ bobvanderlinden ];
|
|
platforms = platforms.all;
|
|
};
|
|
}
|