[Python-Dev] Re: hook for standalone executable
Damien Morton
damien-morton at nyc.rr.com
Thu Aug 14 15:55:37 EDT 2003
Why not activate the hook if a magic cookie has been appended to the
executable. This cookie would flag that a zip archive had been appended
to the executable, and would incorporate information as to the length of
the archive.
The file layout would then be:
<executable> <zip header> <zip archive> <zip length> <zip cookie>
To test for the existance of a zip archive, youd would do the following:
If ((exe[-4:] == <zip cookie>) && (exe[exe[-8:-4]:] == <zip header>))
More information about the Python-Dev
mailing list