lol
1{
2 lib,
3 stdenv,
4 fetchFromGitHub,
5 python3,
6}:
7
8python3.pkgs.buildPythonApplication rec {
9 pname = "baddns";
10 version = "1.11.236";
11 pyproject = true;
12
13 src = fetchFromGitHub {
14 owner = "blacklanternsecurity";
15 repo = "baddns";
16 tag = version;
17 hash = "sha256-GaUZ3WLIxACsdSe262Ie1R1m8K/5X2ILGs6PWm/poUI=";
18 };
19
20 pythonRelaxDeps = true;
21
22 build-system = with python3.pkgs; [
23 poetry-core
24 poetry-dynamic-versioning
25 ];
26
27 dependencies = with python3.pkgs; [
28 colorama
29 dnspython
30 httpx
31 python-dateutil
32 python-whois
33 pyyaml
34 setuptools
35 tldextract
36 ];
37
38 nativeCheckInputs = with python3.pkgs; [
39 mock
40 pyfakefs
41 pytest-asyncio
42 pytest-httpx
43 pytest-mock
44 pytestCheckHook
45 ];
46
47 pythonImportsCheck = [ "baddns" ];
48
49 disabledTests = [
50 # Tests require network access
51 "test_cli_cname_http"
52 "test_cli_direct"
53 "test_cli_validation_customnameservers_valid"
54 "test_cname_http_bigcartel_match"
55 "test_cname_whois_unregistered_baddata"
56 "test_cname_whois_unregistered_match"
57 "test_cname_whois_unregistered_missingdata"
58 "test_modules_customnameservers"
59 "test_references_cname_css"
60 "test_references_cname_js"
61 ];
62
63 meta = {
64 description = "Tool to check subdomains for subdomain takeovers and other DNS issues";
65 homepage = "https://github.com/blacklanternsecurity/baddns/";
66 changelog = "https://github.com/blacklanternsecurity/baddns/releases/tag/${src.tag}";
67 license = lib.licenses.gpl3Only;
68 maintainers = with lib.maintainers; [ fab ];
69 mainProgram = "baddns";
70 };
71}