diff options
author | Alex Griffin <a@ajgrf.com> | 2020-01-10 13:37:30 -0600 |
---|---|---|
committer | Alex Griffin <a@ajgrf.com> | 2020-03-12 21:12:05 -0500 |
commit | 63299f2840edcd5d942b3433ffb205fcc1fb6eb4 (patch) | |
tree | 30d9f67a3307f6bcbec8adf14cbff5503a4f47d4 /gnu/packages/password-utils.scm | |
parent | 42c6503d3777cf1b1c3749efe847dc8025a34b94 (diff) | |
download | guix-63299f2840edcd5d942b3433ffb205fcc1fb6eb4.tar guix-63299f2840edcd5d942b3433ffb205fcc1fb6eb4.tar.gz |
gnu: Add browserpass-native.
* gnu/packages/password-utils.scm (browserpass-native): New variable.
Diffstat (limited to 'gnu/packages/password-utils.scm')
-rw-r--r-- | gnu/packages/password-utils.scm | 80 |
1 files changed, 79 insertions, 1 deletions
diff --git a/gnu/packages/password-utils.scm b/gnu/packages/password-utils.scm index 06214297f7..333fbfa026 100644 --- a/gnu/packages/password-utils.scm +++ b/gnu/packages/password-utils.scm @@ -6,7 +6,7 @@ ;;; Copyright © 2016 Jessica Tallon <tsyesika@tsyesika.se> ;;; Copyright © 2016 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox.org> -;;; Copyright © 2016, 2019 Alex Griffin <a@ajgrf.com> +;;; Copyright © 2016, 2019, 2020 Alex Griffin <a@ajgrf.com> ;;; Copyright © 2017 Leo Famulari <leo@famulari.name> ;;; Copyright © 2017, 2018 Clément Lassieur <clement@lassieur.org> ;;; Copyright © 2017, 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr> @@ -46,6 +46,7 @@ #:use-module ((guix licenses) #:prefix license:) #:use-module (guix build-system cmake) #:use-module (guix build-system gnu) + #:use-module (guix build-system go) #:use-module (guix build-system trivial) #:use-module (guix download) #:use-module (guix git-download) @@ -65,6 +66,7 @@ #:use-module (gnu packages gettext) #:use-module (gnu packages glib) #:use-module (gnu packages gnupg) + #:use-module (gnu packages golang) #:use-module (gnu packages gtk) #:use-module (gnu packages guile) #:use-module (gnu packages kerberos) @@ -697,6 +699,82 @@ using password-store through rofi interface: @end enumerate") (license license:gpl3))) +(define-public browserpass-native + (package + (name "browserpass-native") + (version "3.0.6") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/browserpass/browserpass-native.git") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0q3bsla07zjl6i69nj1axbkg2ia89pvh0jg6nlqgbm2kpzzbn0pz")))) + (build-system go-build-system) + (arguments + `(#:import-path "github.com/browserpass/browserpass-native" + #:install-source? #f + #:phases + (modify-phases %standard-phases + (add-before 'build 'patch-makefile + (lambda* (#:key outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out"))) + ;; This doesn't go in #:make-flags because the Makefile itself + ;; gets installed. + (substitute* + "src/github.com/browserpass/browserpass-native/Makefile" + (("PREFIX \\?= /usr") + (string-append "PREFIX ?= " out))) + #t))) + (add-before 'build 'configure + (lambda _ + (with-directory-excursion + "src/github.com/browserpass/browserpass-native" + (invoke "make" "configure")) + #t)) + (replace 'build + (lambda _ + (with-directory-excursion + "src/github.com/browserpass/browserpass-native" + (invoke "make")) + #t)) + (replace 'install + (lambda _ + (with-directory-excursion + "src/github.com/browserpass/browserpass-native" + (invoke "make" "install")) + #t)) + (add-after 'install 'wrap-executable + (lambda* (#:key inputs outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out")) + (gnupg (assoc-ref inputs "gnupg"))) + (wrap-program (string-append out "/bin/browserpass") + `("PATH" ":" prefix + (,(string-append gnupg "/bin")))) + #t)))))) + (native-inputs + `(("which" ,which))) + (inputs + `(("gnupg" ,gnupg) + ("go-github-com-mattn-go-zglob" ,go-github-com-mattn-go-zglob) + ("go-github-com-rifflock-lfshook" ,go-github-com-rifflock-lfshook) + ("go-github-com-sirupsen-logrus" ,go-github-com-sirupsen-logrus) + ("go-golang-org-x-sys" ,go-golang-org-x-sys))) + (home-page "https://github.com/browserpass/browserpass-native") + (synopsis "Browserpass native messaging host") + (description "Browserpass is a browser extension for pass, a +UNIX-based password store manager. It allows you to auto-fill or copy to +clipboard credentials for the current domain, protecting you from phishing +attacks. + +This package only contains the Browserpass native messaging host. You must +also install the browser extension for GNU IceCat or ungoogled-chromium +separately.") + (license license:isc))) + (define-public argon2 (package (name "argon2") |