From 67a8a00a36c73b72af25d112ac2dc5c97c950a07 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Thu, 12 Mar 2026 18:13:57 +0100 Subject: [PATCH] brutus: init at 1.2.0 Credential testing tool for multiple services https://github.com/praetorian-inc/brutus --- pkgs/by-name/br/brutus/package.nix | 41 ++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 pkgs/by-name/br/brutus/package.nix diff --git a/pkgs/by-name/br/brutus/package.nix b/pkgs/by-name/br/brutus/package.nix new file mode 100644 index 000000000000..a3a63fcd9ee6 --- /dev/null +++ b/pkgs/by-name/br/brutus/package.nix @@ -0,0 +1,41 @@ +{ + lib, + buildGoModule, + fetchFromGitHub, + versionCheckHook, +}: + +buildGoModule (finalAttrs: { + pname = "brutus"; + version = "1.2.0"; + + src = fetchFromGitHub { + owner = "praetorian-inc"; + repo = "brutus"; + tag = "v${finalAttrs.version}"; + hash = "sha256-HsQZqHILko3FTzBH1pJ3HBpfdaOoWH+xPq0l10/CAB8="; + }; + + vendorHash = "sha256-1hP4gitbpm3wFhLu7OJ3gQMVkZKZJEZAKvhfejSOYMI="; + + ldflags = [ + "-s" + "-X=main.Version=${finalAttrs.version}" + "-X=main.BuildTime=1970-01-01T00:00:00Z" + "-X=main.CommitSHA=${finalAttrs.src.rev}" + ]; + + nativeInstallCheckInputs = [ versionCheckHook ]; + + doInstallCheck = true; + + versionCheckProgramArg = [ "--version" ]; + + meta = { + description = "Credential testing tool for multiple services"; + homepage = "https://github.com/praetorian-inc/brutus"; + license = lib.licenses.asl20; + maintainers = with lib.maintainers; [ fab ]; + mainProgram = "brutus"; + }; +})