From e1370b78792505fa6a276a29a8e2a0b7d69756a3 Mon Sep 17 00:00:00 2001 From: laalsaas Date: Wed, 5 Apr 2023 10:43:18 +0200 Subject: [PATCH] sss-cli: init at 0.1.1 --- pkgs/tools/security/sss-cli/default.nix | 27 +++++++++++++++++++ .../security/sss-cli/fix-cargo-lock.patch | 21 +++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 3 files changed, 50 insertions(+) create mode 100644 pkgs/tools/security/sss-cli/default.nix create mode 100644 pkgs/tools/security/sss-cli/fix-cargo-lock.patch diff --git a/pkgs/tools/security/sss-cli/default.nix b/pkgs/tools/security/sss-cli/default.nix new file mode 100644 index 000000000000..80daa4a6627e --- /dev/null +++ b/pkgs/tools/security/sss-cli/default.nix @@ -0,0 +1,27 @@ +{ lib +, rustPlatform +, fetchFromGitHub +}: + +rustPlatform.buildRustPackage rec { + pname = "sss-cli"; + version = "0.1.1"; + + src = fetchFromGitHub { + owner = "dsprenkels"; + repo = "sss-cli"; + rev = "v${version}"; + hash = "sha256-9Wht+t48SsWpj1z2yY6P7G+h9StmuqfMdODtyPffhak="; + }; + + cargoPatches = [ ./fix-cargo-lock.patch ]; + + cargoHash = "sha256-nKb0J9ym3ZYC80KemwQwT5vVtQUngYD4/091hAIYAiU="; + + meta = with lib; { + homepage = "https://github.com/dsprenkels/sss-cli"; + description = "Command line program for secret-sharing strings"; + license = licenses.mit; + maintainers = with maintainers; [ laalsaas ]; + }; +} diff --git a/pkgs/tools/security/sss-cli/fix-cargo-lock.patch b/pkgs/tools/security/sss-cli/fix-cargo-lock.patch new file mode 100644 index 000000000000..4af581c4962d --- /dev/null +++ b/pkgs/tools/security/sss-cli/fix-cargo-lock.patch @@ -0,0 +1,21 @@ +diff --git a/Cargo.lock b/Cargo.lock +index a57c5d8..27278d9 100644 +--- a/Cargo.lock ++++ b/Cargo.lock +@@ -1,5 +1,7 @@ + # This file is automatically @generated by Cargo. + # It is not intended for manual editing. ++version = 3 ++ + [[package]] + name = "aho-corasick" + version = "0.7.15" +@@ -253,7 +255,7 @@ dependencies = [ + + [[package]] + name = "shamirsecretsharing-cli" +-version = "0.1.0" ++version = "0.1.1" + dependencies = [ + "atty", + "clap", diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index bbc9d709ada4..de312b368e01 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -12474,6 +12474,8 @@ with pkgs; ssocr = callPackage ../applications/misc/ssocr { }; + sss-cli = callPackage ../tools/security/sss-cli { }; + ssss = callPackage ../tools/security/ssss { }; stabber = callPackage ../misc/stabber { };