pdfalyzer 1.16.9__tar.gz → 1.16.10__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of pdfalyzer might be problematic. Click here for more details.

Files changed (48) hide show
  1. pdfalyzer-1.16.10/.pdfalyzer.example +66 -0
  2. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/CHANGELOG.md +4 -0
  3. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/PKG-INFO +3 -7
  4. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/README.md +0 -6
  5. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/config.py +4 -0
  6. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/font_info.py +1 -2
  7. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/helpers/pdf_object_helper.py +1 -0
  8. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/helpers/rich_text_helper.py +1 -3
  9. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/output/layout.py +1 -1
  10. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/output/pdfalyzer_presenter.py +2 -2
  11. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/output/tables/decoding_stats_table.py +4 -0
  12. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/output/tables/stream_objects_table.py +0 -1
  13. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/util/adobe_strings.py +0 -1
  14. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/util/argument_parser.py +4 -1
  15. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pyproject.toml +21 -12
  16. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/LICENSE +0 -0
  17. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/__init__.py +0 -0
  18. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/__main__.py +0 -0
  19. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/binary/binary_scanner.py +1 -1
  20. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/decorators/document_model_printer.py +0 -0
  21. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/decorators/indeterminate_node.py +0 -0
  22. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/decorators/pdf_object_properties.py +0 -0
  23. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/decorators/pdf_tree_node.py +0 -0
  24. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/decorators/pdf_tree_verifier.py +0 -0
  25. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/detection/constants/binary_regexes.py +0 -0
  26. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/detection/constants/javascript_reserved_keywords.py +0 -0
  27. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/detection/javascript_hunter.py +0 -0
  28. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/detection/yaralyzer_helper.py +0 -0
  29. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/helpers/dict_helper.py +0 -0
  30. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/helpers/filesystem_helper.py +0 -0
  31. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/helpers/number_helper.py +0 -0
  32. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/helpers/string_helper.py +0 -0
  33. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/output/character_mapping.py +0 -0
  34. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/output/styles/node_colors.py +0 -0
  35. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/output/styles/rich_theme.py +0 -0
  36. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/output/tables/font_summary_table.py +0 -0
  37. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/output/tables/pdf_node_rich_table.py +0 -0
  38. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/pdf_object_relationship.py +0 -0
  39. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/pdfalyzer.py +0 -0
  40. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/util/debugging.py +0 -0
  41. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/util/exceptions.py +0 -0
  42. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/util/pdf_parser_manager.py +0 -0
  43. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/yara_rules/PDF.yara +0 -0
  44. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/yara_rules/PDF_binary_stream.yara +0 -0
  45. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/yara_rules/__init.py__ +0 -0
  46. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/yara_rules/didier_stevens.yara +0 -0
  47. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/yara_rules/lprat.static_file_analysis.yara +0 -0
  48. {pdfalyzer-1.16.9 → pdfalyzer-1.16.10}/pdfalyzer/yara_rules/pdf_malware.yara +0 -0
