You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If a PDF is given with hex characters (for example obfuscated JS tags like /JavaScript --> /#4AavaScript), the following error is encountered:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/worker/venv/lib/python3.10/site-packages/pdfid/pdfid.py", line 1096, in PDFiDMain
ProcessFile(filename, options, plugins, list_of_dict["reports"], disarmed_buffers["buffers"])
File "/home/worker/venv/lib/python3.10/site-packages/pdfid/pdfid.py", line 819, in ProcessFile
PDFID2Dict(xmlDoc, options.nozero, options.force, list_of_dict)
File "/home/worker/venv/lib/python3.10/site-packages/pdfid/pdfid.py", line 698, in PDFID2Dict
filename_dict['%s_hexcode_count' % name] = int(node.getAttribute('HexcodeCount'))
NameError: name 'name' is not defined
The bit of code responsible for this is in the function PDFID2Dict here where in line 698 it references a variable name that does not exist within the scope of the function (or anywhere else for that matter):
If a PDF is given with hex characters (for example obfuscated JS tags like
/JavaScript
-->/#4AavaScript
), the following error is encountered:The bit of code responsible for this is in the function
PDFID2Dict
here where in line 698 it references a variablename
that does not exist within the scope of the function (or anywhere else for that matter):pdfid/pdfid/pdfid.py
Lines 683 to 720 in f7674ff
I cannot provide a fix since I do not know what
name
is supposed to be in the first place. If anyone can help, that would be much appreciated. :)The text was updated successfully, but these errors were encountered: