diff options
| author | Chris Marusich <cmmarusich@gmail.com> | 2019-04-18 02:50:33 -0700 |
|---|---|---|
| committer | Chris Marusich <cmmarusich@gmail.com> | 2019-04-24 21:08:39 -0700 |
| commit | 5297e97599db5b6f1eb135ab2b7b488f83ac6b70 (patch) | |
| tree | ca62232c18c1422c8a8786cce50fb942ff03f98a /gnu | |
| parent | 41553c90e4152ae69f4793459abcc5a00928a8e5 (diff) | |
gnu: Add python-fido2 and python2-fido2.
* gnu/packages/security-token.scm (python-fido2, python2-fido2): New
variables.
Diffstat (limited to 'gnu')
| -rw-r--r-- | gnu/packages/security-token.scm | 61 |
1 files changed, 61 insertions, 0 deletions
diff --git a/gnu/packages/security-token.scm b/gnu/packages/security-token.scm index 6903a033d31..8844d529c5e 100644 --- a/gnu/packages/security-token.scm +++ b/gnu/packages/security-token.scm | |||
| @@ -29,6 +29,7 @@ | |||
| 29 | #:use-module ((guix licenses) #:prefix license:) | 29 | #:use-module ((guix licenses) #:prefix license:) |
| 30 | #:use-module (guix packages) | 30 | #:use-module (guix packages) |
| 31 | #:use-module (guix download) | 31 | #:use-module (guix download) |
| 32 | #:use-module (guix gexp) | ||
| 32 | #:use-module (guix git-download) | 33 | #:use-module (guix git-download) |
| 33 | #:use-module (guix build-system gnu) | 34 | #:use-module (guix build-system gnu) |
| 34 | #:use-module (guix build-system glib-or-gtk) | 35 | #:use-module (guix build-system glib-or-gtk) |
| @@ -38,6 +39,7 @@ | |||
| 38 | #:use-module (gnu packages check) | 39 | #:use-module (gnu packages check) |
| 39 | #:use-module (gnu packages docbook) | 40 | #:use-module (gnu packages docbook) |
| 40 | #:use-module (gnu packages documentation) | 41 | #:use-module (gnu packages documentation) |
| 42 | #:use-module (gnu packages dns) | ||
| 41 | #:use-module (gnu packages gettext) | 43 | #:use-module (gnu packages gettext) |
| 42 | #:use-module (gnu packages graphviz) | 44 | #:use-module (gnu packages graphviz) |
| 43 | #:use-module (gnu packages gtk) | 45 | #:use-module (gnu packages gtk) |
| @@ -53,6 +55,8 @@ | |||
| 53 | #:use-module (gnu packages perl) | 55 | #:use-module (gnu packages perl) |
| 54 | #:use-module (gnu packages pkg-config) | 56 | #:use-module (gnu packages pkg-config) |
| 55 | #:use-module (gnu packages python) | 57 | #:use-module (gnu packages python) |
| 58 | #:use-module (gnu packages python-crypto) | ||
| 59 | #:use-module (gnu packages python-xyz) | ||
| 56 | #:use-module (gnu packages swig) | 60 | #:use-module (gnu packages swig) |
| 57 | #:use-module (gnu packages web) | 61 | #:use-module (gnu packages web) |
| 58 | #:use-module (gnu packages xml)) | 62 | #:use-module (gnu packages xml)) |
| @@ -449,3 +453,60 @@ talk to a U2F device and perform the U2F Register and U2F Authenticate | |||
| 449 | operations.") | 453 | operations.") |
| 450 | ;; Most files are LGPLv2.1+, but some files are GPLv3+. | 454 | ;; Most files are LGPLv2.1+, but some files are GPLv3+. |
| 451 | (license (list license:lgpl2.1+ license:gpl3+)))) | 455 | (license (list license:lgpl2.1+ license:gpl3+)))) |
| 456 | |||
| 457 | (define-public python-fido2 | ||
| 458 | (package | ||
| 459 | (name "python-fido2") | ||
| 460 | (version "0.5.0") | ||
| 461 | (source (origin | ||
| 462 | (method url-fetch) | ||
| 463 | (uri | ||
| 464 | (string-append | ||
| 465 | "https://github.com/Yubico/python-fido2/releases/download/" | ||
| 466 | version "/fido2-" version ".tar.gz")) | ||
| 467 | (sha256 | ||
| 468 | (base32 | ||
| 469 | "1pl8d2pr6jzqj4y9qiaddhjgnl92kikjxy0bgzm2jshkzzic8mp3")) | ||
| 470 | (snippet | ||
| 471 | ;; Remove bundled dependency. | ||
| 472 | #~(delete-file "fido2/public_suffix_list.dat")))) | ||
| 473 | (build-system python-build-system) | ||
| 474 | (arguments | ||
| 475 | `(#:phases | ||
| 476 | (modify-phases %standard-phases | ||
| 477 | (add-after 'unpack 'install-public-suffix-list | ||
| 478 | (lambda* (#:key inputs #:allow-other-keys) | ||
| 479 | (copy-file | ||
| 480 | (string-append (assoc-ref inputs "public-suffix-list") | ||
| 481 | "/share/public-suffix-list-" | ||
| 482 | ,(package-version public-suffix-list) | ||
| 483 | "/public_suffix_list.dat") | ||
| 484 | "fido2/public_suffix_list.dat") | ||
| 485 | #t))))) | ||
| 486 | (propagated-inputs | ||
| 487 | `(("python-cryptography" ,python-cryptography) | ||
| 488 | ("python-six" ,python-six))) | ||
| 489 | (native-inputs | ||
| 490 | `(("python-mock" ,python-mock) | ||
| 491 | ("python-pyfakefs" ,python-pyfakefs) | ||
| 492 | ("public-suffix-list" ,public-suffix-list))) | ||
| 493 | (home-page "https://github.com/Yubico/python-fido2") | ||
| 494 | (synopsis "Python library for communicating with FIDO devices over USB") | ||
| 495 | (description | ||
| 496 | "This Python library provides functionality for communicating with a Fast | ||
| 497 | IDentity Online (FIDO) device over Universal Serial Bus (USB) as well as | ||
| 498 | verifying attestation and assertion signatures. It aims to support the FIDO | ||
| 499 | Universal 2nd Factor (U2F) and FIDO 2.0 protocols for communicating with a USB | ||
| 500 | authenticator via the Client-to-Authenticator Protocol (CTAP 1 and 2). In | ||
| 501 | addition to this low-level device access, classes defined in the | ||
| 502 | @code{fido2.client} and @code{fido2.server} modules implement higher level | ||
| 503 | operations which are useful when interfacing with an Authenticator, or when | ||
| 504 | implementing a Relying Party.") | ||
| 505 | ;; python-fido2 contains some derivative files originally from pyu2f | ||
| 506 | ;; (https://github.com/google/pyu2f). These files are licensed under the | ||
| 507 | ;; Apache License, version 2.0. The maintainers have customized these | ||
| 508 | ;; files for internal use, so they are not really a bundled dependency. | ||
| 509 | (license (list license:bsd-2 license:asl2.0)))) | ||
| 510 | |||
| 511 | (define-public python2-fido2 | ||
| 512 | (package-with-python2 python-fido2)) | ||
