summary refs log tree commit diff
path: root/pkgs/tools/security
diff options
context:
space:
mode:
authorpajowu <git@ca.pajowu.de>2017-04-10 19:53:16 +0200
committerpajowu <git@ca.pajowu.de>2017-04-10 20:06:53 +0200
commit857a3b872c430fd9a2fb09a07146ad0a9af36e07 (patch)
tree9bd3986b79ccb6837fd6efd68ed203252ab5c341 /pkgs/tools/security
parent1bb8a47803ea5015de2fcc3f99fd2323e7de1d91 (diff)
downloadnixlib-857a3b872c430fd9a2fb09a07146ad0a9af36e07.tar
nixlib-857a3b872c430fd9a2fb09a07146ad0a9af36e07.tar.gz
nixlib-857a3b872c430fd9a2fb09a07146ad0a9af36e07.tar.bz2
nixlib-857a3b872c430fd9a2fb09a07146ad0a9af36e07.tar.lz
nixlib-857a3b872c430fd9a2fb09a07146ad0a9af36e07.tar.xz
nixlib-857a3b872c430fd9a2fb09a07146ad0a9af36e07.tar.zst
nixlib-857a3b872c430fd9a2fb09a07146ad0a9af36e07.zip
browserpass: init at 1.0.2
Diffstat (limited to 'pkgs/tools/security')
-rw-r--r--pkgs/tools/security/browserpass/default.nix35
1 files changed, 35 insertions, 0 deletions
diff --git a/pkgs/tools/security/browserpass/default.nix b/pkgs/tools/security/browserpass/default.nix
new file mode 100644
index 000000000000..dee0522115c1
--- /dev/null
+++ b/pkgs/tools/security/browserpass/default.nix
@@ -0,0 +1,35 @@
+{ stdenv, lib, fetchzip }:
+let 
+  userDir = "~/.config/chromium";
+in
+  stdenv.mkDerivation rec {
+    name = "browserpass-${version}";
+
+    version = "1.0.2";
+
+    src = fetchzip {
+      url = "https://github.com/dannyvankooten/browserpass/releases/download/${version}/browserpass-linux64.zip";
+      sha256 = "1fj2siczm472xd1n5i5k08cw94q5gpisfqmvrhhwq7zdjvpcrh8y";
+      stripRoot = false;
+    };
+
+    dontBuild = true;
+
+    installPhase = ''
+      install -D browserpass-linux64 "$out/bin/browserpass"
+
+      host_file="$out/bin/browserpass"
+      sed -i -e "s!%%replace%%!$host_file!" chrome-host.json
+      sed -i -e "s!%%replace%%!$host_file!" firefox-host.json
+
+      install -D chrome-host.json "$out/etc/chrome-host.json"
+      install -D firefox-host.json "$out/etc/firefox-host.json"
+
+    '';
+
+
+    meta = with lib; {
+      maintainers = with maintainers; [ cstrahan ];
+      platforms   = ["x86_64-linux"];
+    };
+  }