| 1 | ;;; GNU Guix --- Functional package management for GNU |
| 2 | ;;; Copyright © 2015 Steve Sprang <scs@stevesprang.com> |
| 3 | ;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Efraim Flashner <efraim@flashner.co.il> |
| 4 | ;;; Copyright © 2015 Aljosha Papsch <misc@rpapsch.de> |
| 5 | ;;; Copyright © 2016 Christopher Allan Webber <cwebber@dustycloud.org> |
| 6 | ;;; Copyright © 2016 Jessica Tallon <tsyesika@tsyesika.se> |
| 7 | ;;; Copyright © 2016 Andreas Enge <andreas@enge.fr> |
| 8 | ;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox.org> |
| 9 | ;;; Copyright © 2016, 2019, 2020 Alex Griffin <a@ajgrf.com> |
| 10 | ;;; Copyright © 2017 Leo Famulari <leo@famulari.name> |
| 11 | ;;; Copyright © 2017, 2018 Clément Lassieur <clement@lassieur.org> |
| 12 | ;;; Copyright © 2017, 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr> |
| 13 | ;;; Copyright © 2017 Jelle Licht <jlicht@fsfe.org> |
| 14 | ;;; Copyright © 2017, 2019 Eric Bavier <bavier@member.fsf.org> |
| 15 | ;;; Copyright © 2017, 2020 Nicolas Goaziou <mail@nicolasgoaziou.fr> |
| 16 | ;;; Copyright © 2017 Manolis Fragkiskos Ragkousis <manolis837@gmail.com> |
| 17 | ;;; Copyright © 2017 Rutger Helling <rhelling@mykolab.com> |
| 18 | ;;; Copyright © 2018 Marius Bakke <mbakke@fastmail.com> |
| 19 | ;;; Copyright © 2018 Konrad Hinsen <konrad.hinsen@fastmail.net> |
| 20 | ;;; Copyright © 2018 Thomas Sigurdsen <tonton@riseup.net> |
| 21 | ;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net> |
| 22 | ;;; Copyright © 2018 Pierre Neidhardt <mail@ambrevar.xyz> |
| 23 | ;;; Copyright © 2018 Amirouche Boubekki <amirouche@hypermove.net> |
| 24 | ;;; Copyright © 2018, 2019, 2020 Tim Gesthuizen <tim.gesthuizen@yahoo.de> |
| 25 | ;;; Copyright © 2019 Jens Mølgaard <jens@zete.tk> |
| 26 | ;;; Copyright © 2019 Tanguy Le Carrour <tanguy@bioneland.org> |
| 27 | ;;; Copyright © 2020 Guillaume Le Vaillant <glv@posteo.net> |
| 28 | ;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re> |
| 29 | ;;; Copyright © 2020 Jean-Baptiste Note <jean-baptiste.note@m4x.org> |
| 30 | ;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de> |
| 31 | ;;; |
| 32 | ;;; This file is part of GNU Guix. |
| 33 | ;;; |
| 34 | ;;; GNU Guix is free software; you can redistribute it and/or modify it |
| 35 | ;;; under the terms of the GNU General Public License as published by |
| 36 | ;;; the Free Software Foundation; either version 3 of the License, or (at |
| 37 | ;;; your option) any later version. |
| 38 | ;;; |
| 39 | ;;; GNU Guix is distributed in the hope that it will be useful, but |
| 40 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of |
| 41 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 42 | ;;; GNU General Public License for more details. |
| 43 | ;;; |
| 44 | ;;; You should have received a copy of the GNU General Public License |
| 45 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. |
| 46 | |
| 47 | (define-module (gnu packages password-utils) |
| 48 | #:use-module ((guix licenses) #:prefix license:) |
| 49 | #:use-module (guix build-system cmake) |
| 50 | #:use-module (guix build-system gnu) |
| 51 | #:use-module (guix build-system go) |
| 52 | #:use-module (guix build-system trivial) |
| 53 | #:use-module (guix download) |
| 54 | #:use-module (guix git-download) |
| 55 | #:use-module (guix packages) |
| 56 | #:use-module (gnu packages) |
| 57 | #:use-module (gnu packages admin) |
| 58 | #:use-module (gnu packages aidc) |
| 59 | #:use-module (gnu packages authentication) |
| 60 | #:use-module (gnu packages base) |
| 61 | #:use-module (gnu packages check) |
| 62 | #:use-module (gnu packages compression) |
| 63 | #:use-module (gnu packages crypto) |
| 64 | #:use-module (gnu packages cryptsetup) |
| 65 | #:use-module (gnu packages curl) |
| 66 | #:use-module (gnu packages docbook) |
| 67 | #:use-module (gnu packages file) |
| 68 | #:use-module (gnu packages freedesktop) |
| 69 | #:use-module (gnu packages gettext) |
| 70 | #:use-module (gnu packages glib) |
| 71 | #:use-module (gnu packages gnupg) |
| 72 | #:use-module (gnu packages golang) |
| 73 | #:use-module (gnu packages gtk) |
| 74 | #:use-module (gnu packages guile) |
| 75 | #:use-module (gnu packages kerberos) |
| 76 | #:use-module (gnu packages libffi) |
| 77 | #:use-module (gnu packages linux) |
| 78 | #:use-module (gnu packages man) |
| 79 | #:use-module (gnu packages multiprecision) |
| 80 | #:use-module (gnu packages ncurses) |
| 81 | #:use-module (gnu packages nss) |
| 82 | #:use-module (gnu packages opencl) |
| 83 | #:use-module (gnu packages perl) |
| 84 | #:use-module (gnu packages pkg-config) |
| 85 | #:use-module (gnu packages python) |
| 86 | #:use-module (gnu packages python-web) |
| 87 | #:use-module (gnu packages python-xyz) |
| 88 | #:use-module (gnu packages readline) |
| 89 | #:use-module (gnu packages ruby) |
| 90 | #:use-module (gnu packages security-token) |
| 91 | #:use-module (gnu packages suckless) |
| 92 | #:use-module (gnu packages tcl) |
| 93 | #:use-module (gnu packages tls) |
| 94 | #:use-module (gnu packages qt) |
| 95 | #:use-module (gnu packages version-control) |
| 96 | #:use-module (gnu packages wxwidgets) |
| 97 | #:use-module (gnu packages xdisorg) |
| 98 | #:use-module (gnu packages xorg) |
| 99 | #:use-module (gnu packages xml) |
| 100 | #:use-module (guix build-system python)) |
| 101 | |
| 102 | (define-public pwgen |
| 103 | (package |
| 104 | (name "pwgen") |
| 105 | (version "2.08") |
| 106 | (source |
| 107 | (origin |
| 108 | (method url-fetch) |
| 109 | (uri (string-append "mirror://sourceforge/pwgen/pwgen/" version |
| 110 | "/pwgen-" version ".tar.gz")) |
| 111 | (sha256 |
| 112 | (base32 "0yy90pqrr2pszzhb5hxjishq9qc7dqd290amiibqx9fm1b9kvc6s")))) |
| 113 | (build-system gnu-build-system) |
| 114 | (arguments |
| 115 | `(#:tests? #f)) ; no test suite |
| 116 | (home-page "http://pwgen.sourceforge.net/") |
| 117 | (synopsis "Password generator") |
| 118 | (description "Pwgen generates passwords which can be easily memorized by a |
| 119 | human.") |
| 120 | (license license:gpl2))) |
| 121 | |
| 122 | (define-public keepassxc |
| 123 | (package |
| 124 | (name "keepassxc") |
| 125 | (version "2.6.1") |
| 126 | (source |
| 127 | (origin |
| 128 | (method url-fetch) |
| 129 | (uri (string-append "https://github.com/keepassxreboot/keepassxc" |
| 130 | "/releases/download/" version "/keepassxc-" |
| 131 | version "-src.tar.xz")) |
| 132 | (sha256 |
| 133 | (base32 "1j4cmj5mv13m5b4ig950yas8ayybakqs366lp1cimmzw8ycparml")))) |
| 134 | (build-system cmake-build-system) |
| 135 | (arguments |
| 136 | '(#:configure-flags '("-DWITH_XC_ALL=YES" |
| 137 | "-DWITH_XC_UPDATECHECK=NO") |
| 138 | #:phases |
| 139 | (modify-phases %standard-phases |
| 140 | (add-after 'install 'wrap-bin |
| 141 | (lambda* (#:key outputs inputs #:allow-other-keys) |
| 142 | (let ((out (assoc-ref outputs "out"))) |
| 143 | (wrap-program (string-append out "/bin/keepassxc") |
| 144 | `("QT_PLUGIN_PATH" ":" prefix |
| 145 | ,(map (lambda (label) |
| 146 | (string-append (assoc-ref inputs label) |
| 147 | "/lib/qt5/plugins")) |
| 148 | '("qtbase" "qtsvg"))))) |
| 149 | #t))))) |
| 150 | (native-inputs |
| 151 | `(("asciidoctor" ,ruby-asciidoctor) |
| 152 | ("qttools" ,qttools))) |
| 153 | (inputs |
| 154 | `(("argon2" ,argon2) |
| 155 | ("libgcrypt" ,libgcrypt) |
| 156 | ("libsodium" ,libsodium) ; XC_BROWSER |
| 157 | ("libyubikey" ,libyubikey) ; XC_YUBIKEY |
| 158 | ("libxi" ,libxi) |
| 159 | ("libxtst" ,libxtst) |
| 160 | ("qrencode" ,qrencode) |
| 161 | ("qtbase" ,qtbase) |
| 162 | ("qtsvg" ,qtsvg) |
| 163 | ("qtx11extras" ,qtx11extras) |
| 164 | ("quazip" ,quazip) ; XC_KEESHARE |
| 165 | ("readline" ,readline) |
| 166 | ("yubikey-personalization" ,yubikey-personalization) ; XC_YUBIKEY |
| 167 | ("zlib" ,zlib))) |
| 168 | (home-page "https://www.keepassxc.org") |
| 169 | (synopsis "Password manager") |
| 170 | (description "KeePassXC is a password manager or safe which helps you to |
| 171 | manage your passwords in a secure way. You can put all your passwords in one |
| 172 | database, which is locked with one master key or a key-file which can be stored |
| 173 | on an external storage device. The databases are encrypted using the |
| 174 | algorithms AES or Twofish.") |
| 175 | ;; While various parts of the software are licensed under different licenses, |
| 176 | ;; the combined work falls under the GPLv3. |
| 177 | (license license:gpl3))) |
| 178 | |
| 179 | (define-public keepassx |
| 180 | (package |
| 181 | (name "keepassx") |
| 182 | (version "2.0.3") |
| 183 | (source |
| 184 | (origin |
| 185 | (method url-fetch) |
| 186 | (uri (string-append "https://www.keepassx.org/releases/" version |
| 187 | "/keepassx-" version ".tar.gz")) |
| 188 | (sha256 |
| 189 | (base32 |
| 190 | "1ia7cqx9ias38mnffsl7da7g1f66bcbjsi23k49sln0c6spb9zr3")))) |
| 191 | (build-system cmake-build-system) |
| 192 | (inputs |
| 193 | `(("libgcrypt" ,libgcrypt) |
| 194 | ("libxi" ,libxi) |
| 195 | ("libxtst" ,libxtst) |
| 196 | ("qt" ,qt-4))) |
| 197 | (native-inputs |
| 198 | `(("zlib" ,zlib))) |
| 199 | (home-page "https://www.keepassx.org") |
| 200 | (synopsis "Password manager") |
| 201 | (description "KeePassX is a password manager or safe which helps you to |
| 202 | manage your passwords in a secure way. You can put all your passwords in one |
| 203 | database, which is locked with one master key or a key-file which can be stored |
| 204 | on an external storage device. The databases are encrypted using the |
| 205 | algorithms AES or Twofish.") |
| 206 | ;; Non functional parts use various licences. |
| 207 | (license license:gpl3) |
| 208 | (properties `((superseded . ,keepassxc))))) |
| 209 | |
| 210 | (define-public pwsafe |
| 211 | (package |
| 212 | (name "pwsafe") |
| 213 | (version "3.52.0") |
| 214 | (home-page "https://www.pwsafe.org/") |
| 215 | (source |
| 216 | (origin |
| 217 | (method git-fetch) |
| 218 | (uri (git-reference |
| 219 | (url "https://github.com/pwsafe/pwsafe") |
| 220 | (commit version))) |
| 221 | (sha256 |
| 222 | (base32 "1ka7xsl63v0559fzf3pwc1iqr37gwr4vq5iaxa2hzar2g28hsxvh")) |
| 223 | (file-name (git-file-name name version)))) |
| 224 | (build-system cmake-build-system) |
| 225 | (native-inputs |
| 226 | `(("gettext" ,gettext-minimal) |
| 227 | ("gtest" ,googletest) |
| 228 | ("perl" ,perl) |
| 229 | ("zip" ,zip))) |
| 230 | (inputs `(("curl" ,curl) |
| 231 | ("file" ,file) |
| 232 | ("libuuid" ,util-linux "lib") |
| 233 | ("libxt" ,libxt) |
| 234 | ("libxtst" ,libxtst) |
| 235 | ("openssl" ,openssl) |
| 236 | ("qrencode" ,qrencode) |
| 237 | ("wxwidgets" ,wxwidgets) |
| 238 | ("xerces-c" ,xerces-c))) |
| 239 | (arguments '(#:configure-flags (list "-DNO_GTEST=YES") |
| 240 | #:phases (modify-phases %standard-phases |
| 241 | (add-after 'unpack 'add-gtest |
| 242 | (lambda* (#:key inputs #:allow-other-keys) |
| 243 | (chmod "CMakeLists.txt" #o644) |
| 244 | (let ((cmake-port (open-file "CMakeLists.txt" |
| 245 | "a"))) |
| 246 | (display "find_package(GTest) |
| 247 | add_subdirectory(src/test)\n" cmake-port) |
| 248 | (close cmake-port) |
| 249 | #t)))))) |
| 250 | (synopsis "Password safe with automatic input and key generation") |
| 251 | (description "pwsafe is a password manager originally designed by Bruce |
| 252 | Schneier. It offers a simple UI to manage passwords for different services. |
| 253 | There are other programs that support the file format on different |
| 254 | platforms.") |
| 255 | (license license:artistic2.0))) |
| 256 | |
| 257 | (define-public shroud |
| 258 | (package |
| 259 | (name "shroud") |
| 260 | (version "0.1.2") |
| 261 | (source (origin |
| 262 | (method url-fetch) |
| 263 | (uri (string-append "https://files.dthompson.us/shroud/shroud-" |
| 264 | version ".tar.gz")) |
| 265 | (sha256 |
| 266 | (base32 |
| 267 | "1l2shrhvcwfzkar9qiwb75nhcqmx25iz55lzmz0c187nbjhqzi9p")))) |
| 268 | (build-system gnu-build-system) |
| 269 | (native-inputs |
| 270 | `(("pkg-config" ,pkg-config))) |
| 271 | (arguments |
| 272 | `(#:modules ((guix build gnu-build-system) |
| 273 | (guix build utils) |
| 274 | (ice-9 popen) |
| 275 | (ice-9 rdelim)) |
| 276 | #:phases |
| 277 | (modify-phases %standard-phases |
| 278 | (add-after 'install 'wrap-shroud |
| 279 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 280 | (let* ((out (assoc-ref outputs "out")) |
| 281 | (guile (assoc-ref inputs "guile")) |
| 282 | (effective (read-line |
| 283 | (open-pipe* OPEN_READ |
| 284 | (string-append guile "/bin/guile") |
| 285 | "-c" "(display (effective-version))"))) |
| 286 | (ccachedir (string-append out |
| 287 | "/lib/guile/" effective "/site-ccache")) |
| 288 | (prog (string-append out "/bin/shroud"))) |
| 289 | (wrap-program prog |
| 290 | `("GUILE_LOAD_COMPILED_PATH" ":" prefix (,ccachedir))) |
| 291 | #t)))))) |
| 292 | (inputs |
| 293 | `(("guile" ,guile-2.2) |
| 294 | ("gnupg" ,gnupg) |
| 295 | ("xclip" ,xclip))) |
| 296 | (synopsis "GnuPG-based secret manager") |
| 297 | (description "Shroud is a simple secret manager with a command line |
| 298 | interface. The password database is stored as a Scheme s-expression and |
| 299 | encrypted with a GnuPG key. Secrets consist of an arbitrary number of |
| 300 | key/value pairs, making Shroud suitable for more than just password storage. |
| 301 | For copying and pasting secrets into web browsers and other graphical |
| 302 | applications, there is xclip integration." ) |
| 303 | (home-page "https://dthompson.us/projects/shroud.html") |
| 304 | (license license:gpl3+))) |
| 305 | |
| 306 | (define-public yapet |
| 307 | (package |
| 308 | (name "yapet") |
| 309 | (version "2.4") |
| 310 | (source |
| 311 | (origin |
| 312 | (method url-fetch) |
| 313 | (uri (string-append "https://yapet.guengel.ch/downloads/yapet-" |
| 314 | version ".tar.xz")) |
| 315 | (sha256 |
| 316 | (base32 "0b1v0whf70dfjzlwqwwvfv526s828skjvm4xvwly3vcvcmpz59sh")))) |
| 317 | (build-system gnu-build-system) |
| 318 | (inputs |
| 319 | `(("argon2" ,argon2) |
| 320 | ("ncurses" ,ncurses) |
| 321 | ("openssl" ,openssl))) |
| 322 | (native-inputs |
| 323 | `(("cppunit" ,cppunit) |
| 324 | ("pkg-config" ,pkg-config))) |
| 325 | (synopsis "Yet Another Password Encryption Tool") |
| 326 | (description "YAPET is a text based password manager using the Blowfish |
| 327 | encryption algorithm. Because of its small footprint and very few library |
| 328 | dependencies, it is suited for installing on desktop and server systems alike. |
| 329 | The text based user interface allows you to run YAPET easily in a Secure Shell |
| 330 | session. Two companion utilities enable users to convert CSV files to YAPET |
| 331 | and vice versa.") |
| 332 | (home-page "https://yapet.guengel.ch/") |
| 333 | (license license:gpl3+))) |
| 334 | |
| 335 | (define-public cracklib |
| 336 | (package |
| 337 | (name "cracklib") |
| 338 | (version "2.9.7") |
| 339 | (source |
| 340 | (origin |
| 341 | (method url-fetch) |
| 342 | (uri (string-append "https://github.com/cracklib/cracklib/" |
| 343 | "releases/download/v" version "/" |
| 344 | "cracklib-" version ".tar.bz2")) |
| 345 | (sha256 |
| 346 | (base32 "1rimpjsdnmw8f5b7k558cic41p2qy2n2yrlqp5vh7mp4162hk0py")))) |
| 347 | (build-system gnu-build-system) |
| 348 | (arguments |
| 349 | `(#:phases |
| 350 | (modify-phases %standard-phases |
| 351 | (add-after 'install 'install-dict |
| 352 | (lambda* (#:key make-flags #:allow-other-keys) |
| 353 | (begin |
| 354 | (chmod (string-append "util/cracklib-format") #o755) |
| 355 | (apply invoke "make" "dict" make-flags) |
| 356 | #t)))))) |
| 357 | (synopsis "Password checking library") |
| 358 | (home-page "https://github.com/cracklib/cracklib") |
| 359 | (description |
| 360 | "CrackLib is a library containing a C function which may be used in a |
| 361 | @command{passwd}-like program. The idea is simple: try to prevent users from |
| 362 | choosing passwords that could easily be guessed (or \"cracked\") by filtering |
| 363 | them out, at the source.") |
| 364 | (license license:lgpl2.1))) |
| 365 | |
| 366 | (define-public libpwquality |
| 367 | (package |
| 368 | (name "libpwquality") |
| 369 | (version "1.4.2") |
| 370 | (source (origin |
| 371 | (method url-fetch) |
| 372 | (uri (list |
| 373 | (string-append "https://github.com/libpwquality/libpwquality" |
| 374 | "/releases/download/libpwquality-" version |
| 375 | "/libpwquality-" version ".tar.bz2") |
| 376 | (string-append "https://launchpad.net/libpwquality/trunk/" |
| 377 | version "/+download/" |
| 378 | "libpwquality-" version ".tar.bz2"))) |
| 379 | (sha256 |
| 380 | (base32 |
| 381 | "13hw532fmzc5xjpy75d74rlfdlxf2a8ibb4hyy9c0s92wsgf0qsj")))) |
| 382 | (build-system gnu-build-system) |
| 383 | (arguments |
| 384 | ;; XXX: have RUNPATH issue. |
| 385 | '(#:configure-flags '("--disable-python-bindings"))) |
| 386 | (inputs |
| 387 | `(("cracklib" ,cracklib))) |
| 388 | (synopsis "Password quality checker") |
| 389 | (home-page "https://github.com/libpwquality/libpwquality") |
| 390 | (description |
| 391 | "Libpwquality is a library for password quality checking and generation of |
| 392 | random passwords that pass the checks.") |
| 393 | (license license:gpl2+))) |
| 394 | |
| 395 | (define-public assword |
| 396 | (package |
| 397 | (name "assword") |
| 398 | (version "0.11") |
| 399 | (source (origin |
| 400 | (method url-fetch) |
| 401 | (uri (list |
| 402 | (string-append |
| 403 | "http://http.debian.net/debian/pool/main/a/assword/" |
| 404 | "assword_" version ".orig.tar.gz"))) |
| 405 | (sha256 |
| 406 | (base32 |
| 407 | "03gkb6kvsghznbcw5l7nmrc6mn3ixkjd5jcs96ni4zs9l47jf7yp")))) |
| 408 | (arguments |
| 409 | `(;; irritatingly, tests do run but not there are two problems: |
| 410 | ;; - "import gtk" fails for unknown reasons here despite it the |
| 411 | ;; program working (indeed, I've found I have to do a logout and log |
| 412 | ;; back in in after an install order for some mumbo jumbo environment |
| 413 | ;; variable mess to work with pygtk and assword... what's up with |
| 414 | ;; that?) |
| 415 | ;; - even when the tests fail, they don't return a nonzero status, |
| 416 | ;; so I'm not sure how to programmatically get that information |
| 417 | #:tests? #f |
| 418 | #:phases |
| 419 | (modify-phases %standard-phases |
| 420 | (add-after 'install 'wrap-assword |
| 421 | (lambda* (#:key outputs #:allow-other-keys) |
| 422 | (let ((prog (string-append |
| 423 | (assoc-ref outputs "out") |
| 424 | "/bin/assword")) |
| 425 | (gi-typelib-path (getenv "GI_TYPELIB_PATH"))) |
| 426 | (wrap-program prog |
| 427 | `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path))) |
| 428 | #t))) |
| 429 | (add-after 'install 'manpage |
| 430 | (lambda* (#:key outputs #:allow-other-keys) |
| 431 | ;; Without this substitution, it fails with |
| 432 | ;; ImportError: No module named 'gpg' |
| 433 | (substitute* "Makefile" |
| 434 | (("PYTHONPATH=.") "")) |
| 435 | (invoke "make" "assword.1") |
| 436 | (install-file |
| 437 | "assword.1" |
| 438 | (string-append (assoc-ref outputs "out") "/share/man/man1"))))))) |
| 439 | (build-system python-build-system) |
| 440 | (native-inputs |
| 441 | `(("txt2man" ,txt2man))) |
| 442 | (inputs |
| 443 | `(("gtk+" ,gtk+) |
| 444 | ("python-xdo" ,python-xdo) |
| 445 | ("python-gpg" ,python-gpg) |
| 446 | ("python-pygobject" ,python-pygobject))) |
| 447 | (propagated-inputs |
| 448 | `(("xclip" ,xclip))) |
| 449 | (home-page "https://finestructure.net/assword/") |
| 450 | (synopsis "Password manager") |
| 451 | (description "assword is a simple password manager using GPG-wrapped |
| 452 | JSON files. It has a command line interface as well as a very simple |
| 453 | graphical interface, which can even \"type\" your passwords into |
| 454 | any X11 window.") |
| 455 | (license license:gpl3+))) |
| 456 | |
| 457 | (define-public password-store |
| 458 | (package |
| 459 | (name "password-store") |
| 460 | (version "1.7.3") |
| 461 | (source (origin |
| 462 | (method url-fetch) |
| 463 | (uri |
| 464 | (string-append "https://git.zx2c4.com/password-store/snapshot/" |
| 465 | name "-" version ".tar.xz")) |
| 466 | (sha256 |
| 467 | (base32 |
| 468 | "1x53k5dn3cdmvy8m4fqdld4hji5n676ksl0ql4armkmsds26av1b")))) |
| 469 | (build-system gnu-build-system) |
| 470 | (arguments |
| 471 | '(#:phases |
| 472 | (modify-phases %standard-phases |
| 473 | (delete 'configure) |
| 474 | (delete 'build) |
| 475 | (add-before 'install 'patch-system-extension-dir |
| 476 | (lambda* (#:key outputs #:allow-other-keys) |
| 477 | (let* ((out (assoc-ref outputs "out")) |
| 478 | (extension-dir (string-append out "/lib/password-store/extensions"))) |
| 479 | (substitute* "src/password-store.sh" |
| 480 | (("^SYSTEM_EXTENSION_DIR=.*$") |
| 481 | ;; lead with whitespace to prevent 'make install' from |
| 482 | ;; overwriting it again |
| 483 | (string-append " SYSTEM_EXTENSION_DIR=\"" |
| 484 | "${PASSWORD_STORE_SYSTEM_EXTENSION_DIR:-" |
| 485 | extension-dir |
| 486 | "}\"\n")))) |
| 487 | #t)) |
| 488 | (add-before 'install 'patch-passmenu-path |
| 489 | (lambda* (#:key inputs #:allow-other-keys) |
| 490 | (substitute* "contrib/dmenu/passmenu" |
| 491 | (("dmenu") (string-append (assoc-ref inputs "dmenu") |
| 492 | "/bin/dmenu")) |
| 493 | (("xdotool") (string-append (assoc-ref inputs "xdotool") |
| 494 | "/bin/xdotool"))) |
| 495 | #t)) |
| 496 | (add-after 'install 'install-passmenu |
| 497 | (lambda* (#:key outputs #:allow-other-keys) |
| 498 | (let* ((out (assoc-ref outputs "out")) |
| 499 | (bin (string-append out "/bin"))) |
| 500 | (install-file "contrib/dmenu/passmenu" bin) |
| 501 | #t))) |
| 502 | (add-after 'install 'wrap-path |
| 503 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 504 | (let ((out (assoc-ref outputs "out")) |
| 505 | (path (map (lambda (pkg) |
| 506 | (string-append (assoc-ref inputs pkg) "/bin")) |
| 507 | '("coreutils" "getopt" "git" "gnupg" "qrencode" |
| 508 | "sed" "tree" "which" "xclip")))) |
| 509 | (wrap-program (string-append out "/bin/pass") |
| 510 | `("PATH" ":" prefix (,(string-join path ":")))) |
| 511 | #t)))) |
| 512 | #:make-flags (list "CC=gcc" (string-append "PREFIX=" %output) |
| 513 | "WITH_ALLCOMP=yes" |
| 514 | (string-append "BASHCOMPDIR=" |
| 515 | %output "/etc/bash_completion.d")) |
| 516 | ;; Parallel tests may cause a race condition leading to a |
| 517 | ;; timeout in some circumstances. |
| 518 | #:parallel-tests? #f |
| 519 | #:test-target "test")) |
| 520 | (native-search-paths |
| 521 | (list (search-path-specification |
| 522 | (variable "PASSWORD_STORE_SYSTEM_EXTENSION_DIR") |
| 523 | (separator #f) ;single entry |
| 524 | (files '("lib/password-store/extensions"))))) |
| 525 | (inputs |
| 526 | `(("dmenu" ,dmenu) |
| 527 | ("getopt" ,util-linux) |
| 528 | ("git" ,git) |
| 529 | ("gnupg" ,gnupg) |
| 530 | ("qrencode" ,qrencode) |
| 531 | ("sed" ,sed) |
| 532 | ("tree" ,tree) |
| 533 | ("which" ,which) |
| 534 | ("xclip" ,xclip) |
| 535 | ("xdotool" ,xdotool))) |
| 536 | (home-page "https://www.passwordstore.org/") |
| 537 | (synopsis "Encrypted password manager") |
| 538 | (description "Password-store is a password manager which uses GnuPG to |
| 539 | store and retrieve passwords. The tool stores each password in its own |
| 540 | GnuPG-encrypted file, allowing the program to be simple yet secure. |
| 541 | Synchronization is possible using the integrated git support, which commits |
| 542 | changes to your password database to a git repository that can be managed |
| 543 | through the pass command.") |
| 544 | (license license:gpl2+))) |
| 545 | |
| 546 | (define-public pass-otp |
| 547 | (package |
| 548 | (name "pass-otp") |
| 549 | (version "1.2.0") |
| 550 | (source |
| 551 | (origin |
| 552 | (method url-fetch) |
| 553 | (uri |
| 554 | (string-append "https://github.com/tadfisher/pass-otp/releases/" |
| 555 | "download/v" version "/pass-otp-" version ".tar.gz")) |
| 556 | (sha256 |
| 557 | (base32 |
| 558 | "0rrs3iazq80dn0wbl20xkh270428jd8l99m5gd7hl93s4r4sc82p")))) |
| 559 | (build-system gnu-build-system) |
| 560 | (arguments |
| 561 | '(#:make-flags |
| 562 | (let* ((out (assoc-ref %outputs "out")) |
| 563 | (bashcomp (string-append out "/etc/bash_completion.d"))) |
| 564 | (list (string-append "PREFIX=" %output) |
| 565 | (string-append "BASHCOMPDIR=" bashcomp))) |
| 566 | #:phases |
| 567 | (modify-phases %standard-phases |
| 568 | (delete 'configure) |
| 569 | (add-after 'build 'patch-oath-path |
| 570 | (lambda* (#:key inputs #:allow-other-keys) |
| 571 | (substitute* "otp.bash" |
| 572 | (("^OATH=.*$") |
| 573 | (string-append |
| 574 | "OATH=" |
| 575 | (assoc-ref inputs "oath-toolkit") |
| 576 | "/bin/oathtool\n"))) |
| 577 | #t))) |
| 578 | #:test-target "test")) |
| 579 | (inputs |
| 580 | `(("oath-toolkit" ,oath-toolkit))) |
| 581 | (native-inputs |
| 582 | `(("password-store" ,password-store) |
| 583 | ("expect" ,expect) |
| 584 | ("git" ,git) |
| 585 | ("gnupg" ,gnupg) |
| 586 | ("which" ,which))) |
| 587 | (home-page "https://github.com/tadfisher/pass-otp") |
| 588 | (synopsis "Pass extension for managing one-time-password (OTP) tokens") |
| 589 | (description |
| 590 | "Pass OTP is an extension for password-store that allows adding |
| 591 | one-time-password (OTP) secrets, generating OTP codes, and displaying secret |
| 592 | key URIs using the standard otpauth:// scheme.") |
| 593 | (license license:gpl3+))) |
| 594 | |
| 595 | (define-public qtpass |
| 596 | (package |
| 597 | (name "qtpass") |
| 598 | (version "1.3.2") |
| 599 | (source |
| 600 | (origin |
| 601 | (method git-fetch) |
| 602 | (uri (git-reference |
| 603 | (url "https://github.com/IJHack/QtPass") |
| 604 | (commit (string-append "v" version)))) |
| 605 | (file-name (git-file-name name version)) |
| 606 | (sha256 |
| 607 | (base32 |
| 608 | "0748hjvhjrybi33ci3c8hcr74k9pdrf5jv8npf9hrsrmdyy1kr9x")))) |
| 609 | (build-system gnu-build-system) |
| 610 | (arguments |
| 611 | `(#:modules ((guix build gnu-build-system) |
| 612 | (guix build qt-utils) |
| 613 | (guix build utils)) |
| 614 | #:imported-modules (,@%gnu-build-system-modules |
| 615 | (guix build qt-utils)) |
| 616 | #:phases |
| 617 | (modify-phases %standard-phases |
| 618 | (replace 'configure |
| 619 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 620 | (let ((out (assoc-ref outputs "out"))) |
| 621 | ;; lupdate/lrelease need to find qmake. |
| 622 | (setenv "QMAKE" "qmake") |
| 623 | ;; qmake needs to find lrelease/lupdate. |
| 624 | (invoke "qmake" |
| 625 | "QMAKE_LRELEASE=lrelease" |
| 626 | "QMAKE_LUPDATE=lupdate" |
| 627 | (string-append "PREFIX=" out))))) |
| 628 | (add-after 'configure 'reset-resource-timestamps |
| 629 | ;; Reset timestamps on localization files for a reproducible build. |
| 630 | (lambda _ |
| 631 | (with-directory-excursion "localization" |
| 632 | (for-each (lambda (file) |
| 633 | (let* ((base (basename file ".qm")) |
| 634 | (src (string-append base ".ts")) |
| 635 | (st (stat src))) |
| 636 | (set-file-time file st))) |
| 637 | (find-files "." ".*\\.qm"))) |
| 638 | #t)) |
| 639 | (add-after 'install 'install-auxilliary |
| 640 | ;; Install man-page, icon and .desktop file. |
| 641 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 642 | (let* ((out (assoc-ref outputs "out")) |
| 643 | (applications (string-append out "/share/applications")) |
| 644 | (icons (string-append out "/share/icons/hicolor/scalable/apps")) |
| 645 | (man (string-append out "/share/man/man1"))) |
| 646 | (install-file "qtpass.desktop" applications) |
| 647 | (install-file "artwork/icon.svg" icons) |
| 648 | (rename-file (string-append icons "/icon.svg") |
| 649 | (string-append icons "/qtpass-icon.svg")) |
| 650 | (install-file "qtpass.1" man) |
| 651 | #t))) |
| 652 | (add-after 'install 'wrap-qt |
| 653 | (lambda* (#:key outputs #:allow-other-keys) |
| 654 | (wrap-qt-program (assoc-ref outputs "out") "qtpass") |
| 655 | #t)) |
| 656 | (add-before 'check 'check-setup |
| 657 | ;; Make Qt render "offscreen", required for tests. |
| 658 | (lambda _ |
| 659 | (setenv "QT_QPA_PLATFORM" "offscreen") |
| 660 | #t))))) |
| 661 | (native-inputs |
| 662 | `(("qttools" ,qttools))) |
| 663 | (inputs |
| 664 | `(("qtbase" ,qtbase) |
| 665 | ("qtsvg" ,qtsvg))) |
| 666 | (home-page "https://qtpass.org") |
| 667 | (synopsis "GUI for password manager password-store") |
| 668 | (description |
| 669 | "Qt-based graphical user interface for the password manager |
| 670 | password-store also known as pass. Can use either pass or gpg to interact |
| 671 | with password-store files. Features configurable password generation, |
| 672 | templates, clipboard handling, and per folder settings for multi-recipient |
| 673 | encryption.") |
| 674 | (license license:gpl3+))) |
| 675 | |
| 676 | (define-public rofi-pass |
| 677 | (package |
| 678 | (name "rofi-pass") |
| 679 | (version "2.0.2") |
| 680 | (source |
| 681 | (origin |
| 682 | (method url-fetch) |
| 683 | (uri |
| 684 | (string-append "https://raw.githubusercontent.com/carnager/rofi-pass/" |
| 685 | version "/rofi-pass")) |
| 686 | (sha256 |
| 687 | (base32 "0msldkndqp40nx1s5s7ggcr97ir4nshpmnyzvj5hqw1l7m3gvw6j")) |
| 688 | (file-name name))) |
| 689 | (build-system trivial-build-system) |
| 690 | (arguments |
| 691 | `(#:modules ((guix build utils)) |
| 692 | #:builder |
| 693 | (begin |
| 694 | (use-modules (guix build utils)) |
| 695 | (let ((source (string-append (assoc-ref %build-inputs "source"))) |
| 696 | (script "rofi-pass") |
| 697 | (out (assoc-ref %outputs "out"))) |
| 698 | (copy-file source script) |
| 699 | (chmod script #o555) |
| 700 | (install-file script (string-append out "/bin")))))) |
| 701 | (propagated-inputs |
| 702 | `(("password-store" ,password-store) |
| 703 | ("rofi" ,rofi) |
| 704 | ("xdotool" ,xdotool))) |
| 705 | (home-page "https://github.com/carnager/rofi-pass") |
| 706 | (synopsis "Rofi frontend for password-store") |
| 707 | (description "Rofi-pass provides a way to manipulate information stored |
| 708 | using password-store through rofi interface: |
| 709 | @enumerate |
| 710 | @item open URLs of entries with hotkey; |
| 711 | @item type any field from entry; |
| 712 | @item auto-typing of user and/or password fields; |
| 713 | @item auto-typing username based on path; |
| 714 | @item auto-typing of more than one field, using the autotype entry; |
| 715 | @item bookmarks mode (open stored URLs in browser, default: Alt+x). |
| 716 | @end enumerate") |
| 717 | (license license:gpl3))) |
| 718 | |
| 719 | (define-public browserpass-native |
| 720 | (package |
| 721 | (name "browserpass-native") |
| 722 | (version "3.0.7") |
| 723 | (source |
| 724 | (origin |
| 725 | (method git-fetch) |
| 726 | (uri (git-reference |
| 727 | (url "https://github.com/browserpass/browserpass-native") |
| 728 | (commit version))) |
| 729 | (file-name (git-file-name name version)) |
| 730 | (sha256 |
| 731 | (base32 |
| 732 | "1jkjslbbac49xjyjkc2b07phdm3i64z40kh6h55cl22dxjmpp1nb")))) |
| 733 | (build-system go-build-system) |
| 734 | (arguments |
| 735 | `(#:import-path "github.com/browserpass/browserpass-native" |
| 736 | #:install-source? #f |
| 737 | #:phases |
| 738 | (modify-phases %standard-phases |
| 739 | (add-before 'build 'patch-makefile |
| 740 | (lambda* (#:key outputs #:allow-other-keys) |
| 741 | (let ((out (assoc-ref outputs "out"))) |
| 742 | ;; This doesn't go in #:make-flags because the Makefile itself |
| 743 | ;; gets installed. |
| 744 | (substitute* |
| 745 | "src/github.com/browserpass/browserpass-native/Makefile" |
| 746 | (("PREFIX \\?= /usr") |
| 747 | (string-append "PREFIX ?= " out))) |
| 748 | #t))) |
| 749 | (add-before 'build 'configure |
| 750 | (lambda _ |
| 751 | (with-directory-excursion |
| 752 | "src/github.com/browserpass/browserpass-native" |
| 753 | (invoke "make" "configure")) |
| 754 | #t)) |
| 755 | (replace 'build |
| 756 | (lambda _ |
| 757 | (with-directory-excursion |
| 758 | "src/github.com/browserpass/browserpass-native" |
| 759 | (invoke "make")) |
| 760 | #t)) |
| 761 | (replace 'install |
| 762 | (lambda _ |
| 763 | (with-directory-excursion |
| 764 | "src/github.com/browserpass/browserpass-native" |
| 765 | (invoke "make" "install")) |
| 766 | #t)) |
| 767 | (add-after 'install 'wrap-executable |
| 768 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 769 | (let ((out (assoc-ref outputs "out")) |
| 770 | (gnupg (assoc-ref inputs "gnupg"))) |
| 771 | (wrap-program (string-append out "/bin/browserpass") |
| 772 | `("PATH" ":" prefix |
| 773 | (,(string-append gnupg "/bin")))) |
| 774 | #t)))))) |
| 775 | (native-inputs |
| 776 | `(("which" ,which))) |
| 777 | (inputs |
| 778 | `(("gnupg" ,gnupg) |
| 779 | ("go-github-com-mattn-go-zglob" ,go-github-com-mattn-go-zglob) |
| 780 | ("go-github-com-rifflock-lfshook" ,go-github-com-rifflock-lfshook) |
| 781 | ("go-github-com-sirupsen-logrus" ,go-github-com-sirupsen-logrus) |
| 782 | ("go-golang-org-x-sys" ,go-golang-org-x-sys))) |
| 783 | (home-page "https://github.com/browserpass/browserpass-native") |
| 784 | (synopsis "Browserpass native messaging host") |
| 785 | (description "Browserpass is a browser extension for pass, a |
| 786 | UNIX-based password store manager. It allows you to auto-fill or copy to |
| 787 | clipboard credentials for the current domain, protecting you from phishing |
| 788 | attacks. |
| 789 | |
| 790 | This package only contains the Browserpass native messaging host. You must |
| 791 | also install the browser extension for GNU IceCat or ungoogled-chromium |
| 792 | separately.") |
| 793 | (license license:isc))) |
| 794 | |
| 795 | (define-public argon2 |
| 796 | (package |
| 797 | (name "argon2") |
| 798 | (version "20190702") |
| 799 | (source |
| 800 | (origin |
| 801 | (method git-fetch) |
| 802 | (uri (git-reference |
| 803 | (url "https://github.com/P-H-C/phc-winner-argon2") |
| 804 | (commit version))) |
| 805 | (file-name (git-file-name name version)) |
| 806 | (sha256 |
| 807 | (base32 |
| 808 | "01rwanr4wmr9vm6c712x411wig543q195z2icn388z892a93lc7p")))) |
| 809 | (build-system gnu-build-system) |
| 810 | (arguments |
| 811 | `(#:test-target "test" |
| 812 | #:make-flags (list "CC=gcc" |
| 813 | (string-append "PREFIX=" (assoc-ref %outputs "out")) |
| 814 | "LIBRARY_REL=lib" |
| 815 | (string-append "ARGON2_VERSION=" ,version) |
| 816 | "OPTTEST=1") ; disable CPU optimization |
| 817 | #:phases |
| 818 | (modify-phases %standard-phases |
| 819 | (delete 'configure)))) ; No configure script. |
| 820 | (home-page "https://www.argon2.com/") |
| 821 | (synopsis "Password hashing library") |
| 822 | (description "Argon2 provides a key derivation function that was declared |
| 823 | winner of the 2015 Password Hashing Competition.") |
| 824 | ;; Argon2 is dual licensed under CC0 and ASL 2.0. Some of the source |
| 825 | ;; files are CC0 only; see README.md and LICENSE for details. |
| 826 | (license (list license:cc0 license:asl2.0)))) |
| 827 | |
| 828 | (define-public pass-git-helper |
| 829 | (package |
| 830 | (name "pass-git-helper") |
| 831 | (version "1.1.0") |
| 832 | (source |
| 833 | (origin |
| 834 | (method git-fetch) |
| 835 | (uri (git-reference |
| 836 | (url "https://github.com/languitar/pass-git-helper") |
| 837 | (commit (string-append "v" version)))) |
| 838 | (file-name (git-file-name name version)) |
| 839 | (sha256 |
| 840 | (base32 |
| 841 | "18nvwlp0w4aqj268wly60rnjzqw2d8jl0hbs6bkwp3hpzzz5g6yd")))) |
| 842 | (build-system python-build-system) |
| 843 | (arguments |
| 844 | `(#:phases |
| 845 | (modify-phases %standard-phases |
| 846 | (add-before 'build 'patch-pass-path |
| 847 | (lambda* (#:key inputs #:allow-other-keys) |
| 848 | (let* ((password-store (assoc-ref inputs "password-store")) |
| 849 | (pass (string-append password-store "/bin/pass"))) |
| 850 | (substitute* '("passgithelper.py" |
| 851 | "test_passgithelper.py") |
| 852 | (("'pass'") (string-append "'" pass "'"))) |
| 853 | #t))) |
| 854 | (replace 'check |
| 855 | (lambda _ |
| 856 | (setenv "HOME" (getcwd)) |
| 857 | (invoke "pytest")))))) |
| 858 | (inputs |
| 859 | `(("python-pyxdg" ,python-pyxdg) |
| 860 | ("password-store" ,password-store))) |
| 861 | (native-inputs |
| 862 | `(("python-pytest" ,python-pytest) |
| 863 | ("python-pytest-mock" ,python-pytest-mock))) |
| 864 | (home-page "https://github.com/languitar/pass-git-helper") |
| 865 | (synopsis "Git credential helper interfacing with pass") |
| 866 | (description "pass-git-helper is a git credential helper which |
| 867 | uses pass, the standard unix password manager, as the credential backend for |
| 868 | your git repositories. This is achieved by explicitly defining mappings |
| 869 | between hosts and entries in the password store.") |
| 870 | (license license:lgpl3+))) |
| 871 | |
| 872 | (define-public john-the-ripper-jumbo |
| 873 | (let ((official-version "1.9.0") |
| 874 | (jumbo-version "1")) |
| 875 | (package |
| 876 | (name "john-the-ripper-jumbo") |
| 877 | (version (string-append official-version "-" jumbo-version)) |
| 878 | (source |
| 879 | (origin |
| 880 | (method url-fetch) |
| 881 | (uri (string-append "http://www.openwall.com/john/j/john-" |
| 882 | official-version "-jumbo-" jumbo-version ".tar.xz")) |
| 883 | (sha256 |
| 884 | (base32 |
| 885 | "0fvz3v41hnaiv1ggpxanfykyfjq79cwp9qcqqn63vic357w27lgm")))) |
| 886 | (build-system gnu-build-system) |
| 887 | (native-inputs |
| 888 | `(("perl" ,perl))) |
| 889 | (inputs |
| 890 | `(("gmp" ,gmp) |
| 891 | ("libpcap" ,libpcap) |
| 892 | ("nss" ,nss) |
| 893 | ("openssl" ,openssl-1.0) |
| 894 | ("python" ,python-2) ; For "python" and "python2" shebangs |
| 895 | ("ruby" ,ruby) ; For genincstats.rb |
| 896 | ("zlib" ,zlib))) |
| 897 | (arguments |
| 898 | `(#:configure-flags |
| 899 | (list "--with-systemwide" |
| 900 | ;; Do not test for instruction set in configure, and do not |
| 901 | ;; pass '-march=native' to gcc: |
| 902 | "--disable-native-tests" |
| 903 | "--disable-native-march" |
| 904 | ,(string-append |
| 905 | "--enable-simd=" |
| 906 | (let ((system (or (%current-target-system) |
| 907 | (%current-system)))) |
| 908 | (cond |
| 909 | ((or (string-prefix? "x86_64" system) |
| 910 | (string-prefix? "i686" system)) "sse2") |
| 911 | ((string-prefix? "aarch" system) "neon") |
| 912 | (else "no"))))) |
| 913 | #:phases |
| 914 | (modify-phases %standard-phases |
| 915 | (add-before 'configure 'chdir-src |
| 916 | (lambda _ (chdir "src") #t)) |
| 917 | (replace 'install |
| 918 | (lambda _ |
| 919 | (let ((bindir (string-append %output "/bin")) |
| 920 | (docdir (string-append %output "/share/doc/john")) |
| 921 | (execdir (string-append %output "/libexec/john")) |
| 922 | (datadir (string-append %output "/share/john")) |
| 923 | (install-file-to (lambda (dir) |
| 924 | (lambda (f) (install-file f dir)))) |
| 925 | (symlink? (lambda (_ s) (eq? (stat:type s) 'symlink)))) |
| 926 | (with-directory-excursion "../run" |
| 927 | (for-each (install-file-to bindir) |
| 928 | (cons* |
| 929 | "john" "makechr" "cprepair" "SIPdump" "tgtsnarf" |
| 930 | "genmkvpwd" "mkvcalcproba" "calc_stat" "raw2dyna" |
| 931 | (find-files "." "(to|2)?john(-[^.]*)?$"))) |
| 932 | (for-each (lambda (f) ; Install symlinked aliases |
| 933 | (let ((tgt (string-append bindir "/" (basename f)))) |
| 934 | ;; The use of install-file above dereferences |
| 935 | ;; symlinks. We'd rather have the symlinks |
| 936 | ;; for clarity, so remove tgt before linking. |
| 937 | (when (file-exists? tgt) (delete-file tgt)) |
| 938 | (symlink "john" tgt))) |
| 939 | (find-files "." symlink?)) |
| 940 | (for-each (install-file-to execdir) |
| 941 | (cons* "mailer" "benchmark-unify" "relbench" |
| 942 | (find-files "." ".*\\.js"))) |
| 943 | (for-each (lambda (f) |
| 944 | (let* ((base (basename f)) |
| 945 | (name (substring base 0 (string-index base #\.))) |
| 946 | (link (string-append bindir "/" name))) |
| 947 | (install-file f execdir) |
| 948 | (when (and (executable-file? f) |
| 949 | (not (file-exists? link))) |
| 950 | (symlink (string-append execdir "/" base) link)))) |
| 951 | (find-files "." ".*\\.(pl|py|rb|lua)")) |
| 952 | (for-each (install-file-to datadir) |
| 953 | (append (find-files "." "(stats|dictionary.*)") |
| 954 | (find-files "." "(.*\\.chr|.*\\.lst)") |
| 955 | (find-files "." ".*\\.conf"))) |
| 956 | (copy-recursively "rules" (string-append datadir "/rules"))) |
| 957 | (copy-recursively "../doc" docdir) |
| 958 | #t))) |
| 959 | (delete 'check) ; Tests need installed .conf files; move after install |
| 960 | (add-after 'install 'check |
| 961 | (lambda args |
| 962 | (setenv "HOME" "/tmp") ; Some tests need to write to ~/.john |
| 963 | (setenv "OMP_NUM_THREADS" (number->string (parallel-job-count))) |
| 964 | (apply (assoc-ref %standard-phases 'check) args)))))) |
| 965 | (home-page "http://www.openwall.com/john/") |
| 966 | (synopsis "Password cracker") |
| 967 | (description "John the Ripper is a fast password cracker. Its primary |
| 968 | purpose is to detect weak Unix passwords. Besides several @code{crypt} |
| 969 | password hash types most commonly found on various Unix systems, supported out |
| 970 | of the box are Windows LM hashes, plus lots of other hashes and ciphers. This |
| 971 | is the community-enhanced, \"jumbo\" version of John the Ripper.") |
| 972 | (license license:gpl2+)))) |
| 973 | |
| 974 | (define-public sala |
| 975 | (package |
| 976 | (name "sala") |
| 977 | (version "1.3") |
| 978 | (source |
| 979 | (origin |
| 980 | (method url-fetch) |
| 981 | (uri (pypi-uri "sala" version)) |
| 982 | (sha256 |
| 983 | (base32 |
| 984 | "13qgmc3i2a0cqp8jqrfl93lnphfagb32pgfikc1gza2a14asxzi8")))) |
| 985 | (build-system python-build-system) |
| 986 | (arguments |
| 987 | ;; Sala is supposed to work with Python 3.2 or higher, |
| 988 | ;; but it doesn't work with Python 3.6. Better stick |
| 989 | ;; to Python 2, which works fine. |
| 990 | `(#:python ,python-2)) |
| 991 | (propagated-inputs |
| 992 | `(("gnupg" ,gnupg) |
| 993 | ("pwgen" ,pwgen))) |
| 994 | (home-page "http://www.digip.org/sala/") |
| 995 | (synopsis "Encrypted plaintext password store") |
| 996 | (description |
| 997 | "Store passwords and other bits of sensitive plain-text information |
| 998 | to encrypted files on a directory hierarchy. The information is protected |
| 999 | by GnuPG's symmetrical encryption.") |
| 1000 | (license license:expat))) |
| 1001 | |
| 1002 | (define-public fpm2 |
| 1003 | (package |
| 1004 | (name "fpm2") |
| 1005 | (version "0.79") |
| 1006 | (source (origin |
| 1007 | (method url-fetch) |
| 1008 | (uri (string-append "https://als.regnet.cz/fpm2/download/fpm2-" |
| 1009 | version ".tar.bz2")) |
| 1010 | (sha256 |
| 1011 | (base32 |
| 1012 | "19sdy1lygfhkg5nxi2w9a4d9kwvw24nxp0ix0p0lz91qpvk9qpnm")))) |
| 1013 | (build-system gnu-build-system) |
| 1014 | (inputs `(("gtk2" ,gtk+-2) |
| 1015 | ("gnupg" ,gnupg) |
| 1016 | ("libxml2" ,libxml2))) |
| 1017 | (native-inputs `(("pkg-config" ,pkg-config) |
| 1018 | ("intltool" ,intltool))) |
| 1019 | (arguments |
| 1020 | `(#:phases |
| 1021 | (modify-phases %standard-phases |
| 1022 | (add-before 'configure 'pre-configure |
| 1023 | ;; The file po/POTFILES.in ends up missing for some reason in |
| 1024 | ;; both nix and guix builds. Adding the file with contents |
| 1025 | ;; found during troubleshooting. |
| 1026 | (lambda _ |
| 1027 | (call-with-output-file "po/POTFILES.in" |
| 1028 | (lambda (port) |
| 1029 | (format port "data/fpm2.desktop.in |
| 1030 | data/fpm2.desktop.in.in |
| 1031 | fpm2.glade |
| 1032 | src/callbacks.c |
| 1033 | src/fpm.c |
| 1034 | src/fpm_file.c |
| 1035 | src/interface.c |
| 1036 | src/support.c |
| 1037 | fpm2.glade |
| 1038 | "))) |
| 1039 | #t))))) |
| 1040 | (synopsis "Manage, generate and store passwords encrypted") |
| 1041 | (description "FPM2 is GTK2 port from Figaro's Password Manager |
| 1042 | originally developed by John Conneely, with some new enhancements. |
| 1043 | |
| 1044 | Upstream development seems to have stopped. It is therefore recommended |
| 1045 | to use a different password manager.") |
| 1046 | (home-page "https://als.regnet.cz/fpm2/") |
| 1047 | (license license:gpl2+))) |
| 1048 | |
| 1049 | (define-public pass-rotate |
| 1050 | (package |
| 1051 | (name "pass-rotate") |
| 1052 | (version "0.1") |
| 1053 | (source |
| 1054 | (origin |
| 1055 | (method git-fetch) |
| 1056 | (uri (git-reference |
| 1057 | (url "https://github.com/ddevault/pass-rotate") |
| 1058 | (commit version))) |
| 1059 | (file-name (git-file-name name version)) |
| 1060 | (sha256 |
| 1061 | (base32 |
| 1062 | "1m067vvdlc85csbpkp8aw4s3ags7q8s3jszrr32kmj9qhk5c254f")))) |
| 1063 | (build-system python-build-system) |
| 1064 | (inputs |
| 1065 | `(("python-beautifulsoup4" ,python-beautifulsoup4) |
| 1066 | ("python-docopt" ,python-docopt) |
| 1067 | ("python-html5lib" ,python-html5lib) |
| 1068 | ("python-requests" ,python-requests))) |
| 1069 | (home-page "https://github.com/ddevault/pass-rotate") |
| 1070 | (synopsis "Rotate password on online services") |
| 1071 | (description "pass-rotate is a command line utility and python library for |
| 1072 | rotating passwords on various web services. It makes it easier to rotate your |
| 1073 | passwords, one at a time or in bulk, when security events or routine upkeep of |
| 1074 | your online accounts makes it necessary.") |
| 1075 | (license license:expat))) |
| 1076 | |
| 1077 | (define-public hashcat |
| 1078 | (package |
| 1079 | (name "hashcat") |
| 1080 | (version "6.1.1") |
| 1081 | (source |
| 1082 | (origin |
| 1083 | (method url-fetch) |
| 1084 | (uri (string-append "https://hashcat.net/files/hashcat-" |
| 1085 | version ".tar.gz")) |
| 1086 | (sha256 |
| 1087 | (base32 |
| 1088 | "104z63m7lqbb0sdrxhf9yi15l4a9zwf9m6zs9dbb3gf0nfxl1h9r")))) |
| 1089 | (native-inputs |
| 1090 | `(("opencl-headers" ,opencl-headers))) |
| 1091 | (build-system gnu-build-system) |
| 1092 | (arguments |
| 1093 | '(#:tests? #f ;no tests |
| 1094 | #:make-flags (list (string-append "PREFIX=" %output)) |
| 1095 | #:phases |
| 1096 | (modify-phases %standard-phases |
| 1097 | (delete 'configure)))) |
| 1098 | (home-page "https://hashcat.net/hashcat/") |
| 1099 | (synopsis "Advanced password recovery utility") |
| 1100 | (description "Hashcat is an password recovery utility, supporting five |
| 1101 | unique modes of attack for over 200 highly-optimized hashing algorithms. |
| 1102 | Hashcat currently supports CPUs, GPUs, and other hardware accelerators on |
| 1103 | Linux, Windows, and macOS, and has facilities to help enable distributed |
| 1104 | password cracking.") |
| 1105 | (license license:expat))) |
| 1106 | |
| 1107 | (define-public hashcat-utils |
| 1108 | (package |
| 1109 | (name "hashcat-utils") |
| 1110 | (version "1.9") |
| 1111 | (source |
| 1112 | (origin |
| 1113 | (method url-fetch) |
| 1114 | (uri (string-append "https://github.com/hashcat/hashcat-utils/releases/" |
| 1115 | "download/v" version "/" |
| 1116 | "hashcat-utils-" version ".7z")) |
| 1117 | (sha256 |
| 1118 | (base32 "0kq555kb338691qd7zjmi8vhq4km3apnsl2w63zh0igwzcjx6lx1")))) |
| 1119 | (native-inputs |
| 1120 | `(("p7zip" ,p7zip))) |
| 1121 | (inputs |
| 1122 | `(("perl" ,perl))) |
| 1123 | (build-system gnu-build-system) |
| 1124 | (arguments |
| 1125 | `(#:tests? #f ;no tests |
| 1126 | #:make-flags (list "CC=gcc" |
| 1127 | ;; Upstream bug(?): "make all" seems to remove the |
| 1128 | ;; Perl scripts from the source. |
| 1129 | "native") |
| 1130 | #:phases |
| 1131 | (modify-phases %standard-phases |
| 1132 | (replace 'unpack |
| 1133 | (lambda* (#:key source #:allow-other-keys) |
| 1134 | (invoke "7z" "x" source) |
| 1135 | (chdir (string-append "hashcat-utils-" ,version "/src")) |
| 1136 | #t)) |
| 1137 | (delete 'configure) |
| 1138 | (replace 'install |
| 1139 | (lambda* (#:key outputs #:allow-other-keys) |
| 1140 | (let ((out (string-append (assoc-ref outputs "out") "/bin"))) |
| 1141 | (mkdir-p out) |
| 1142 | (for-each |
| 1143 | (lambda (file) |
| 1144 | (copy-file file (string-append out "/" |
| 1145 | (basename file ".bin")))) |
| 1146 | (find-files "." "\\.bin$")) |
| 1147 | (for-each |
| 1148 | (lambda (file) |
| 1149 | (copy-file file (string-append out "/" |
| 1150 | (basename file ".pl")))) |
| 1151 | (find-files "../bin" "\\.pl$")) |
| 1152 | #t)))))) |
| 1153 | (home-page "https://github.com/hashcat/hashcat-utils/") |
| 1154 | (synopsis "Small utilities that are useful in advanced password cracking") |
| 1155 | (description "Hashcat-utils are a set of small utilities that are useful |
| 1156 | in advanced password cracking. They all are packed into multiple stand-alone |
| 1157 | binaries. All of these utils are designed to execute only one specific |
| 1158 | function. Since they all work with @code{STDIN} and @code{STDOUT} you can |
| 1159 | group them into chains.") |
| 1160 | (license license:expat))) |
| 1161 | |
| 1162 | (define-public bruteforce-luks |
| 1163 | (package |
| 1164 | (name "bruteforce-luks") |
| 1165 | (version "1.4.0") |
| 1166 | (source |
| 1167 | (origin |
| 1168 | (method url-fetch) |
| 1169 | (uri (string-append "https://github.com/glv2/bruteforce-luks/releases/download/" |
| 1170 | version |
| 1171 | "/bruteforce-luks-" |
| 1172 | version |
| 1173 | ".tar.lz")) |
| 1174 | (sha256 |
| 1175 | (base32 "0yawrlbbklhmvwr99wm7li3r0d5kxvpkwf33a12rji7z0ya5p340")))) |
| 1176 | (build-system gnu-build-system) |
| 1177 | (native-inputs |
| 1178 | `(("lzip" ,lzip))) |
| 1179 | (inputs |
| 1180 | `(("cryptsetup" ,cryptsetup))) |
| 1181 | (synopsis "LUKS encrypted volume cracker") |
| 1182 | (description |
| 1183 | "This is a cracker for LUKS encrypted volumes. It can be used either in |
| 1184 | exhaustive mode to try every password given a charset or in dictionary mode to |
| 1185 | try every password contained in a file.") |
| 1186 | (home-page "https://github.com/glv2/bruteforce-luks") |
| 1187 | (license license:gpl3+))) |
| 1188 | |
| 1189 | (define-public makepasswd |
| 1190 | (let ((commit "3545d57d3a589a392d7eb0df36a5286785345c9e") |
| 1191 | (revision "1")) |
| 1192 | (package |
| 1193 | (name "makepasswd") |
| 1194 | (version (git-version "0.5.4" revision commit)) |
| 1195 | (source |
| 1196 | (origin |
| 1197 | (method git-fetch) |
| 1198 | (uri (git-reference |
| 1199 | (url "https://github.com/khorben/makepasswd") |
| 1200 | (commit commit))) |
| 1201 | (file-name (git-file-name name version)) |
| 1202 | (sha256 |
| 1203 | (base32 "0lspqyyxbk6h28yxnp7pd5aib161vrkzgasam5jpzn35n1jacx2j")))) |
| 1204 | (build-system gnu-build-system) |
| 1205 | (native-inputs |
| 1206 | `(("pkg-config" ,pkg-config) |
| 1207 | ("libxslt" ,libxslt) |
| 1208 | ("libxml2" ,libxml2) |
| 1209 | ("docbook-xsl" ,docbook-xsl) |
| 1210 | ("docbook-xml" ,docbook-xml))) |
| 1211 | (inputs |
| 1212 | `(("openssl" ,openssl))) |
| 1213 | (arguments |
| 1214 | `(#:phases |
| 1215 | (modify-phases %standard-phases |
| 1216 | (delete 'configure)) |
| 1217 | #:make-flags (list "CC=gcc" |
| 1218 | (string-append "PREFIX=" (assoc-ref %outputs "out"))) |
| 1219 | #:tests? #f)) ;no tests |
| 1220 | (synopsis "Generate (pseudo-)random passwords and hashes") |
| 1221 | (description |
| 1222 | "Makepasswd is a program that generates pseudo-random passwords of a |
| 1223 | desired length. It can also generate their corresponding hashes for a given |
| 1224 | encryption algorithm if so desired.") |
| 1225 | (home-page "https://github.com/khorben/makepasswd") |
| 1226 | (license license:gpl3)))) |
| 1227 | |
| 1228 | (define-public pass-tomb |
| 1229 | (package |
| 1230 | (name "pass-tomb") |
| 1231 | (version "1.2") |
| 1232 | (source |
| 1233 | (origin |
| 1234 | (method git-fetch) |
| 1235 | (uri (git-reference |
| 1236 | (url "https://github.com/roddhjav/pass-tomb") |
| 1237 | (commit (string-append "v" version)))) |
| 1238 | (file-name (git-file-name name version)) |
| 1239 | (sha256 |
| 1240 | (base32 "1qj7vx7svk1ljwihj3kv310k17mafnf919n30n4qn1yxmmsvj924")))) |
| 1241 | (build-system gnu-build-system) |
| 1242 | (arguments |
| 1243 | `(#:make-flags |
| 1244 | (let ((out (assoc-ref %outputs "out"))) |
| 1245 | (list (string-append "PREFIX=" out) |
| 1246 | (string-append "BASHCOMPDIR=" out "/etc/bash_completion.d"))) |
| 1247 | #:test-target "tests" |
| 1248 | ;; tests are very dependent on system state (swap partition) and require |
| 1249 | ;; access to /tmp/zsh which is not in the build container. |
| 1250 | #:tests? #f |
| 1251 | #:phases |
| 1252 | (modify-phases %standard-phases |
| 1253 | (add-after 'unpack 'set-tomb-path |
| 1254 | (lambda* (#:key inputs #:allow-other-keys) |
| 1255 | (let ((tomb (assoc-ref inputs "tomb"))) |
| 1256 | (substitute* "tomb.bash" |
| 1257 | ((":-tomb") |
| 1258 | (string-append ":-" tomb "/bin/tomb")))))) |
| 1259 | (delete 'configure)))) |
| 1260 | (inputs |
| 1261 | `(("tomb" ,tomb))) |
| 1262 | (home-page "https://github.com/roddhjav/pass-tomb") |
| 1263 | (synopsis "Pass extension keeping the tree of passwords encrypted") |
| 1264 | (description "Pass-tomb provides a convenient solution to put your |
| 1265 | password store in a Tomb and then keep your password tree encrypted when you |
| 1266 | are not using it. It uses the same GPG key to encrypt passwords and tomb, |
| 1267 | therefore you don't need to manage more key or secret. Moreover, you can ask |
| 1268 | pass-tomb to automatically close your store after a given time.") |
| 1269 | (license license:gpl3+))) |