-
Notifications
You must be signed in to change notification settings - Fork 25
Expand file tree
/
Copy pathpyproject.toml
More file actions
134 lines (115 loc) · 3.66 KB
/
Copy pathpyproject.toml
File metadata and controls
134 lines (115 loc) · 3.66 KB
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
[tool.poetry]
name = "pdfalyzer"
version = "1.19.6"
description = "Analyze PDFs with colors (and YARA). Visualize a PDF's inner tree-like data structure, check it against a library of YARA rules, force decodes of suspicious font binaries, and more."
authors = ["Michel de Cryptadamus <michel@cryptadamus.com>"]
license = "GPL-3.0-or-later"
readme = "README.md"
documentation = "https://github.com/michelcrypt4d4mus/pdfalyzer"
homepage = "https://github.com/michelcrypt4d4mus/pdfalyzer"
repository = "https://github.com/michelcrypt4d4mus/pdfalyzer"
classifiers = [
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Intended Audience :: Information Technology",
"License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)",
"Programming Language :: Python",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Topic :: Artistic Software",
"Topic :: Security",
"Topic :: Scientific/Engineering :: Visualization",
]
include = [
"CHANGELOG.md",
"LICENSE",
".pdfalyzer.example"
]
keywords = [
"ascii art",
"binary",
"color",
"cybersecurity",
"DFIR",
"encoding",
"font",
"infosec",
"maldoc",
"malicious pdf",
"malware",
"malware analysis",
"pdf",
"pdfs",
"pdf analysis",
"pypdf",
"threat assessment",
"threat hunting",
"threat intelligence",
"threat research",
"threatintel",
"visualization",
"yara"
]
# TODO: what is this / is it necessary?
packages = [
{ include = "pdfalyzer" }
]
[tool.poetry.urls]
Changelog = "https://github.com/michelcrypt4d4mus/pdfalyzer/blob/master/CHANGELOG.md"
#####################
# Dependencies #
#####################
[tool.poetry.dependencies]
python = "^3.11"
anytree = "~=2.13"
pypdf = "6.6.0"
yaralyzer = "1.3.17"
# The OCR library pytesseract is kinda heavyweight and not required for basic pdfalyzing.
# It's only needed if you want to use The Pdfalyzer's extra tools like extract_pdf_text().
# Install the extra pkgs with one of the commands below depending on your package manager:
# * [poetry] poetry add pdfalyzer[extract]
# * [pip] pip install pdfalyzer[extract]
# Or for local development:
# * [poetry] poetry install --all-extras
# * [pip] pip install .[extract]
# Note for future: Poetry 2.x handles optional dependencies like this:
# [project.optional-dependencies]
# extract = ["PyMuPDF", "pytesseract"]
cairosvg = {version = "^2.8.2", optional = true}
cryptography = {version = "^46.0.3", optional = true}
numpy = {version = ">1.22.3", optional = true}
PyMuPDF = {version = "^1.26.5", optional = true}
pytesseract = {version = "^0.3.13", optional = true}
requests = {version=">2", optional = true}
[tool.poetry.extras]
extract = ["cryptography", "numpy", "PyMuPDF", "pytesseract", "requests"]
img = ["cairosvg"]
[tool.poetry.group.dev.dependencies]
flake8 = "^7.3.0"
pytest = "^7.1.2"
pytest-skip-slow = "^0.0.3"
requests = "^2.32.5"
#############
# Scripts #
#############
[tool.poetry.scripts]
combine_pdfs = 'pdfalyzer:combine_pdfs'
extract_pdf_pages = 'pdfalyzer:extract_pdf_pages'
extract_pdf_text = 'pdfalyzer:extract_pdf_text'
pdfalyzer_install_pdf_parser = 'pdfalyzer:pdfalyzer_install_pdf_parser'
pdfalyze = 'pdfalyzer:pdfalyze'
###############################
# Poetry build system #
###############################
[build-system]
build-backend = "poetry.core.masonry.api"
requires = ["poetry-core>=1.0.0"]
##################
# pytest #
##################
[tool.pytest.ini_options]
addopts = [
"--import-mode=importlib",
"-v",
]