@@ -0,0 +1,66 @@
1
+ # If you place a filed called '.pdfalyzer' in your home dir or the current dir environment variables specified
2
+ # in that .pdfalyzer file will be added to the environment each time pdfalyzer is invoked. (See the `dotenv`
3
+ # package for more details.) This file contains environment variables you can place in .pdfalyzer to configure
4
+ # the application above and beyond providing command line options. Useful if you want to permanently
5
+ # configure options you tend to reuse (e.g. '--maximize-width') so you can stop remembering to type them.
6
+ #
7
+ # Almost all of the yaralyzer (yes, you read that right - The Pdfalyzer uses The Yaralyzer for all
8
+ # kinds of backend functionality) command line options can be configured in this file by capitalizing them and
9
+ # prefixing 'YARALYZER'. e.g. to configure the --maximize-width option for every invocation, you would set:
10
+ # YARALYZER_MAXIMIZE_WIDTH=True
11
+ #
12
+ # Note that many of these options are actually configuring the yaralyzer, which is a separate tool leveraged
13
+ # by the Pdfalyzer to actually do the work of finding patterns. More info can be found at
14
+ # https://github.com/michelcrypt4d4mus/yaralyzer
15
+
16
+
17
+
18
+ # Expand the width of the output to the fit the display window (same as the --maximize-width options)
19
+ # YARALYZER_MAXIMIZE_WIDTH=True
20
+
21
+ # yara-python internal options passed through to yara.set_config() as the stack_size and max_match_data arguments
22
+ # YARALYZER_STACK_SIZE=10485760
23
+ # YARALYZER_MAX_MATCH_LENGTH=10737418240
24
+
25
+ # Suppress all PDF binary regex matching/scanning/etc
26
+ # YARALYZER_SUPPRESS_DECODES_TABLE=False
27
+
28
+ # Suppress the display of the table showing the the encoding assessments given by `chardet.detect()`
29
+ # about a particular chunk of binary data. (The most important data in the chardet confidence table is
30
+ # redunandant anyways. Only the low likelihood encodings are hidden from the usef)
31
+ # YARALYZER_SUPPRESS_CHARDET_TABLE=False
32
+ # Minimum confidence to display an encoding in the chardet results table
33
+ # YARALYZER_MIN_CHARDET_CONFIDENCE=2.0
34
+
35
+ # Configure how many bytes before and after any binary data should be included in scans and visualizations
36
+ # YARALYZER_SURROUNDING_BYTES=64
37
+
38
+ # Size thresholds (in bytes) under/over which pdfalyzer will NOT make attempts to decode a match.
39
+ # Longer byte sequences are for obvious reasons slower to decode by force.
40
+ # It may feel counterintuitive but larger chunks of random binary are also harder to examine and
41
+ # (in my experience) less likely to be maningful. Consider it - two frontslash characters 20,000 lines apart
42
+ # are more likely to be random than those same frontslashes when placed nearer to each other and
43
+ # in the vicinity of lot of computerized sigils of internet power like `.', `+bacd*?`,. and other regexes.*
44
+ # Keeping the max value number low will do more to affect the speed of the app than ay anything else you
45
+ # can easily configure..
46
+ #
47
+ # YARALYZER_MIN_DECODE_LENGTH=1
48
+ # YARALYZER_MAX_DECODE_LENGTH=256
49
+
50
+ # Directory to write application logs to. Must be an absolute path, not a relative one.
51
+ # These logs are not normally written to a file and the default log level means that the standard behavior
52
+ # is to more or less discard them. Be aware that if you configure this variable a few things will change:
53
+ #
54
+ # 1. Logs WILL NOT be written to STDOUT. They will stream ONLY to files in the configured directory.
55
+ # This is true even with the -D option.
56
+ # 2. The default log_level will be decreased from WARN (extremely spartan) to INFO (fairly verbose).
57
+ # The -D option, which sets the log level to DEBUG, will be respected whether or not
58
+ # YARALYZER_LOG_DIR is configured.
59
+ #
60
+ # YARALYZER_LOG_DIR=/path/to/pdfalyzer/log_dir/
61
+
62
+ # Log level
63
+ # YARALYZER_LOG_LEVEL='INFO'
64
+
65
+ # Path to directory containing Didier Stevens's pdf-parser.py. Only required for extracting binary streams to files.
66
+ # PDFALYZER_PDF_PARSER_PY_PATH=/path/to/pdfparserdotpy/
@@ -1,5 +1,9 @@
1
1
  # NEXT RELEASE
2
2
 
3
+ ### 1.16.10
4
+ * Add `Environment :: Console` and `Programming Language :: Python` to pypi classifiers
5
+ * Add `.pdfalyzer.example` to PyPi package
6
+
3
7
  ### 1.16.9
4
8
  * Add `Development Status :: 5 - Production/Stable` to pypi classifiers
5
9
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: pdfalyzer
3
- Version: 1.16.9
3
+ Version: 1.16.10
4
4
  Summary: A PDF analysis toolkit. Scan a PDF with relevant YARA rules, visualize its inner tree-like data structure in living color (lots of colors), force decodes of suspicious font binaries, and more.
5
5
  Home-page: https://github.com/michelcrypt4d4mus/pdfalyzer
6
6
  License: GPL-3.0-or-later
@@ -9,8 +9,10 @@ Author: Michel de Cryptadamus
9
9
  Author-email: michel@cryptadamus.com
10
10
  Requires-Python: >=3.9.2,<4.0.0
11
11
  Classifier: Development Status :: 5 - Production/Stable
12
+ Classifier: Environment :: Console
12
13
  Classifier: Intended Audience :: Information Technology
13
14
  Classifier: License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)
15
+ Classifier: Programming Language :: Python
14
16
  Classifier: Programming Language :: Python :: 3
15
17
  Classifier: Programming Language :: Python :: 3.10
16
18
  Classifier: Programming Language :: Python :: 3.11
