1{ lib
2, fetchFromGitHub
3, python3
4}:
5
6python3.pkgs.buildPythonApplication rec {
7 pname = "regexploit";
8 version = "1.0.0";
9
10 disabled = python3.pythonOlder "3.8";
11
12 src = fetchFromGitHub {
13 owner = "doyensec";
14 repo = pname;
15 rev = "v${version}";
16 sha256 = "0z3fghsyw0ll36in7ihc0qi3gy7mqi6cw1mi8m8c8xb1nlwpfr0y";
17 };
18
19 propagatedBuildInputs = with python3.pkgs; [
20 pyyaml
21 ];
22
23 nativeCheckInputs = with python3.pkgs; [
24 pytestCheckHook
25 ];
26
27 pythonImportsCheck = [ "regexploit" ];
28
29 meta = with lib; {
30 description = "Tool to find regular expressions which are vulnerable to ReDoS";
31 homepage = "https://github.com/doyensec/regexploit";
32 license = with licenses; [ asl20 ];
33 maintainers = with maintainers; [ fab ];
34 };
35}