extremecoders-re / pyinstxtractor

PyInstaller Extractor
GNU General Public License v3.0
2.82k stars 604 forks source link

Improve: make the pattern searching match the way of pyinstaller. #26

Closed Ai-Himmel closed 3 years ago

Ai-Himmel commented 3 years ago

The searching algorithm used now is fetch the magic pattern by fixed offset from the end of file. But according the source code of pyinstaller it should be searching from end to front, and I found some sample which added extra overlay to CArchive and stil works. So I rewrite some code to match the original algorithm. related issue: https://github.com/extremecoders-re/pyinstxtractor/issues/25

extremecoders-re commented 3 years ago

Thanks for the PR. However the file doesn't run with the changes you've made. For example, the checkFile function has been removed, but there is a call to the function from main.

As such I've gone ahead and implemented the changes in a different way. Thanks for your contribution! Closing the PR.