Skip to content

Commit 4392def

Browse files
author
ashariyar
committed
IndirectObject style is light_coral
1 parent 2361b00 commit 4392def

7 files changed

+1420
-1419
lines changed

pdfalyzer/output/highlighter.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@
1515
PYPDF_LOG_PFX_PATTERN = r"\(pypdf\)"
1616

1717
# Styles
18-
CHILD_STYLE = "orange3 bold"
18+
CHILD_STYLE = 'orange3 bold'
19+
INDIRECT_OBJ_STYLE = 'light_coral'
1920
PARENT_STYLE = 'violet'
2021
PDF_ARRAY_STYLE = 'color(143)' # color(120)
2122
PDF_DICTIONARY_STYLE = 'color(64)'
@@ -63,7 +64,7 @@
6364
"child": CHILD_STYLE,
6465
"dictionary_obj": f"{PDF_DICTIONARY_STYLE} italic",
6566
"indeterminate": 'bright_black',
66-
"indirect_object": 'light_coral',
67+
"indirect_object": INDIRECT_OBJ_STYLE,
6768
"node_type": 'honeydew2',
6869
"parent": PARENT_STYLE,
6970
"pypdf_line": "dim",

pdfalyzer/output/theme.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@
1717
from yaralyzer.output.theme import BYTES_NO_DIM, YARALYZER_THEME_DICT
1818
from yaralyzer.util.logging import log_console
1919

20-
from pdfalyzer.output.highlighter import (CHILD_STYLE, LOG_HIGHLIGHT_PATTERNS, LOG_HIGHLIGHT_STYLES, PARENT_STYLE,
21-
PDF_ARRAY_STYLE, PDF_DICTIONARY_STYLE, LogHighlighter, PdfHighlighter)
20+
from pdfalyzer.output.highlighter import (CHILD_STYLE, INDIRECT_OBJ_STYLE, LOG_HIGHLIGHT_PATTERNS,
21+
LOG_HIGHLIGHT_STYLES, PARENT_STYLE, PDF_ARRAY_STYLE, PDF_DICTIONARY_STYLE, LogHighlighter, PdfHighlighter)
2222
from pdfalyzer.util import adobe_strings
2323
from pdfalyzer.util.helpers.collections_helper import prefix_keys, safe_json
2424
from pdfalyzer.util.helpers.rich_helper import vertically_padded_panel
@@ -63,7 +63,7 @@
6363
}
6464

6565
PDF_OBJ_TYPE_STYLES = [
66-
ClassStyle(IndirectObject, 'color(225)'),
66+
ClassStyle(IndirectObject, INDIRECT_OBJ_STYLE),
6767
ClassStyle(ByteStringObject, YARALYZER_THEME_DICT['bytes.title']),
6868
ClassStyle(EncodedStreamObject, YARALYZER_THEME_DICT['bytes']),
6969
ClassStyle(StreamObject, BYTES_NO_DIM),

tests/fixtures/rendered/SF424_page2.pdf.rich_table_tree.txt

Lines changed: 321 additions & 321 deletions
Large diffs are not rendered by default.

tests/fixtures/rendered/Type1_Acrobat_Font_Explanation.pdf.rich_table_tree.txt

Lines changed: 65 additions & 65 deletions
Large diffs are not rendered by default.

tests/fixtures/rendered/Type1_Acrobat_Font_Explanation.pdf.rich_table_tree__scannedby_additional_yara_rules.yara.txt

Lines changed: 65 additions & 65 deletions
Large diffs are not rendered by default.

tests/fixtures/rendered/Type1_Acrobat_Font_Explanation.pdf.rich_table_tree__scannedby_additional_yara_rules.yara_customrulesonly.txt

Lines changed: 65 additions & 65 deletions
Large diffs are not rendered by default.

tests/fixtures/rendered/analyzing-malicious-document-files.pdf.rich_table_tree.txt

Lines changed: 898 additions & 898 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)