Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at netboot-syslinux-multiplatform 40 lines 1.2 kB view raw
1{ lib, stdenv, perl, perlPackages, fetchurl }: 2 3stdenv.mkDerivation rec { 4 pname = "davtest"; 5 version = "1.0"; 6 7 src = fetchurl { 8 url = "https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/davtest/davtest-${version}.tar.bz2"; 9 sha256 = "0kigcgv1bbnan9yr5481s4b9islmvzl2arpg1ig1i39sxrna06y7"; 10 }; 11 12 postPatch = '' 13 substituteInPlace davtest.pl \ 14 --replace "backdoors/" "$out/share/davtest/backdoors/" \ 15 --replace "tests/" "$out/share/davtest/tests/" 16 ''; 17 18 buildInputs = [ 19 (perl.withPackages (p: with p; [ HTTPDAV ])) 20 ]; 21 22 installPhase = '' 23 runHook preInstall 24 25 install -Dm755 davtest.pl $out/bin/davtest.pl 26 mkdir -p $out/share/davtest 27 cp -r backdoors/ tests/ $out/share/davtest/ 28 29 runHook postInstall 30 ''; 31 32 meta = with lib; { 33 description = "Tests WebDAV servers by uploading test files, and then optionally testing for command execution or other actions directly on the target"; 34 homepage = "https://code.google.com/p/davtest/"; 35 mainProgram = "davtest.pl"; 36 license = licenses.gpl3Only; 37 maintainers = with maintainers; [ emilytrau ]; 38 platforms = platforms.unix; 39 }; 40}