跳转到主要内容

围绕NUCLEI功能性的Python包装器。

项目描述

NUCLEI

Checked with mypy Code style: black Imports: isort

此仓库由CEMS BV创建,并帮助用户访问和处理对NUCLEI环境的API调用。

安装

要安装此包,包括NucleiClient库及其依赖项,请运行

pip install cems-nuclei[client]

如果您不需要NucleiClient库(例如,仅使用纯请求),请运行以跳过安装

pip install cems-nuclei

环境变量

要使用nuclei,请将以下环境变量添加到您的环境中。或者在被询问时提供它们。

* NUCLEI_TOKEN
    - Your NUCLEI user token

您可以在NUCLEI上获取您的NUCLEI_TOKEN。转到personal-access-tokens并创建一个新的用户令牌。

贡献

环境

我们建议使用Python3.9和一个干净的虚拟环境(使用virtualenvconda)进行开发,从requirements.txt文件中安装依赖项。

在Linux上使用virtualenvpip安装依赖项的示例

python -m venv .env
source activate .env/bin/activate
python -m pip install --upgrade pip setuptools
pip install -r requirements.txt
pip install -e .

文档

构建文档

python -m pip install --upgrade pip setuptools
pip install -r requirements.txt
pip install .
sphinx-build -b html docs public

注意:您需要设置NUCLEI_TOKEN环境变量。您可以在以下网址获取您的令牌:https://cemsbv.crux-nuclei.com

格式

我们使用black和isort来格式化代码。

black --config "pyproject.toml" src/nuclei tests
isort --settings-path "pyproject.toml" src/nuclei tests

代码检查

为了保持代码质量,我们使用GitHub超级代码检查工具。

要本地运行代码检查,从根目录运行run_super_linters.shbash脚本。

单元测试

使用覆盖率测试软件。

python -m pip install --upgrade pip setuptools
pip install -r requirements.txt
pip install .
coverage run -m pytest

需求

需求由pip-compile自动生成,使用python 3.9。

pip-compile --extra=test --extra=docs --extra=lint --extra=client --output-file=requirements.txt pyproject.toml

要更新定义范围内的需求,运行

pip-compile --upgrade --extra=test --extra=docs --extra=lint --extra=client --output-file=requirements.txt pyproject.toml

项目详情


下载文件

下载您平台的文件。如果您不确定选择哪个,请了解有关安装包的更多信息。

源代码分发

cems_nuclei-1.0.1.tar.gz (11.7 kB 查看哈希值)

上传时间 源代码

构建分发

cems_nuclei-1.0.1-py3-none-any.whl (10.5 kB 查看哈希值)

上传时间 Python 3

由以下支持

AWS AWS 云计算和安全赞助商 Datadog Datadog 监控 Fastly Fastly CDN Google Google 下载分析 Microsoft Microsoft PSF 赞助商 Pingdom Pingdom 监控 Sentry Sentry 错误记录 StatusPage StatusPage 状态页面