1{
2 lib,
3 stdenv,
4 arc4,
5 asn1crypto,
6 asn1tools,
7 asyauth,
8 asysocks,
9 buildPythonPackage,
10 cargo,
11 colorama,
12 fetchFromGitHub,
13 iconv,
14 pillow,
15 pyperclip,
16 pythonOlder,
17 rustPlatform,
18 rustc,
19 setuptools,
20 setuptools-rust,
21 tqdm,
22 unicrypto,
23}:
24
25buildPythonPackage rec {
26 pname = "aardwolf";
27 version = "0.2.11";
28 pyproject = true;
29
30 disabled = pythonOlder "3.7";
31
32 src = fetchFromGitHub {
33 owner = "skelsec";
34 repo = "aardwolf";
35 rev = "0586591e948977ca5945252c893ba8f766ff8d28";
36 hash = "sha256-daDxkQ7N0+yS2JOLfXJq4jv+5VQNnwtqIMy2p8j+Sag=";
37 };
38
39 cargoDeps = rustPlatform.fetchCargoVendor {
40 inherit src;
41 sourceRoot = "${src.name}/aardwolf/utils/rlers";
42 name = "${pname}-${version}";
43 hash = "sha256-doBraJQtekrO/ZZV9KFz7BdIgBVVWtQztUS2Gz8dDdA=";
44 };
45
46 cargoRoot = "aardwolf/utils/rlers";
47
48 build-system = [
49 setuptools
50 setuptools-rust
51 ];
52
53 nativeBuildInputs = [
54 rustPlatform.cargoSetupHook
55 cargo
56 rustc
57 ];
58
59 dependencies = [
60 arc4
61 asn1crypto
62 asn1tools
63 asyauth
64 asysocks
65 colorama
66 pillow
67 pyperclip
68 tqdm
69 unicrypto
70 ] ++ lib.optionals (stdenv.hostPlatform.isDarwin) [ iconv ];
71
72 # Module doesn't have tests
73 doCheck = false;
74
75 pythonImportsCheck = [ "aardwolf" ];
76
77 meta = with lib; {
78 description = "Asynchronous RDP protocol implementation";
79 mainProgram = "ardpscan";
80 homepage = "https://github.com/skelsec/aardwolf";
81 changelog = "https://github.com/skelsec/aardwolf/releases/tag/${version}";
82 license = with licenses; [ mit ];
83 maintainers = with maintainers; [ fab ];
84 };
85}