about summary refs log tree commit diff
path: root/nixpkgs/pkgs/tools/security/knockpy/default.nix
blob: 89eda45322c7f3c08be7bbcf05286149fcf6d1ae (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
40
{ lib
, fetchFromGitHub
, python3
}:

python3.pkgs.buildPythonApplication rec {
  pname = "knockpy";
  version = "5.0.0";
  disabled = python3.pythonOlder "3.6";

  src = fetchFromGitHub {
    owner = "guelfoweb";
    repo = "knock";
    rev = version;
    sha256 = "1h7sibdxx8y53xm1wydyng418n4j6baiys257msq03cs04jlm7h9";
  };

  propagatedBuildInputs = with python3.pkgs; [
    beautifulsoup4
    colorama
    requests
  ];

  postPatch = ''
    # https://github.com/guelfoweb/knock/pull/95
    substituteInPlace setup.py \
      --replace "bs4" "beautifulsoup4"
  '';

  # Project has no tests
  doCheck = false;
  pythonImportsCheck = [ "knockpy" ];

  meta = with lib; {
    description = "Tool to scan subdomains";
    homepage = "https://github.com/guelfoweb/knock";
    license = with licenses; [ gpl3Only ];
    maintainers = with maintainers; [ fab ];
  };
}