depot/third_party/nixpkgs/pkgs/tools/security/faraday-agent-dispatcher/default.nix
Default email fa5436e0a7 Project import generated by Copybara.
GitOrigin-RevId: e8057b67ebf307f01bdcc8fba94d94f75039d1f6
2024-06-05 17:53:02 +02:00

83 lines
1.7 KiB
Nix

{ lib
, fetchFromGitHub
, python3
}:
python3.pkgs.buildPythonApplication rec {
pname = "faraday-agent-dispatcher";
version = "3.4.1";
pyproject = true;
src = fetchFromGitHub {
owner = "infobyte";
repo = "faraday_agent_dispatcher";
rev = "refs/tags/${version}";
hash = "sha256-b62WO1+5EWzsTCzeZPX9T+ho8Sig46lH/9dPmGGhPWA=";
};
postPatch = ''
substituteInPlace setup.py \
--replace-fail '"pytest-runner",' ""
'';
pythonRelaxDeps = [
"python-socketio"
];
build-system = with python3.pkgs; [
setuptools-scm
];
nativeBuildInputs = with python3.pkgs; [
pythonRelaxDepsHook
];
dependencies = with python3.pkgs; [
aiohttp
click
faraday-agent-parameters-types
faraday-plugins
itsdangerous
psutil
pytenable
python-gvm
python-owasp-zap-v2-4
python-socketio
pyyaml
requests
syslog-rfc5424-formatter
websockets
];
nativeCheckInputs = with python3.pkgs; [
pytest-asyncio
pytestCheckHook
];
preCheck = ''
export HOME=$(mktemp -d);
'';
disabledTests = [
"test_execute_agent"
"SSL"
];
disabledTestPaths = [
# Tests require a running Docker instance
"tests/plugins-docker/test_executors.py"
];
pythonImportsCheck = [
"faraday_agent_dispatcher"
];
meta = with lib; {
description = "Tool to send result from tools to the Faraday Platform";
homepage = "https://github.com/infobyte/faraday_agent_dispatcher";
changelog = "https://github.com/infobyte/faraday_agent_dispatcher/releases/tag/${version}";
license = licenses.gpl3Only;
maintainers = with maintainers; [ fab ];
mainProgram = "faraday-dispatcher";
};
}