Frank Poz
Frank Poz
The other part of my modification only matters when the Rich header has been tampered with or replaced. The search for the PE header is the first attempt to find...
I half agree with Wes. I'll change my PR to search from 0x80 to ```pe.NT_HEADERS.get_file_offset()```, which is what pefile should be doing instead of searching through to the OPTIONAL_HEADER. If...
Latest release of pefile makes this much easier. Updated the code to use the clear data exposed by pefile.
should also fix #55
I suggest checking and using the value from: ``` python pe.OPTIONAL_HEADER.DATA_DIRECTORY[pefile.DIRECTORY_ENTRY['IMAGE_DIRECTORY_ENTRY_SECURITY']].Size ``` In theory, nothing should come after the digital signature, but in practice it sometimes occurs.