summary refs log tree commit diff
path: root/pkgs/applications/misc/vanitygen/default.nix
blob: 462b6d0e57bb2e32fa4b25cf0e558b350216a90d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
{ fetchgit, stdenv, openssl, pcre }:

stdenv.mkDerivation rec {
  version = "0.21";
  name = "vanitygen-${version}";

  src = fetchgit {
    url = "https://github.com/samr7/vanitygen";
    rev = "refs/tags/${version}";
    sha256  = "1vzfv74hhiyrrpvjca8paydx1ashgbgn5plzrx4swyzxy1xkamah";
  };

  buildInputs = [ openssl pcre ];

  installPhase = ''
    mkdir -p $out/bin
    cp vanitygen $out/bin
    cp keyconv $out/bin/vanitygen-keyconv
  '';

  meta = {
      description = "Bitcoin vanity address generator";
      longDescription= ''
        Vanitygen can search for exact prefixes or regular expression
        matches, so you can generate Bitcoin addresses that starts
        with the needed mnemonic.

        Vanitygen can generate regular bitcoin addresses, namecoin
        addresses, and testnet addresses.

        When searching for exact prefixes, vanitygen will ensure that
        the prefix is possible, will provide a difficulty estimate,
        and will run about 30% faster.
      '';
      homepage = https://github.com/samr7/vanitygen;
      license = stdenv.lib.licenses.agpl3;
      platforms = stdenv.lib.platforms.all;
  };
}