gnu: perl-archive-zip: Update to 1.64.
[jackhill/guix/guix.git] / gnu / packages / gnupg.scm
CommitLineData
233e7676 1;;; GNU Guix --- Functional package management for GNU
464f5447 2;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018 Ludovic Courtès <ludo@gnu.org>
a92d9726 3;;; Copyright © 2013, 2015, 2018 Andreas Enge <andreas@enge.fr>
c8e3651a 4;;; Copyright © 2014, 2018 Eric Bavier <bavier@member.fsf.org>
3a7261bf 5;;; Copyright © 2014, 2015, 2016 Mark H Weaver <mhw@netris.org>
5dabdb75 6;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org>
607d280e 7;;; Copyright © 2015, 2016, 2017, 2018 Efraim Flashner <efraim@flashner.co.il>
5aeb6611 8;;; Copyright © 2015, 2016, 2017 Ricardo Wurmus <rekado@elephly.net>
a05d1d82 9;;; Copyright © 2016 Christopher Allan Webber <cwebber@dustycloud.org>
4a78fd46 10;;; Copyright © 2016, 2017 Nils Gillmann <ng0@n0.is>
41edb23f 11;;; Copyright © 2016 Christopher Baines <mail@cbaines.net>
cd9ed6c1 12;;; Copyright © 2016 Mike Gerwitz <mtg@gnu.org>
0f391063 13;;; Copyright © 2016 Troy Sankey <sankeytms@gmail.com>
e3dd1f0c 14;;; Copyright © 2017 Leo Famulari <leo@famulari.name>
5aeb6611 15;;; Copyright © 2017 Petter <petter@mykolab.ch>
f7147e27 16;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
df9f6289 17;;; Copyright © 2018 Marius Bakke <mbakke@fastmail.com>
8d1939e4 18;;;
233e7676 19;;; This file is part of GNU Guix.
8d1939e4 20;;;
233e7676 21;;; GNU Guix is free software; you can redistribute it and/or modify it
8d1939e4
LC
22;;; under the terms of the GNU General Public License as published by
23;;; the Free Software Foundation; either version 3 of the License, or (at
24;;; your option) any later version.
25;;;
233e7676 26;;; GNU Guix is distributed in the hope that it will be useful, but
8d1939e4
LC
27;;; WITHOUT ANY WARRANTY; without even the implied warranty of
28;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
29;;; GNU General Public License for more details.
30;;;
31;;; You should have received a copy of the GNU General Public License
233e7676 32;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
8d1939e4 33
1ffa7090 34(define-module (gnu packages gnupg)
07157e8a 35 #:use-module ((guix licenses) #:prefix license:)
a05d1d82 36 #:use-module (gnu packages)
7b40296f 37 #:use-module (gnu packages adns)
c9ce8e17 38 #:use-module (gnu packages autotools)
34ef5755 39 #:use-module (gnu packages base)
01e11826 40 #:use-module (gnu packages curl)
c9ce8e17 41 #:use-module (gnu packages crypto)
abc4a332 42 #:use-module (gnu packages emacs)
5e369f8a
EF
43 #:use-module (gnu packages enlightenment)
44 #:use-module (gnu packages gettext)
b0cb92b2 45 #:use-module (gnu packages guile)
01e11826 46 #:use-module (gnu packages openldap)
ea4d96c6 47 #:use-module (gnu packages perl)
5ccde207 48 #:use-module (gnu packages perl-check)
1ffa7090 49 #:use-module (gnu packages pth)
ea4d96c6 50 #:use-module (gnu packages python)
54df7558 51 #:use-module (gnu packages qt)
1ffa7090 52 #:use-module (gnu packages readline)
07157e8a 53 #:use-module (gnu packages compression)
2d12284d 54 #:use-module (gnu packages databases)
40d806af
LC
55 #:use-module (gnu packages gtk)
56 #:use-module (gnu packages glib)
d1d75c6a 57 #:use-module (gnu packages gnome)
40d806af
LC
58 #:use-module (gnu packages pkg-config)
59 #:use-module (gnu packages ncurses)
cd9ed6c1 60 #:use-module (gnu packages security-token)
e3dd1f0c 61 #:use-module (gnu packages swig)
b0cb92b2 62 #:use-module (gnu packages texinfo)
a7fd7b68 63 #:use-module (gnu packages tls)
15b08442
P
64 #:use-module (gnu packages tor)
65 #:use-module (gnu packages web)
66 #:use-module (gnu packages xml)
8d1939e4 67 #:use-module (guix packages)
87f5d366 68 #:use-module (guix download)
0f391063 69 #:use-module (guix git-download)
14e2e44d 70 #:use-module (guix build-system gnu)
34ef5755 71 #:use-module (guix build-system perl)
c8e3651a
EB
72 #:use-module (guix build-system python)
73 #:use-module (srfi srfi-1))
8d1939e4
LC
74
75(define-public libgpg-error
76 (package
77 (name "libgpg-error")
fa258af2 78 (version "1.32")
8d1939e4
LC
79 (source
80 (origin
87f5d366 81 (method url-fetch)
0db342a5 82 (uri (string-append "mirror://gnupg/libgpg-error/libgpg-error-"
8d1939e4
LC
83 version ".tar.bz2"))
84 (sha256
85 (base32
fa258af2 86 "1jj08ns4sh1hmafqp1giskvdicdz18la516va26jycy27kkwaif3"))))
8d1939e4 87 (build-system gnu-build-system)
72fb1b24 88 (home-page "https://gnupg.org")
35b9e423 89 (synopsis "Library of error values for GnuPG components")
8d1939e4
LC
90 (description
91 "Libgpg-error is a small library that defines common error values
92for all GnuPG components. Among these are GPG, GPGSM, GPGME,
93GPG-Agent, libgcrypt, Libksba, DirMngr, Pinentry, SmartCard
94Daemon and possibly more in the future.")
63e8bb12
LC
95 (license license:lgpl2.0+)
96 (properties '((ftp-server . "ftp.gnupg.org")
97 (ftp-directory . "/gcrypt/libgpg-error")))))
8d1939e4
LC
98
99(define-public libgcrypt
100 (package
101 (name "libgcrypt")
9dfbf405 102 (version "1.8.3")
84a3e3b7
LC
103 (source (origin
104 (method url-fetch)
105 (uri (string-append "mirror://gnupg/libgcrypt/libgcrypt-"
106 version ".tar.bz2"))
107 (sha256
108 (base32
4866cba6
BH
109 "0z5gs1khzyknyfjr19k8gk4q148s6q987ya85cpn0iv70fz91v36"))
110 (patches
111 (search-patches "libgcrypt-make-yat2m-reproducible.patch"))))
8d1939e4
LC
112 (build-system gnu-build-system)
113 (propagated-inputs
e0932742 114 `(("libgpg-error-host" ,libgpg-error)))
e766f699
JD
115 (native-inputs
116 ;; Needed here for the 'gpg-error' program.
e0932742 117 `(("libgpg-error-native" ,libgpg-error)))
e766f699
JD
118 (arguments
119 ;; The '--with-gpg-error-prefix' argument is needed because otherwise
120 ;; 'configure' uses 'gpg-error-config' to determine the '-L' flag, and
121 ;; the 'gpg-error-config' it runs is the native one---i.e., the wrong one.
122 `(#:configure-flags
123 (list (string-append "--with-gpg-error-prefix="
e0932742 124 (assoc-ref %build-inputs "libgpg-error-host")))))
40fed2d8 125 (outputs '("out" "debug"))
72fb1b24 126 (home-page "https://gnupg.org/")
f50d2669 127 (synopsis "Cryptographic function library")
8d1939e4 128 (description
a22dc0c4
LC
129 "Libgcrypt is a general-purpose cryptographic library. It provides the
130standard cryptographic building blocks such as symmetric ciphers, hash
131algorithms, public key algorithms, large integer functions and random number
132generation.")
63e8bb12
LC
133 (license license:lgpl2.0+)
134 (properties '((ftp-server . "ftp.gnupg.org")
135 (ftp-directory . "/gcrypt/libgcrypt")))))
8d1939e4
LC
136
137(define-public libassuan
138 (package
139 (name "libassuan")
5965b083 140 (version "2.5.1")
8d1939e4
LC
141 (source
142 (origin
87f5d366 143 (method url-fetch)
0db342a5 144 (uri (string-append "mirror://gnupg/libassuan/libassuan-"
8d1939e4
LC
145 version ".tar.bz2"))
146 (sha256
147 (base32
5965b083 148 "0jb4nb4nrjr949gd3lw8lh4v5d6qigxaq6xwy24w5apjnhvnrya7"))))
8d1939e4
LC
149 (build-system gnu-build-system)
150 (propagated-inputs
5965b083
LF
151 `(("libgpg-error" ,libgpg-error)
152 ("pth" ,pth)))
72fb1b24 153 (home-page "https://gnupg.org")
8d1939e4 154 (synopsis
35b9e423 155 "IPC library used by GnuPG and related software")
8d1939e4
LC
156 (description
157 "Libassuan is a small library implementing the so-called Assuan
158protocol. This protocol is used for IPC between most newer
159GnuPG components. Both, server and client side functions are
160provided.")
63e8bb12
LC
161 (license license:lgpl2.0+)
162 (properties '((ftp-server . "ftp.gnupg.org")
163 (ftp-directory . "/gcrypt/libassuan")))))
8d1939e4
LC
164
165(define-public libksba
166 (package
167 (name "libksba")
c95f7160 168 (version "1.3.5")
8d1939e4
LC
169 (source
170 (origin
87f5d366 171 (method url-fetch)
8d1939e4 172 (uri (string-append
0db342a5 173 "mirror://gnupg/libksba/libksba-"
8d1939e4
LC
174 version ".tar.bz2"))
175 (sha256
176 (base32
c95f7160 177 "0h53q4sns1jz1pkmhcz5wp9qrfn9f5g9i3vjv6dafwzzlvblyi21"))))
8d1939e4
LC
178 (build-system gnu-build-system)
179 (propagated-inputs
180 `(("libgpg-error" ,libgpg-error)))
e766f699
JD
181 (native-inputs
182 `(("libgpg-error" ,libgpg-error)))
183 (arguments
184 `(#:configure-flags
185 (list ,@(if (%current-target-system)
186 '("CC_FOR_BUILD=gcc")
187 '())
188 (string-append "--with-gpg-error-prefix="
189 (assoc-ref %build-inputs "libgpg-error")))))
72fb1b24 190 (home-page "https://www.gnupg.org")
35b9e423 191 (synopsis "CMS and X.509 access library")
8d1939e4
LC
192 (description
193 "KSBA (pronounced Kasbah) is a library to make X.509 certificates
194as well as the CMS easily accessible by other applications. Both
195specifications are building blocks of S/MIME and TLS.")
63e8bb12
LC
196 (license license:gpl3+)
197 (properties '((ftp-server . "ftp.gnupg.org")
198 (ftp-directory . "/gcrypt/libksba")))))
8d1939e4 199
c18ea90f
AE
200(define-public npth
201 (package
202 (name "npth")
f48a9d4a 203 (version "1.5")
c18ea90f
AE
204 (source
205 (origin
206 (method url-fetch)
89c83e8c 207 (uri (string-append "mirror://gnupg/npth/npth-" version ".tar.bz2"))
c18ea90f
AE
208 (sha256
209 (base32
f48a9d4a 210 "1hmkkp6vzyrh8v01c2ynzf9vwikyagp7p1lxhbnr4ysk3w66jji9"))))
c18ea90f 211 (build-system gnu-build-system)
72fb1b24 212 (home-page "https://www.gnupg.org")
c18ea90f
AE
213 (synopsis "Non-preemptive thread library")
214 (description
215 "Npth is a library to provide the GNU Pth API and thus a non-preemptive
216threads implementation.
217
218In contrast to GNU Pth is is based on the system's standard threads
219implementation. This allows the use of libraries which are not
220compatible to GNU Pth.")
07157e8a 221 (license (list license:lgpl3+ license:gpl2+)))) ; dual license
c18ea90f 222
8d1939e4
LC
223(define-public gnupg
224 (package
225 (name "gnupg")
b20aef98 226 (version "2.2.11")
58970d6a
LC
227 (source (origin
228 (method url-fetch)
229 (uri (string-append "mirror://gnupg/gnupg/gnupg-" version
230 ".tar.bz2"))
231 (sha256
232 (base32
b20aef98 233 "1ncwqjhcxh46fgkp84g2lhf91amcha7abk6wdm1kagzm7q93wv29"))))
8d1939e4 234 (build-system gnu-build-system)
08fa45b1
MW
235 (native-inputs
236 `(("pkg-config" ,pkg-config)))
8d1939e4 237 (inputs
f02d254a 238 `(("gnutls" ,gnutls)
8d1939e4
LC
239 ("libassuan" ,libassuan)
240 ("libgcrypt" ,libgcrypt)
01e11826 241 ("libgpg-error" ,libgpg-error)
8d1939e4 242 ("libksba" ,libksba)
cd064df7 243 ("npth" ,npth)
01e11826 244 ("openldap" ,openldap)
cd9ed6c1 245 ("pcsc-lite" ,pcsc-lite)
2d12284d
EF
246 ("readline" ,readline)
247 ("sqlite" ,sqlite)
248 ("zlib" ,zlib)))
30e9cbb4 249 (arguments
10756b9e 250 `(#:configure-flags '(;; Otherwise, the test suite looks for the `gpg`
f11275c9
LF
251 ;; executable in its installation directory in
252 ;; /gnu/store before it has been installed.
e184de57
EF
253 "--enable-gnupg-builddir-envvar"
254 "--enable-all-tests")
163708a6 255 #:phases
45477c6a 256 (modify-phases %standard-phases
cd9ed6c1
MG
257 (add-before 'configure 'patch-paths
258 (lambda* (#:key inputs #:allow-other-keys)
cd9ed6c1
MG
259 (substitute* "scd/scdaemon.c"
260 (("\"(libpcsclite\\.so[^\"]*)\"" _ name)
261 (string-append "\"" (assoc-ref inputs "pcsc-lite")
262 "/lib/" name "\"")))
7deb5ee8
LF
263 #t))
264 (add-after 'build 'patch-scheme-tests
265 (lambda _
266 (substitute* (find-files "tests" ".\\.scm$")
267 (("/usr/bin/env gpgscm")
764c5662
LF
268 (string-append (getcwd) "/tests/gpgscm/gpgscm")))
269 #t))
f11275c9 270 (add-before 'build 'patch-test-paths
92cc6a58
EF
271 (lambda _
272 (substitute* '("tests/inittests"
273 "tests/pkits/inittests"
274 "tests/Makefile"
275 "tests/pkits/common.sh"
276 "tests/pkits/Makefile")
277 (("/bin/pwd") (which "pwd")))
278 (substitute* "common/t-exectool.c"
279 (("/bin/cat") (which "cat"))
280 (("/bin/true") (which "true"))
281 (("/bin/false") (which "false")))
282 #t)))))
72fb1b24 283 (home-page "https://gnupg.org/")
f50d2669 284 (synopsis "GNU Privacy Guard")
8d1939e4 285 (description
a22dc0c4
LC
286 "The GNU Privacy Guard is a complete implementation of the OpenPGP
287standard. It is used to encrypt and sign data and communication. It
288features powerful key management and the ability to access public key
79c311b8 289servers. It includes several libraries: libassuan (IPC between GnuPG
58970d6a
LC
290components), libgpg-error (centralized GnuPG error values), and
291libskba (working with X.509 certificates and CMS data).")
63e8bb12
LC
292 (license license:gpl3+)
293 (properties '((ftp-server . "ftp.gnupg.org")
294 (ftp-directory . "/gcrypt/gnupg")))))
ea4d96c6 295
cd064df7
AE
296(define-public gnupg-2.0
297 (package (inherit gnupg)
b5afe6f0 298 (version "2.0.30")
cd064df7
AE
299 (source (origin
300 (method url-fetch)
301 (uri (string-append "mirror://gnupg/gnupg/gnupg-" version
302 ".tar.bz2"))
303 (sha256
304 (base32
b5afe6f0 305 "0wax4cy14hh0h7kg9hj0hjn9424b71z8lrrc5kbsasrn9xd7hag3"))))
08fa45b1 306 (native-inputs '())
cd064df7 307 (inputs
7b40296f
EF
308 `(("adns" ,adns)
309 ("bzip2" ,bzip2)
cd064df7
AE
310 ("curl" ,curl)
311 ("libassuan" ,libassuan)
312 ("libgcrypt" ,libgcrypt)
313 ("libgpg-error" ,libgpg-error)
314 ("libksba" ,libksba)
315 ("pth" ,pth)
316 ("openldap" ,openldap)
07157e8a 317 ("zlib" ,zlib)
cd064df7
AE
318 ("readline" ,readline)))
319 (arguments
320 `(#:phases
80c47cf8 321 (modify-phases %standard-phases
6b547d22
LC
322 (add-before 'configure 'patch-config-files
323 (lambda _
324 (substitute* "tests/openpgp/Makefile.in"
3a534f42 325 (("/bin/sh") (which "sh")))
bc85b127
LC
326 #t))
327 (add-after 'install 'rename-v2-commands
328 (lambda* (#:key outputs #:allow-other-keys)
329 ;; Upstream suggests removing the trailing '2' from command names:
330 ;; <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=22883#58>.
331 (let ((out (assoc-ref outputs "out")))
332 (with-directory-excursion (string-append out "/bin")
333 (rename-file "gpgv2" "gpgv")
334 (rename-file "gpg2" "gpg")
335
336 ;; Keep the old name around to ease transition.
337 (symlink "gpgv" "gpgv2")
338 (symlink "gpg" "gpg2")
806e891e
LF
339 #t)))))))
340 (properties `((superseded . ,gnupg)))))
cd064df7 341
5249045c
MW
342(define-public gnupg-1
343 (package (inherit gnupg)
b6c675c6 344 (version "1.4.23")
58970d6a
LC
345 (source (origin
346 (method url-fetch)
347 (uri (string-append "mirror://gnupg/gnupg/gnupg-" version
348 ".tar.bz2"))
349 (sha256
350 (base32
b6c675c6 351 "1fkq4sqldvf6a25mm2qz95swv1qjg464736091w51djiwqbjyin9"))))
08fa45b1 352 (native-inputs '())
5249045c 353 (inputs
07157e8a
LC
354 `(("zlib" ,zlib)
355 ("bzip2" ,bzip2)
5249045c
MW
356 ("curl" ,curl)
357 ("readline" ,readline)
358 ("libgpg-error" ,libgpg-error)))
359 (arguments
29d90757
LF
360 `(#:phases
361 (modify-phases %standard-phases
362 (add-after 'unpack 'patch-check-sh
363 (lambda _
364 (substitute* "checks/Makefile.in"
b17f7238
MW
365 (("/bin/sh") (which "sh")))
366 #t)))))))
5249045c 367
09d5c166
AE
368(define-public gpgme
369 (package
370 (name "gpgme")
df9f6289 371 (version "1.11.1")
09d5c166
AE
372 (source
373 (origin
374 (method url-fetch)
375 (uri (string-append "mirror://gnupg/gpgme/gpgme-" version
376 ".tar.bz2"))
377 (sha256
378 (base32
df9f6289 379 "0vxx5xaag3rhp4g2arp5qm77gvz4kj0m3hnpvhkdvqyjfhbi26rd"))))
09d5c166 380 (build-system gnu-build-system)
b3ecb3fe
LF
381 (native-inputs
382 `(("gnupg" ,gnupg)))
68640c3c
MW
383 (propagated-inputs
384 ;; Needs to be propagated because gpgme.h includes gpg-error.h.
7de44023 385 `(("libgpg-error" ,libgpg-error)))
09d5c166 386 (inputs
b3ecb3fe 387 `(("libassuan" ,libassuan)))
72fb1b24 388 (home-page "https://www.gnupg.org/related_software/gpgme/")
35b9e423 389 (synopsis "Library providing simplified access to GnuPG functionality")
09d5c166
AE
390 (description
391 "GnuPG Made Easy (GPGME) is a library designed to make access to GnuPG
392easier for applications. It provides a High-Level Crypto API for encryption,
393decryption, signing, signature verification and key management. Currently
394it uses GnuPG as its backend but the API isn't restricted to this engine.
395
396Because the direct use of GnuPG from an application can be a complicated
397programming task, it is suggested that all software should try to use GPGME
398instead. This way bug fixes or improvements can be done at a central place
399and every application benefits from this.")
07157e8a 400 (license license:lgpl2.1+)))
09d5c166 401
6b982a78
HG
402(define-public qgpgme
403 (package
404 (inherit gpgme)
405 (name "qgpgme")
406 (arguments
407 `(#:phases
408 (modify-phases %standard-phases
409 (add-before 'build 'chdir-and-symlink
410 (lambda* (#:key inputs #:allow-other-keys)
411 (let ((gpgme (assoc-ref inputs "gpgme")))
412 (symlink (string-append gpgme "/lib/libgpgmepp.la")
413 "lang/cpp/src/libgpgmepp.la")
414 (symlink (string-append gpgme "/lib/libgpgme.la")
415 "src/libgpgme.la"))
416 (chdir "lang/qt")
417 #t)))))
418 (native-inputs
0684f1d6
LF
419 `(("pkg-config" ,pkg-config)
420 ,@(package-native-inputs gpgme)))
6b982a78
HG
421 (inputs
422 `(("gpgme" ,gpgme)
423 ("qtbase" ,qtbase)
424 ,@(package-inputs gpgme)))
425 (synopsis "Qt API bindings for gpgme")
426 (description "QGpgme provides a very high level Qt API around GpgMEpp.
427
428QGpgME was originally developed as part of libkleo and incorporated into
429gpgpme starting with version 1.7.")
430 (license license:gpl2+))) ;; Note: this differs from gpgme
431
b0cb92b2
LC
432(define-public guile-gcrypt
433 (package
434 (name "guile-gcrypt")
435 (version "0.1.0")
436 (home-page "https://notabug.org/cwebber/guile-gcrypt")
437 (source (origin
438 (method git-fetch)
439 (uri (git-reference
440 (url (string-append home-page ".git"))
441 (commit (string-append "v" version))))
442 (sha256
443 (base32
444 "1lhgh3105yi0ggrjsjibv4wp1ipz8s17pa820hk2wln3rc04wpvf"))
445 (file-name (string-append name "-" version "-checkout"))))
446 (build-system gnu-build-system)
447 (native-inputs
448 `(("pkg-config" ,pkg-config)
449 ("autoconf" ,autoconf)
450 ("automake" ,automake)
451 ("texinfo" ,texinfo)))
452 (inputs
453 `(("guile" ,guile-2.2)
454 ("libgcrypt" ,libgcrypt)))
b0cb92b2
LC
455 (synopsis "Cryptography library for Guile using Libgcrypt")
456 (description
457 "Guile-Gcrypt provides a Guile 2.x interface to a subset of the
458GNU Libgcrypt crytographic library. It provides modules for cryptographic
459hash functions, message authentication codes (MAC), public-key cryptography,
460strong randomness, and more. It is implemented using the foreign function
461interface (FFI) of Guile.")
462 (license license:gpl3+)))
463
c8e3651a
EB
464(define-public guile2.0-gcrypt
465 (package (inherit guile-gcrypt)
466 (name "guile2.0-gcrypt")
467 (inputs
468 `(("guile" ,guile-2.0)
469 ,@(alist-delete "guile" (package-inputs guile-gcrypt))))))
470
e3dd1f0c
LF
471(define-public python-gpg
472 (package
473 (name "python-gpg")
fb4fcfab 474 (version "1.10.0")
e3dd1f0c
LF
475 (source (origin
476 (method url-fetch)
477 (uri (pypi-uri "gpg" version))
478 (sha256
479 (base32
fb4fcfab 480 "1ji3ynhp36m1ccx7bmaq75dhij9frpn19v9mpi4aajn8csl194il"))))
e3dd1f0c
LF
481 (build-system python-build-system)
482 (arguments
fb4fcfab
EF
483 '(#:phases
484 (modify-phases %standard-phases
485 (add-before 'build 'set-environment
486 (lambda _
487 (substitute* "setup.py"
488 (("cc") (which "gcc")))
489 #t)))
490 #:tests? #f)) ; No test suite.
e3dd1f0c
LF
491 (inputs
492 `(("gpgme" ,gpgme)))
493 (native-inputs
494 `(("swig" ,swig)))
495 (home-page (package-home-page gpgme))
496 (synopsis "Python bindings for GPGME GnuPG cryptography library")
497 (description "This package provides Python bindings to the GPGME GnuPG
498cryptographic library. It is developed in the GPGME source code, and then
499distributed separately.")
500 (license license:lgpl2.1+)))
501
502(define-public python2-gpg
503 (package-with-python2 python-gpg))
504
a05d1d82
CAW
505(define-public python-pygpgme
506 (package
507 (name "python-pygpgme")
508 (version "0.3")
509 (source
510 (origin
511 (method url-fetch)
512 (uri (pypi-uri "pygpgme" version))
513 (sha256
514 (base32
515 "1q82p3gs6lwq8j8dxk4pvrwk3jpww1zqcjrzznl9clh10z28gn2z"))
516 ;; Unfortunately, we have to disable some tests due to some gpg-agent
517 ;; goofiness... see:
518 ;; https://bugs.launchpad.net/pygpgme/+bug/999949
1c9cea74
LF
519 (patches (search-patches "pygpgme-disable-problematic-tests.patch"
520 "python-pygpgme-fix-pinentry-tests.patch"))))
a05d1d82
CAW
521 (arguments
522 `(#:phases
523 (modify-phases %standard-phases
524 (add-before 'build 'make-build
525 (lambda _
526 (zero? (system* "make" "build"))))
527 (replace 'check
528 (lambda _
529 (zero? (system* "make" "check")))))))
530 (build-system python-build-system)
e6f63412
LF
531 (native-inputs
532 `(("gnupg" ,gnupg-1)))
a05d1d82 533 (inputs
e6f63412 534 `(("gpgme" ,gpgme)))
a05d1d82
CAW
535 (home-page "https://launchpad.net/pygpgme")
536 (synopsis "Python module for working with OpenPGP messages")
537 (description
538 "PyGPGME is a Python module that lets you sign, verify, encrypt and
539decrypt messages using the OpenPGP format by making use of GPGME.")
540 (license license:lgpl2.1+)))
541
542(define-public python2-pygpgme
5c31f4aa 543 (package-with-python2 python-pygpgme))
a05d1d82 544
22af9029
RW
545(define-public python-gnupg
546 (package
547 (name "python-gnupg")
ff76a1e9 548 (version "0.4.3")
22af9029
RW
549 (source
550 (origin
551 (method url-fetch)
5b669ba1 552 (uri (pypi-uri "python-gnupg" version))
22af9029
RW
553 (sha256
554 (base32
ff76a1e9 555 "03dc8whhvk7ccspbk8vzfhkxli8cd9zfbss5p597g4jldgy8s59d"))))
22af9029
RW
556 (build-system python-build-system)
557 (arguments
558 `(#:phases
559 (modify-phases %standard-phases
560 (replace 'check
ec089763
RW
561 (lambda _
562 (substitute* "test_gnupg.py"
ec089763
RW
563 ;; Unsure why this test fails.
564 (("'test_search_keys'") "True")
565 (("def test_search_keys") "def disabled__search_keys"))
566 (setenv "USERNAME" "guixbuilder")
567 ;; The doctests are extremely slow and sometimes time out,
568 ;; so we disable them.
b262aba7
TGR
569 (invoke "python"
570 "test_gnupg.py" "--no-doctests"))))))
22af9029
RW
571 (native-inputs
572 `(("gnupg" ,gnupg-1)))
72fb1b24 573 (home-page "https://packages.python.org/python-gnupg/index.html")
22af9029
RW
574 (synopsis "Wrapper for the GNU Privacy Guard")
575 (description
576 "This module allows easy access to GnuPG’s key management, encryption
577and signature functionality from Python programs.")
578 (license license:bsd-3)))
579
580(define-public python2-gnupg
581 (package-with-python2 python-gnupg))
582
34ef5755
CB
583(define-public perl-gnupg-interface
584 (package
585 (name "perl-gnupg-interface")
586 (version "0.52")
9c2d0a03
RW
587 (source (origin
588 (method url-fetch)
589 (uri (string-append "mirror://cpan/authors/id/A/AL/ALEXMV/"
590 "GnuPG-Interface-" version ".tar.gz"))
591 (sha256
592 (base32
593 "0dgx8yhdsmhkazcrz14n4flrk1afv7azgl003hl4arxvi1d9yyi4"))))
34ef5755
CB
594 (build-system perl-build-system)
595 (arguments
9c2d0a03
RW
596 `(#:phases
597 (modify-phases %standard-phases
598 ;; FIXME: This test fails for unknown reasons
599 (add-after 'unpack 'delete-broken-test
600 (lambda _
601 (delete-file "t/encrypt_symmetrically.t")
602 #t)))))
34ef5755 603 (inputs
9c2d0a03 604 `(("gnupg" ,gnupg-1)))
34ef5755
CB
605 (propagated-inputs
606 `(("perl-moo" ,perl-moo)
9c2d0a03
RW
607 ("perl-moox-handlesvia" ,perl-moox-handlesvia)
608 ("perl-moox-late" ,perl-moox-late)))
609 (native-inputs
610 `(("which" ,which)
611 ("perl-module-install" ,perl-module-install)))
9aba9b12 612 (home-page "https://metacpan.org/release/GnuPG-Interface")
34ef5755 613 (synopsis "Perl interface to GnuPG")
9c2d0a03
RW
614 (description "@code{GnuPG::Interface} and its associated modules are
615designed to provide an object-oriented method for interacting with GnuPG,
616being able to perform functions such as but not limited to encrypting,
617signing, decryption, verification, and key-listing parsing.")
34ef5755
CB
618 (license license:perl-license)))
619
ea4d96c6 620(define-public pius
cda0ef04
TS
621 (package
622 (name "pius")
66eb91be 623 (version "2.2.6")
cda0ef04
TS
624 (source (origin
625 (method url-fetch)
626 (uri (string-append
627 "https://github.com/jaymzh/pius/releases/download/v"
628 version "/pius-" version ".tar.bz2"))
629 (sha256
630 (base32
a92d9726
AE
631 "1893hzpx3zv724drqv48csrn0cm98xw4ymb1zmhs2jvjj1778zfj"))
632 (patches (search-patches "pius.patch"))))
cda0ef04
TS
633 (build-system python-build-system)
634 (inputs `(("perl" ,perl) ;for 'pius-party-worksheet'
fcb1dd99
AE
635 ("gpg" ,gnupg)
636 ("python-six" ,python2-six)))
cda0ef04
TS
637 (arguments
638 `(#:tests? #f
639 #:python ,python-2 ;uses the Python 2 'print' syntax
640 #:phases
641 (modify-phases %standard-phases
642 (add-before
643 'build 'set-gpg-file-name
644 (lambda* (#:key inputs outputs #:allow-other-keys)
645 (let* ((gpg (string-append (assoc-ref inputs "gpg")
646 "/bin/gpg")))
647 (substitute* "libpius/constants.py"
648 (("/usr/bin/gpg2") gpg))
649 #t))))))
650 (synopsis "Programs to simplify GnuPG key signing")
651 (description
652 "Pius (PGP Individual UID Signer) helps attendees of PGP keysigning
35b9e423
EB
653parties. It is the main utility and makes it possible to quickly and easily
654sign each UID on a set of PGP keys. It is designed to take the pain out of
ea4d96c6
AE
655the sign-all-the-keys part of PGP Keysigning Party while adding security
656to the process.
657
658pius-keyring-mgr and pius-party-worksheet help organisers of
659PGP keysigning parties.")
cda0ef04
TS
660 (license license:gpl2)
661 (home-page "https://www.phildev.net/pius/index.shtml")))
96be765c
AE
662
663(define-public signing-party
831f07a0
LC
664 ;; Upstream moved from alioth.debian.org to salsa.debian.org but the
665 ;; automatic svn import did not preserve tags apparently, so there's no real
666 ;; version number.
667 (let ((commit "d6f2296325605ee96ddf9f5b156e5e3f667a6df3")
668 (revision "0"))
669 (package
670 (name "signing-party")
671 (version (git-version "2.6" revision commit))
672 (home-page "https://salsa.debian.org/stappers/pgp-tools")
673 (source (origin
674 (method git-fetch)
675 (uri (git-reference
676 (url home-page)
677 (commit commit)))
678 (sha256
679 (base32
680 "00f7zasbwcbjzd92br2j10pyjxv0aw1qb4540qfz2dxzxgmdscrz"))))
681 (build-system gnu-build-system)
682 (native-inputs
683 `(("autoconf" ,autoconf-wrapper)
684 ("automake" ,automake)))
685 (inputs `(("perl" ,perl)
686 ("perl-text-template" ,perl-text-template)
687 ("perl-mime-tools" ,perl-mime-tools)
688 ("perl-gnupg-interface" ,perl-gnupg-interface)
689 ("perl-net-idn-encode" ,perl-net-idn-encode)
690 ("libmd" ,libmd)))
691 (arguments
692 `(#:tests? #f
693 #:phases
694 (modify-phases %standard-phases
695 (replace 'configure
696 (lambda* (#:key outputs #:allow-other-keys)
697 (let ((out (assoc-ref outputs "out")))
698 (substitute* "keyanalyze/Makefile"
699 (("LDLIBS") (string-append "CC=" (which "gcc") "\nLDLIBS")))
700 (substitute* "keyanalyze/Makefile"
701 (("\\./configure") (string-append "./configure --prefix=" out)))
702 (substitute* "gpgwrap/Makefile"
703 (("\\} clean")
704 (string-append "} clean\ninstall:\n\tinstall -D bin/gpgwrap "
705 out "/bin/gpgwrap\n")))
706 (substitute* '("gpgsigs/Makefile" "keyanalyze/Makefile"
707 "keylookup/Makefile" "sig2dot/Makefile"
708 "springgraph/Makefile")
709 (("/usr") out))
710 (setenv "CONFIG_SHELL" (which "sh")))))
711 (replace 'install
712 (lambda* (#:key outputs #:allow-other-keys #:rest args)
713 (let ((out (assoc-ref outputs "out"))
714 (install (assoc-ref %standard-phases 'install)))
715 (apply install args)
716 (for-each
717 (lambda (dir file)
718 (copy-file (string-append dir "/" file)
719 (string-append out "/bin/" file)))
720 '("caff" "caff" "caff" "gpgdir" "gpg-key2ps"
721 "gpglist" "gpg-mailkeys" "gpgparticipants")
722 '("caff" "pgp-clean" "pgp-fixkey" "gpgdir" "gpg-key2ps"
723 "gpglist" "gpg-mailkeys" "gpgparticipants"))
724 (for-each
725 (lambda (dir file)
726 (copy-file (string-append dir "/" file)
727 (string-append out "/share/man/man1/" file)))
728 '("caff" "caff" "caff" "gpgdir"
729 "gpg-key2ps" "gpglist" "gpg-mailkeys"
730 "gpgparticipants" "gpgsigs" "gpgwrap/doc"
731 "keyanalyze" "keyanalyze/pgpring" "keyanalyze")
732 '("caff.1" "pgp-clean.1" "pgp-fixkey.1" "gpgdir.1"
733 "gpg-key2ps.1" "gpglist.1" "gpg-mailkeys.1"
734 "gpgparticipants.1" "gpgsigs.1" "gpgwrap.1"
735 "process_keys.1" "pgpring.1" "keyanalyze.1")))))
736 (add-after 'install 'wrap-programs
737 (lambda* (#:key outputs #:allow-other-keys)
738 (let* ((out (assoc-ref outputs "out")))
739 (wrap-program
740 (string-append out "/bin/caff")
741 `("PERL5LIB" ":" prefix (,(getenv "PERL5LIB"))))))))))
742 (synopsis "Collection of scripts for simplifying gnupg key signing")
743 (description
744 "Signing-party is a collection for all kinds of PGP/GnuPG related things,
96be765c 745including tools for signing keys, keyring analysis, and party preparation.
7ac53403
EF
746@enumerate
747@item caff: CA - Fire and Forget signs and mails a key
748@item pgp-clean: removes all non-self signatures from key
749@item pgp-fixkey: removes broken packets from keys
750@item gpg-mailkeys: simply mail out a signed key to its owner
751@item gpg-key2ps: generate PostScript file with fingerprint paper strips
752@item gpgdir: recursive directory encryption tool
753@item gpglist: show who signed which of your UIDs
754@item gpgsigs: annotates list of GnuPG keys with already done signatures
755@item gpgparticipants: create list of party participants for the organiser
756@item gpgwrap: a passphrase wrapper
757@item keyanalyze: minimum signing distance (MSD) analysis on keyrings
758@item keylookup: ncurses wrapper around gpg --search
759@item sig2dot: converts a list of GnuPG signatures to a .dot file
760@item springgraph: creates a graph from a .dot file
761@end enumerate")
831f07a0
LC
762 ;; gpl2+ for almost all programs, except for keyanalyze: gpl2
763 ;; and caff and gpgsigs: bsd-3, see
764 ;; http://packages.debian.org/changelogs/pool/main/s/signing-party/current/copyright
765 (license license:gpl2))))
40d806af 766
c607b701 767(define-public pinentry-tty
40d806af 768 (package
c607b701 769 (name "pinentry-tty")
4498cbd7 770 (version "1.1.0")
40d806af
LC
771 (source (origin
772 (method url-fetch)
773 (uri (string-append "mirror://gnupg/pinentry/pinentry-"
774 version ".tar.bz2"))
775 (sha256
776 (base32
4498cbd7 777 "0w35ypl960pczg5kp6km3dyr000m1hf0vpwwlh72jjkjza36c1v8"))))
40d806af 778 (build-system gnu-build-system)
c607b701
EF
779 (arguments
780 `(#:configure-flags '("--enable-pinentry-tty")))
40d806af
LC
781 (inputs
782 `(("ncurses" ,ncurses)
18ed97d6 783 ("libassuan" ,libassuan)
c607b701 784 ("libsecret" ,libsecret "out")))
40d806af
LC
785 (native-inputs
786 `(("pkg-config" ,pkg-config)))
547cb17d 787 (home-page "https://gnupg.org/aegypten2/")
40d806af
LC
788 (synopsis "GnuPG's interface to passphrase input")
789 (description
c607b701 790 "Pinentry provides a console that allows users to enter a passphrase when
9614897b 791@code{gpg} is run and needs it.")
f8457932
LC
792 (license license:gpl2+)
793 (properties '((ftp-server . "ftp.gnupg.org")
794 (ftp-directory . "/gcrypt/pinentry")
795 (upstream-name . "pinentry")))))
4380a7b4 796
abc4a332
PN
797(define-public pinentry-emacs
798 (package
799 (inherit pinentry-tty)
800 (name "pinentry-emacs")
801 (arguments
802 `(#:configure-flags '("--enable-pinentry-emacs")))
803 (description
804 "Pinentry provides a console and an Emacs interface that allows users to
805enter a passphrase when required by @code{gpg} or other software.")))
806
c607b701
EF
807(define-public pinentry-gtk2
808 (package
809 (inherit pinentry-tty)
810 (name "pinentry-gtk2")
811 (inputs
812 `(("gtk+" ,gtk+-2)
813 ("glib" ,glib)
814 ,@(package-inputs pinentry-tty)))
815 (description
816 "Pinentry provides a console and a GTK+ GUI that allows users to enter a
9614897b 817passphrase when @code{gpg} is run and needs it.")))
c607b701 818
41edb23f
CB
819(define-public pinentry-gnome3
820 (package
821 (inherit pinentry-tty)
822 (name "pinentry-gnome3")
823 (inputs
824 `(("gtk+" ,gtk+-2)
825 ("gcr" ,gcr)
826 ("glib" ,glib)
827 ,@(package-inputs pinentry-tty)))
828 (arguments
829 `(#:configure-flags '("--enable-pinentry-gnome3")))
830 (description
831 "Pinentry provides a console and a GUI designed for use with GNOME@tie{}3
832that allows users to enter a passphrase when required by @code{gpg} or other
833software.")))
c607b701 834
54df7558
EF
835(define-public pinentry-qt
836 (package
837 (inherit pinentry-tty)
838 (name "pinentry-qt")
839 (inputs
e2788cef 840 `(("qtbase" ,qtbase)
54df7558 841 ,@(package-inputs pinentry-tty)))
984ad832
DC
842 (arguments
843 `(#:configure-flags '("CXXFLAGS=-std=gnu++11")))
54df7558
EF
844 (description
845 "Pinentry provides a console and a Qt GUI that allows users to enter a
9614897b 846passphrase when @code{gpg} is run and needs it.")))
54df7558 847
5e369f8a
EF
848(define-public pinentry-efl
849 (package
850 (inherit pinentry-tty)
851 (name "pinentry-efl")
852 (source
853 (origin
854 (inherit (package-source pinentry-tty))
855 (patches (search-patches "pinentry-efl.patch"))))
856 (arguments
857 '(#:configure-flags '("--enable-pinentry-efl")
858 #:phases
859 (modify-phases %standard-phases
860 (replace 'bootstrap
861 (lambda _
862 (invoke "sh" "autogen.sh"))))))
863 (native-inputs
864 `(("autoconf" ,autoconf)
865 ("automake" ,automake)
866 ("gettext" ,gettext-minimal)
867 ,@(package-native-inputs pinentry-tty)))
868 (inputs
869 `(("efl" ,efl)
870 ,@(package-inputs pinentry-tty)))
871 (description
872 "Pinentry provides a console and a graphical interface for the
873@dfn{Enlightenment Foundation Libraries} (EFL) that allows users to enter a
874passphrase when @code{gpg} is run and needs it.")))
875
940f8d39
EF
876(define-public pinentry
877 (package (inherit pinentry-gtk2)
878 (name "pinentry")))
879
4380a7b4
EB
880(define-public paperkey
881 (package
882 (name "paperkey")
ae9877fe 883 (version "1.5")
4380a7b4
EB
884 (source (origin
885 (method url-fetch)
886 (uri (string-append "http://www.jabberwocky.com/"
887 "software/paperkey/paperkey-"
888 version ".tar.gz"))
889 (sha256
890 (base32
ae9877fe 891 "1prd2jaf4zjad3xhv160hmi5n408ssljfg7iz90jxs9w111pjwy4"))))
4380a7b4
EB
892 (build-system gnu-build-system)
893 (arguments
894 `(#:phases
e379d85c
EF
895 (modify-phases %standard-phases
896 (add-before 'check 'patch-check-scripts
897 (lambda _
898 (substitute* '("checks/roundtrip.sh"
899 "checks/roundtrip-raw.sh")
900 (("/bin/echo") "echo"))
901 #t)))))
4380a7b4
EB
902 (home-page "http://www.jabberwocky.com/software/paperkey/")
903 (synopsis "Backup OpenPGP keys to paper")
904 (description
905 "Paperkey extracts the secret bytes from an OpenPGP (GnuPG, PGP, etc) key
906for printing with paper and ink, which have amazingly long retention
907qualities. To reconstruct a secret key, you re-enter those
908bytes (whether by hand, OCR, QR code, or the like) and paperkey can use
909them to transform your existing public key into a secret key.")
07157e8a 910 (license license:gpl2+)))
8384499c 911
912(define-public gpa
913 (package
914 (name "gpa")
915 (version "0.9.10")
916 (source (origin
917 (method url-fetch)
918 (uri (string-append "mirror://gnupg/gpa/"
919 name "-" version ".tar.bz2"))
920 (sha256
921 (base32
922 "09xphbi2456qynwqq5n0yh0zdmdi2ggrj3wk4hsyh5lrzlvcrff3"))))
923 (build-system gnu-build-system)
924 (native-inputs
925 `(("pkg-config" ,pkg-config)))
926 (inputs
927 `(("gnupg" ,gnupg)
928 ("gpgme" ,gpgme)
929 ("libassuan" ,libassuan)
930 ("libgpg-error" ,libgpg-error)
931 ("gtk+-2" ,gtk+-2)))
932 (home-page "https://gnupg.org/software/gpa/")
933 (synopsis "Graphical user interface for GnuPG")
934 (description
935 "GPA, the GNU Privacy Assistant, is a graphical user interface for
936@uref{https://gnupg.org, GnuPG}. It can be used to encrypt, decrypt, and sign
937files, to verify signatures, and to manage the private and public keys.")
938 (license license:gpl3+)))
5aeb6611 939
15b08442
P
940(define-public parcimonie
941 (package
942 (name "parcimonie")
943 (version "0.10.3")
944 (source (origin
945 (method url-fetch)
946 (uri (string-append "https://gaffer.ptitcanardnoir.org/"
947 "intrigeri/files/parcimonie/App-Parcimonie-"
948 version ".tar.gz"))
949 (sha256
950 (base32
951 "1kf891117s1f3k6lxvbjdb21va9gxh29vlp9bd664ssgw266rcyb"))))
952 (build-system perl-build-system)
953 (inputs
954 `(("gnupg" ,gnupg-1) ; This is the version used by perl-gnupg-interface
955 ("perl-config-general" ,perl-config-general)
956 ("perl-clone" ,perl-clone)
957 ("perl-data" ,perl-data)
958 ("perl-exporter-tiny" ,perl-exporter-tiny)
959 ("perl-file-homedir" ,perl-file-homedir)
960 ("perl-file-sharedir" ,perl-file-sharedir)
961 ("perl-file-which" ,perl-file-which)
962 ("perl-getopt-long-descriptive" ,perl-getopt-long-descriptive)
963 ("perl-gnupg-interface" ,perl-gnupg-interface)
964 ("perl-ipc-system-simple" ,perl-ipc-system-simple)
965 ("perl-list-moreutils" ,perl-list-moreutils)
966 ("perl-libintl-perl" ,perl-libintl-perl) ; Locale::TextDomain
967 ("perl-lwp-online" ,perl-lwp-online)
968 ("perl-module-build" ,perl-module-build)
969 ("perl-module-pluggable-object" ,perl-module-pluggable)
970 ("perl-moo" ,perl-moo)
971 ("perl-moox-handlesvia" ,perl-moox-handlesvia)
972 ("perl-moox-late" ,perl-moox-late)
973 ("perl-moox-options" ,perl-moox-options)
974 ("perl-namespace-clean" ,perl-namespace-clean)
975 ("perl-net-dbus" ,perl-net-dbus)
976 ("perl-net-dbus-glib" ,perl-net-dbus-glib)
977 ("perl-path-tiny" ,perl-path-tiny)
978 ("perl-test-most" ,perl-test-most)
979 ("perl-test-trap" ,perl-test-trap)
980 ("perl-time-duration" ,perl-time-duration)
981 ("perl-time-duration-parse" ,perl-time-duration-parse)
982 ("perl-try-tiny" ,perl-try-tiny)
983 ("perl-type-tiny" ,perl-type-tiny)
984 ("perl-types-path-tiny" ,perl-types-path-tiny)
985 ("perl-unicode-linebreak" ,perl-unicode-linebreak)
986 ("perl-xml-parser" ,perl-xml-parser)
987 ("perl-xml-twig" ,perl-xml-twig)
988 ("torsocks" ,torsocks)))
989 (arguments
990 `(#:phases
991 (modify-phases %standard-phases
992 ;; Needed for using gpg-connect-agent during tests.
993 (add-before 'check 'set-HOME
994 (lambda _ (setenv "HOME" "/tmp") #t))
995 (add-before 'install 'fix-references
996 (lambda* (#:key inputs outputs #:allow-other-keys)
997 (substitute* "lib/App/Parcimonie/GnuPG/Interface.pm"
998 (("gpg2") "gpg")
999 ;; Skip check whether dependencies are in the PATH
1000 (("defined which.*") "")
1001 (("call\\('parcimonie-torified-gpg'\\)")
1002 (string-append "call('" (assoc-ref outputs "out")
1003 "/bin/parcimonie-torified-gpg')")))
1004 (substitute* "bin/parcimonie-torified-gpg"
1005 (("torsocks") (string-append (assoc-ref inputs "torsocks")
1006 "/bin/torsocks")))
1007 #t))
1008 (add-after 'install 'wrap-program
1009 (lambda* (#:key inputs outputs #:allow-other-keys)
1010 (let* ((out (assoc-ref outputs "out"))
1011 (perllib (string-append out "/lib/perl5/site_perl/"
1012 ,(package-version perl))))
1013 (wrap-program (string-append out "/bin/parcimonie")
1014 `("PERL5LIB" ":"
1015 prefix (,(string-append perllib ":" (getenv "PERL5LIB")))))
1016 #t))))))
1017 (home-page "https://gaffer.ptitcanardnoir.org/intrigeri/code/parcimonie/")
1018 (synopsis "Incrementally refreshes a GnuPG keyring")
1019 (description "Parcimonie incrementaly refreshes a GnuPG keyring in a way
1020that makes it hard to correlate the keyring content to an individual, and
1021makes it hard to locate an individual based on an identifying subset of her
1022keyring content. Parcimonie is a daemon that fetches one key at a time using
1023the Tor network, waits a bit, changes the Tor circuit being used, and starts
1024over.")
1025 (license license:gpl1+)))
607d280e
EF
1026
1027(define-public jetring
1028 (package
1029 (name "jetring")
835cf37c 1030 (version "0.27")
607d280e
EF
1031 (source
1032 (origin
1033 (method url-fetch)
1034 (uri (string-append "mirror://debian/pool/main/j/" name "/"
1035 name "_" version ".tar.xz"))
1036 (sha256
1037 (base32
835cf37c 1038 "0jy0x5zj7v87xgyldlsx1knzp0mv10wzamblrw1b61i2m1ii4pxz"))))
607d280e
EF
1039 (build-system gnu-build-system)
1040 (arguments
1041 '(#:phases
1042 (modify-phases %standard-phases
1043 (delete 'configure) ; no configure script
1044 (add-before 'install 'hardlink-gnupg
1045 (lambda* (#:key inputs #:allow-other-keys)
1046 (let ((gpg (string-append (assoc-ref inputs "gnupg")
1047 "/bin/gpg")))
1048 (substitute* (find-files "." "jetring-[[:alpha:]]+$")
1049 (("gpg -") (string-append gpg " -"))
1050 (("\\\"gpg\\\"") (string-append "\"" gpg "\"")))
1051 #t)))
1052 (replace 'install
1053 (lambda* (#:key outputs #:allow-other-keys)
1054 (let* ((out (assoc-ref outputs "out"))
1055 (man (string-append out "/share/man")))
1056 (for-each (lambda (file)
1057 (install-file file (string-append out "/bin/")))
1058 (find-files "." "jetring-[[:alpha:]]+$"))
1059 (for-each (lambda (file)
1060 (install-file file (string-append man "/man1/")))
1061 (find-files "." ".*\\.1$"))
1062 (install-file "jetring.7" (string-append man "/man7/"))
1063 #t))))
1064 #:tests? #f)) ; no test phase
1065 (inputs
1066 `(("gnupg" ,gnupg)
1067 ("perl" ,perl)))
1068 (home-page "https://joeyh.name/code/jetring/")
1069 (synopsis "GnuPG keyring maintenance using changesets")
1070 (description
1071 "Jetring is a collection of tools that allow for gpg keyrings to be
1072maintained using changesets. It was developed with the Debian keyring in mind,
1073and aims to solve the problem that a gpg keyring is a binary blob that's hard
1074for multiple people to collaboratively edit.
1075
1076With jetring, changesets can be submitted, reviewed to see exactly what they
1077will do, applied, and used to build a keyring. The origin of every change made
1078to the keyring is available for auditing, and gpg signatures can be used for
1079integrity guarantees.")
1080 (license license:gpl2+)))