summary refs log tree commit diff
path: root/pkgs/tools/networking/wifite2/default.nix
blob: 2333408f07818a40a6de372987e446864252e4cb (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
{ stdenv, lib, fetchFromGitHub, python3, aircrack-ng, wireshark-cli, reaverwps-t6x, cowpatty, hashcat, hcxtools, which }:

python3.pkgs.buildPythonApplication rec {
  version = "2.2.5";
  pname = "wifite2";

  src = fetchFromGitHub {
    owner = "derv82";
    repo = "wifite2";
    rev = version;
    sha256 = "1hfy90wf2bjg0z8rbs8cfhhvz78pzg2c6nj0zksal42mb6b5cjdp";
  };

  propagatedBuildInputs = [
    aircrack-ng
    wireshark-cli
    reaverwps-t6x
    cowpatty
    hashcat
    hcxtools
    which
  ];

  postFixup = let
    sitePackagesDir = "$out/lib/python3.${lib.versions.minor python3.version}/site-packages";
  in ''
    mv ${sitePackagesDir}/wifite/__main__.py ${sitePackagesDir}/wifite/wifite.py
  '';

  # which is not found
  doCheck = false;

  meta = with stdenv.lib; {
    homepage = "https://github.com/derv82/wifite2";
    description = "Rewrite of the popular wireless network auditor, wifite";
    license = licenses.gpl2;
    platforms = platforms.linux;
    maintainers = with maintainers; [ lassulus ];
  };
}