This commit was created by a combination of scripts and tools: - an ast-grep script to prefix things in meta with `lib.`, - a modified nixf-diagnose / nixf combination to remove unused `with lib;`, and - regular nixfmt. Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
48 lines
1.0 KiB
Nix
48 lines
1.0 KiB
Nix
{
|
|
lib,
|
|
stdenv,
|
|
fetchurl,
|
|
perl,
|
|
}:
|
|
|
|
stdenv.mkDerivation (finalAttrs: {
|
|
pname = "apache-users";
|
|
version = "2.1";
|
|
|
|
src = fetchurl {
|
|
url = "https://labs.portcullis.co.uk/download/apache_users-${finalAttrs.version}.tar.gz";
|
|
hash = "sha256-rylW4F8Si6KKYxaxEJlVFnbLqfqS6ytMPfHpc8MgriA=";
|
|
};
|
|
|
|
# Allow optional arguments where defaults are provided
|
|
patches = [ ./optional-args.patch ];
|
|
|
|
postPatch = ''
|
|
substituteAllInPlace apache${finalAttrs.version}.pl
|
|
'';
|
|
|
|
buildInputs = [
|
|
(perl.withPackages (p: [
|
|
p.ParallelForkManager
|
|
p.LWP
|
|
]))
|
|
];
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
|
|
install -D apache${finalAttrs.version}.pl $out/bin/apache-users
|
|
install -Dm444 names $out/share/apache-users/names
|
|
|
|
runHook postInstall
|
|
'';
|
|
|
|
meta = {
|
|
description = "Username Enumeration through Apache UserDir";
|
|
homepage = "https://labs.portcullis.co.uk/downloads/";
|
|
license = lib.licenses.gpl2Plus;
|
|
maintainers = with lib.maintainers; [ emilytrau ];
|
|
mainProgram = "apache-users";
|
|
};
|
|
})
|