-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathpyproject.toml
138 lines (122 loc) · 4.04 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
[tool.poetry]
name = "crypto-condor"
version = "2025.01.31"
description = "Compliance testing for implementations of cryptographic primitives"
license = "Apache-2.0"
authors = [
"Julio Loayza Meneses <[email protected]>",
"Angèle Bossuat <[email protected]>",
"Dahmun Goudarzi <[email protected]>",
]
readme = "README.md"
homepage = "https://github.com/quarkslab/crypto-condor"
repository = "https://github.com/quarkslab/crypto-condor"
documentation = "https://quarkslab.github.io/crypto-condor/latest/index.html"
keywords = ["cryptography", "compliance"]
include = [
{ path ="crypto_condor/vectors/_aes/dat/*.dat", format = ["sdist", "wheel"] },
{ path ="crypto_condor/vectors/_ECDH/dat/*.dat", format = ["sdist", "wheel"] },
{ path ="crypto_condor/vectors/_ecdsa/dat/*.dat", format = ["sdist", "wheel"] },
{ path ="crypto_condor/vectors/_falcon/dat/*.dat", format = ["sdist", "wheel"] },
{ path ="crypto_condor/vectors/_HMAC/dat/*.dat", format = ["sdist", "wheel"] },
{ path ="crypto_condor/vectors/_mldsa/pb2/*.pb2", format = ["sdist", "wheel"] },
{ path ="crypto_condor/vectors/_mlkem/pb2/*.pb2", format = ["sdist", "wheel"] },
{ path ="crypto_condor/vectors/_rsa/dat/*.dat", format = ["sdist", "wheel"] },
{ path ="crypto_condor/vectors/_sha/dat/*.dat", format = ["sdist", "wheel"] },
{ path ="crypto_condor/primitives/_testu01/examples/excel.dat", format = ["sdist", "wheel"] },
]
exclude = [
"crypto_condor/vectors/_aes/rsp",
"crypto_condor/vectors/_ECDH/src",
"crypto_condor/vectors/_ecdsa/rsp",
"crypto_condor/vectors/_falcon/rsp",
"crypto_condor/vectors/_HMAC/rsp",
"crypto_condor/vectors/_HMAC/wycheproof",
"crypto_condor/vectors/_mldsa/**/*.rsp",
"crypto_condor/vectors/_mlkem/**/*.rsp",
"crypto_condor/vectors/_rsa/rsp",
"crypto_condor/vectors/_sha/rsp",
"crypto_condor/vectors/_sphincs/rsp",
]
[tool.poetry.dependencies]
python = "^3.10"
pycryptodome = "^3.17"
protobuf = "^5.28.3"
typer = { version = "^0.9.0", extras = ["all"] }
cryptography = "^43.0.0"
attrs = "^23.1.0"
cffi = "^1.16.0"
strenum = "^0.4.15"
lief = "^0.14.1"
[tool.poetry.group.dev.dependencies]
black = { extras = ["jupyter"], version = "^24.1.1" }
ruff = "^0.9.2"
pytest = "^7.3.1"
pytest-xdist = { extras = ["psutil"], version = "^3.5.0" }
pytest-cov = "^4.1.0"
mypy = "^1.8.0"
types-cffi = "^1.16.0.20240331"
mypy-protobuf = "^3.6.0"
types-protobuf = "^5.26.0.20240422"
[tool.poetry.group.docs.dependencies]
sphinx = "^7.0.0"
sphinx-autobuild = "^2021.3.14"
furo = "^2023.5.20"
nbsphinx = "^0.9.2"
sphinx-copybutton = "^0.5.2"
tomli = "^2.0.1"
myst-parser = "^2.0.0"
sphinxcontrib-bibtex = "^2.5.0"
enum-tools = { extras = ["sphinx"], version = "^0.11.0" }
sphinx-toolbox = "^3.5.0"
setuptools = "^75.8.0"
[tool.poetry.scripts]
crypto-condor-cli = "crypto_condor.cli.main:app"
[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
[tool.ruff]
# Exclude protobuf-generated classes.
extend-exclude = ["*_pb2.py", "*.pyi", "utils/templates/*", "*.ipynb"]
[tool.ruff.lint]
# Enable flake8-bugbear rules.
select = ["D", "E", "F", "B", "Q", "I"]
# Avoid trying to fix flake8-bugbear (`B`) violations.
unfixable = ["B"]
ignore = [
"D107", # missing docstring in __init__, we add docstrings to the class
]
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.pytest.ini_options]
# Prevent pytest from capturing logs.
addopts = "-p no:logging"
[tool.coverage.run]
source = ["crypto_condor/"]
omit = ["*_pb2.py", "nist_to_proto.py"]
[tool.black]
extend-exclude = '''
(
.*_pb2.py # exclude protobuf generated classes
| nist_to_proto.py # exclude internal script
)
'''
[tool.mypy]
python_version = "3.11"
# warn_return_any = true
# warn_unused_configs = true
exclude = [
"^crypto_condor/resources/wrappers/",
'_import\.py$',
"^utils/templates/",
]
[[tool.mypy.overrides]]
module = ["google"]
ignore_missing_imports = true
[tool.tox]
requires = ["tox>=4.19"]
env_list = ["3.12", "3.11", "3.10"]
[tool.tox.env_run_base]
description = "Run test under {base_python}"
allowlist_externals = ["make"]
commands = [["make", "all"]]