#!/usr/bin/env python
from setuptools import setup, find_packages
setup(
name="dohlyzer",
description="Set of tools to capture HTTPS traffic, extract statistical and time-series features from it, and analyze them with a focus on detecting and characterizing DoH (DNS-over-HTTPS) traffic. ",
long_description=open('README.md').read(),
long_description_content_type="text/markdown",
url="https://github.com/ahlashkari/DoHlyzer",
packages=find_packages(exclude=[]),
python_requires=">=3.6",
install_requires=open('requirements.txt').read().split('\n'),
entry_points={
"console_scripts": [
"dohlyzer=meter.dohlyzer:main",
]
},
)
要测试是否可以使用virtualenv,请执行以下操作:
% virtualenv venv
% venv/bin/pip install .
% venv/bin/dohlyzer -h
usage: dohlyzer [-h] (-n INPUT_INTERFACE | -f INPUT_FILE) (-c | -s) output
positional arguments:
output output file name (in flow mode) or directory (in sequence mode)
optional arguments:
-h, help show this help message and exit
-n INPUT_INTERFACE, online INPUT_INTERFACE, interface INPUT_INTERFACE
capture online data from INPUT_INTERFACE
-f INPUT_FILE, offline INPUT_FILE, file INPUT_FILE
capture offline data from INPUT_FILE
-c, csv, flow output flows as csv
-s, json, sequence
output flow segments as json
问题是该代码没有正确构建,因为它认为自己是作为模块安装的,没有提供适当的setup.py/pyproject.toml文件使其可安装
因此,作为一种快速有效的方法,您可以添加一个示例
setup.py
文件,以便安装该工具:要测试是否可以使用virtualenv,请执行以下操作:
或者,您可以全局安装它:
注意:setup.py文件有几个问题,只适用于快速破解,如果您想让它变得干净,我建议您阅读some documentation about it
相关问题 更多 >
编程相关推荐