@@ -304,12 +306,6 @@ These are the naming conventions at play in The Pdfalyzer code base:
304
306
  * [`PyPDF` documentation](https://pypdf.readthedocs.io/en/stable/) (latest is 4.x or something so these are the relevant docs for `pdfalyze`)
305
307
 
306
308
 
307
- # TODO
308
- * Highlight decodes with a lot of Javascript keywords
309
- * https://github.com/mandiant/flare-floss (https://github.com/mandiant/flare-floss/releases/download/v2.1.0/floss-v2.1.0-linux.zip)
310
- * https://github.com/1Project/Scanr/blob/master/emulator/emulator.py
311
-
312
-
313
309
  [^1]: The official Adobe PDF specification calls this tree the PDF's "logical structure", which is a good example of nomenclature that does not help those who see it understand anything about what is being described. I can forgive them given that they named this thing back in the 80s, though it's a good example of why picking good names for things at the beginning is so important.
314
310
 
315
311
  [^2]: An exception will be raised if there's any issue placing a node while parsing or if there are any nodes not reachable from the root of the tree at the end of parsing. If there are no exceptions then all internal PDF objects are guaranteed to exist in the tree except in these situations when warnings will be printed:
@@ -277,12 +277,6 @@ These are the naming conventions at play in The Pdfalyzer code base:
277
277
  * [`PyPDF` documentation](https://pypdf.readthedocs.io/en/stable/) (latest is 4.x or something so these are the relevant docs for `pdfalyze`)
278
278
 
279
279
 
280
- # TODO
281
- * Highlight decodes with a lot of Javascript keywords
282
- * https://github.com/mandiant/flare-floss (https://github.com/mandiant/flare-floss/releases/download/v2.1.0/floss-v2.1.0-linux.zip)
283
- * https://github.com/1Project/Scanr/blob/master/emulator/emulator.py
284
-
285
-
286
280
  [^1]: The official Adobe PDF specification calls this tree the PDF's "logical structure", which is a good example of nomenclature that does not help those who see it understand anything about what is being described. I can forgive them given that they named this thing back in the 80s, though it's a good example of why picking good names for things at the beginning is so important.
287
281
 
288
282
  [^2]: An exception will be raised if there's any issue placing a node while parsing or if there are any nodes not reachable from the root of the tree at the end of parsing. If there are no exceptions then all internal PDF objects are guaranteed to exist in the tree except in these situations when warnings will be printed:
@@ -1,3 +1,7 @@
1
+ """
2
+ PdfalyzerConfig object holds the unification of configuration options parsed from the command line
3
+ as well as those set by environment variables and/or a .pdfalyzer file.
4
+ """
1
5
  import importlib.resources
2
6
  from argparse import Namespace
3
7
  from os import environ, pardir, path
@@ -2,7 +2,6 @@
2
2
  Unify font information spread across a bunch of PdfObjects (Font, FontDescriptor,
3
3
  and FontFile) into a single class.
4
4
  """
5
-
6
5
  from pypdf._cmap import build_char_map, prepare_cm
7
6
  from pypdf.generic import IndirectObject, PdfObject
8
7
  from rich.text import Text
@@ -11,9 +10,9 @@ from yaralyzer.util.logging import log
11
10
 
12
11
  from pdfalyzer.binary.binary_scanner import BinaryScanner
13
12
  from pdfalyzer.output.character_mapping import print_character_mapping, print_prepared_charmap
14
- from pdfalyzer.output.tables.font_summary_table import font_summary_table
15
13
  from pdfalyzer.output.layout import print_section_subheader
16
14
  from pdfalyzer.output.styles.node_colors import get_label_style
15
+ from pdfalyzer.output.tables.font_summary_table import font_summary_table
17
16
  from pdfalyzer.util.adobe_strings import (FONT, FONT_DESCRIPTOR, FONT_FILE, FONT_LENGTHS, RESOURCES,
18
17
  SUBTYPE, TO_UNICODE, TYPE, W, WIDTHS)
19
18
 
@@ -20,6 +20,7 @@ def does_list_have_any_references(_list) -> bool:
20
20
 
21
21
 
22
22
  def _sort_pdf_object_refs(refs: List[PdfObjectRelationship]) -> List[PdfObjectRelationship]:
23
+ """Sort a list of PdfObjectRelationship objects by their to_obj's idnum. Only used by pytest."""
23
24
  return sorted(refs, key=lambda ref: ref.to_obj.idnum)
24
25
 
25
26
 
@@ -1,13 +1,11 @@
1
1
  """
2
- Functions for miscellaneous Rich text/string operations.
2
+ Functions for miscellaneous Rich text/string pretty printing operations.
3
3
  """
4
4
  from typing import List, Union
5
5
 
6
6
  from pypdf.generic import PdfObject
7
7
  from rich.console import Console
8
- from rich.highlighter import RegexHighlighter, JSONHighlighter
9
8
  from rich.text import Text
10
- from yaralyzer.output.rich_console import console
11
9
 
12
10
  from pdfalyzer.helpers.pdf_object_helper import pypdf_class_name
13
11
  from pdfalyzer.output.styles.node_colors import get_label_style, get_class_style_italic
@@ -1,5 +1,5 @@
1
1
  """
2
- Methods to help with the design of the output
2
+ Methods to help with the formatting of the output tables, headers, panels, etc.
3
3
  """
4
4
  from rich import box
5
5
  from rich.padding import Padding
@@ -23,9 +23,9 @@ from pdfalyzer.detection.yaralyzer_helper import get_bytes_yaralyzer, get_file_y
23
23
  from pdfalyzer.helpers.string_helper import pp
24
24
  from pdfalyzer.output.layout import (print_fatal_error_panel, print_section_header, print_section_subheader,
25
25
  print_section_sub_subheader)
26
+ from pdfalyzer.output.tables.decoding_stats_table import build_decoding_stats_table
26
27
  from pdfalyzer.output.tables.pdf_node_rich_table import generate_rich_tree, get_symlink_representation
27
28
  from pdfalyzer.output.tables.stream_objects_table import stream_objects_table
28
- from pdfalyzer.output.tables.decoding_stats_table import build_decoding_stats_table
29
29
  from pdfalyzer.pdfalyzer import Pdfalyzer
30
30
  from pdfalyzer.util.adobe_strings import *
31
31
 
@@ -91,7 +91,6 @@ class PdfalyzerPresenter:
91
91
  2. Check for (and force decode) dangerous PDF instructions like /JavaScript and /OpenAction
92
92
  3. Check for (and force decode) any BOMs (byte order marks)
93
93
  4. Check for (and force decode) any sequences of bytes between quotes
94
-
95
94
  """
96
95
  print_section_header(f'Binary Stream Analysis / Extraction')
97
96
  console.print(self._stream_objects_table())
@@ -109,6 +108,7 @@ class PdfalyzerPresenter:
109
108
  log.warning(msg)
110
109
  node_stream_bytes = node_stream_bytes.encode()
111
110
 
111
+ console.line()
112
112
  print_section_subheader(f"{escape(str(node))} Summary and Analysis", style=f"{BYTES_HIGHLIGHT} reverse")
113
113
  binary_scanner = BinaryScanner(node_stream_bytes, node)
114
114
  console.print(bytes_hashes_table(binary_scanner.bytes))
@@ -1,3 +1,6 @@
1
+ """
2
+ Helper functions for building a table that summarizes the decoding attempts made on binary data.
3
+ """
1
4
  from numbers import Number
2
5
 
3
6
  from rich.table import Table
@@ -13,6 +16,7 @@ NOT_FOUND_MSG = Text('(not found)', style='grey.dark_italic')
13
16
  REGEX_SUBTABLE_COLS = ['Metric', 'Value']
14
17
  DECODES_SUBTABLE_COLS = ['Encoding', '#', 'Decoded', '#', 'Forced', '#', 'Failed']
15
18
 
19
+
16
20
  def build_decoding_stats_table(scanner: 'BinaryScanner') -> Table:
17
21
  """Diplay aggregate results on the decoding attempts we made on subsets of scanner.bytes"""
18
22
  stats_table = _new_decoding_stats_table(scanner.label.plain if scanner.label else '')
@@ -1,7 +1,6 @@
1
1
  """
2
2
  Build a rich table to show the sizes of embedded streams.
3
3
  """
4
-
5
4
  from typing import List
6
5
 
7
6
  from rich.table import Table
@@ -1,7 +1,6 @@
1
1
  """
2
2
  String constants specified in the Adobe specs for PDFs, fonts, etc.
3
3
  """
4
-
5
4
  from pypdf.constants import (CatalogDictionary, ImageAttributes, PageAttributes,
6
5
  PagesAttributes, Resources)
7
6
 
@@ -1,5 +1,8 @@
1
+ """
2
+ Parse command line arguments for pdfalyzer and construct the PdfalyzerConfig object.
3
+ """
1
4
  import sys
2
- from argparse import ArgumentError, ArgumentParser, Namespace
5
+ from argparse import ArgumentParser, Namespace
3
6
  from collections import namedtuple
4
7
  from functools import partial, update_wrapper
5
8
  from importlib.metadata import version
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "pdfalyzer"
3
- version = "1.16.9"
3
+ version = "1.16.10"
4
4
  description = "A PDF analysis toolkit. Scan a PDF with relevant YARA rules, visualize its inner tree-like data structure in living color (lots of colors), force decodes of suspicious font binaries, and more."
5
5
  authors = ["Michel de Cryptadamus <michel@cryptadamus.com>"]
6
6
  license = "GPL-3.0-or-later"
@@ -32,8 +32,10 @@ keywords = [
32
32
 
33
33
  classifiers = [
34
34
  "Development Status :: 5 - Production/Stable",
35
+ "Environment :: Console",
35
36
  "Intended Audience :: Information Technology",
36
37
  "License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)",
38
+ "Programming Language :: Python",
37
39
  "Topic :: Artistic Software",
38
40
  "Topic :: Security",
39
41
  "Topic :: Scientific/Engineering :: Visualization",
@@ -41,40 +43,47 @@ classifiers = [
41
43
 
42
44
  include = [
43
45
  "CHANGELOG.md",
44
- "LICENSE"
46
+ "LICENSE",
47
+ ".pdfalyzer.example"
45
48
  ]
46
49
 
47
50
  packages = [
48
51
  { include = "pdfalyzer" }
49
52
  ]
50
53
 
51
- [tool.poetry.urls]
52
- Changelog = "https://github.com/michelcrypt4d4mus/pdfalyzer/blob/master/CHANGELOG.md"
53
-
54
-
55
- [tool.poetry.scripts]
56
- combine_pdfs = 'pdfalyzer:combine_pdfs'
57
- pdfalyze = 'pdfalyzer:pdfalyze'
58
- pdfalyzer_show_color_theme = 'pdfalyzer:pdfalyzer_show_color_theme'
59
-
60
54
 
55
+ # Dependencies
61
56
  [tool.poetry.dependencies]
62
57
  python = "^3.9.2"
63
58
  anytree = "~=2.13"
64
59
  pypdf = "^5.9.0"
65
60
  yaralyzer = "^1.0.4"
66
61
 
67
-
62
+ # Dev dependencies
68
63
  [tool.poetry.group.dev.dependencies]
69
64
  pytest = "^7.1.2"
70
65
  pytest-skip-slow = "^0.0.3"
71
66
 
72
67
 
68
+ # Scripts
69
+ [tool.poetry.scripts]
70
+ combine_pdfs = 'pdfalyzer:combine_pdfs'
71
+ pdfalyze = 'pdfalyzer:pdfalyze'
72
+ pdfalyzer_show_color_theme = 'pdfalyzer:pdfalyzer_show_color_theme'
73
+
74
+
75
+ # URLs for PyPi page
76
+ [tool.poetry.urls]
77
+ Changelog = "https://github.com/michelcrypt4d4mus/pdfalyzer/blob/master/CHANGELOG.md"
78
+
79
+
80
+ # Poetry build system
73
81
  [build-system]
74
82
  requires = ["poetry-core>=1.0.0"]
75
83
  build-backend = "poetry.core.masonry.api"
76
84
 
77
85
 
86
+ # Pytest configuration
78
87
  [tool.pytest.ini_options]
79
88
  addopts = [
80
89
  "--import-mode=importlib",
File without changes
@@ -12,8 +12,8 @@ from yaralyzer.decoding.bytes_decoder import BytesDecoder
12
12
  from yaralyzer.encoding_detection.character_encodings import BOMS
13
13
  from yaralyzer.helpers.bytes_helper import hex_string, print_bytes
14
14
  from yaralyzer.helpers.string_helper import escape_yara_pattern
15
- from yaralyzer.output.rich_console import BYTES_NO_DIM, console, console_width
16
15
  from yaralyzer.output.regex_match_metrics import RegexMatchMetrics
16
+ from yaralyzer.output.rich_console import BYTES_NO_DIM, console, console_width
17
17
  from yaralyzer.yara.yara_rule_builder import HEX, REGEX, safe_label
18
18
  from yaralyzer.yaralyzer import Yaralyzer
19
19
  from yaralyzer.util.logging import log