17 src = fetchFromGitHub {
19 repo = "certificates";
21 sha256 = "sha256-iWThTFH36NNjO9Acx5QyxJrUzKFl7vD/seWF/Rz05CU=";
24 vendorSha256 = "sha256-AcjICy991WPQyXp/9j6rgedg4FTYXilH7O4dy8gGYq8=";
26 ldflags = [ "-buildid=" ];
28 nativeBuildInputs = lib.optionals hsmSupport [ pkg-config ];
31 lib.optionals (hsmSupport && stdenv.isLinux) [ pcsclite ]
32 ++ lib.optionals (hsmSupport && stdenv.isDarwin) [ PCSC ];
35 substituteInPlace systemd/step-ca.service --replace "/bin/kill" "${coreutils}/bin/kill"
39 ${lib.optionalString (!hsmSupport) "export CGO_ENABLED=0"}
43 install -Dm444 -t $out/lib/systemd/system systemd/step-ca.service
46 # Tests start http servers which need to bind to local addresses:
47 # panic: httptest: failed to listen on a port: listen tcp6 [::1]:0: bind: operation not permitted
48 __darwinAllowLocalNetworking = true;
50 passthru.tests.step-ca = nixosTests.step-ca;
53 description = "A private certificate authority (X.509 & SSH) & ACME server for secure automated certificate management, so you can use TLS everywhere & SSO for SSH";
54 homepage = "https://smallstep.com/certificates/";
55 license = licenses.asl20;
56 maintainers = with maintainers; [ cmcdragonkai mohe2015 techknowlogick ];