git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #65618 from peterhoeg/p/spwgen

pwgen-secure: init at 0.9.1

commitf46b8a9ef2bc0b00ee044c4699862917ca467535 authorPeter Hoeg <peter@hoeg.com> dateWed 31 Jul 2019, 15:18 (7 years ago) parentf4b9195db5aa01
2 files changed+38
pkgs/tools/security/pwgen-secure/default.nix+36 pkgs/top-level/all-packages.nix+2
pkgs/tools/security/pwgen-secure/default.nixnew file+36
@@ -0,0 +1,36 @@
1+{ lib, python3Packages, fetchFromGitHub }:
2+
3+with python3Packages;
4+
5+buildPythonApplication rec {
6+ pname = "pwgen-secure";
7+ version = "0.9.1";
8+
9+ # it needs `secrets` which was introduced in 3.6
10+ disabled = pythonOlder "3.6";
11+
12+ # GH is newer than Pypi and contains both library *and* the actual program
13+ # whereas Pypi only has the library
14+ src = fetchFromGitHub {
15+ owner = "mjmunger";
16+ repo = "pwgen_secure";
17+ rev = "v${version}";
18+ sha256 = "15md5606hzy1xfhj2lxmc0nvynyrcs4vxa5jdi34kfm31rdklj28";
19+ };
20+
21+ propagatedBuildInputs = [ docopt ];
22+
23+ postInstall = ''
24+ install -Dm755 spwgen.py $out/bin/spwgen
25+ '';
26+
27+ # there are no checks
28+ doCheck = false;
29+
30+ meta = with lib; {
31+ description = "Secure password generation library to replace pwgen";
32+ homepage = "https://github.com/mjmunger/pwgen_secure/";
33+ license = licenses.mit;
34+ maintainers = with maintainers; [ peterhoeg ];
35+ };
36+}
pkgs/top-level/all-packages.nix+2
@@ -5523,6 +5523,8 @@ in
55235523
55245524 pwgen = callPackage ../tools/security/pwgen { };
55255525
5526+ pwgen-secure = callPackage ../tools/security/pwgen-secure { };
5527+
55265528 pwnat = callPackage ../tools/networking/pwnat { };
55275529
55285530 pwndbg = python3Packages.callPackage ../development/tools/misc/pwndbg { };