Merge pull request #48 from wkpark/py3

Python3
This commit is contained in:
Stephen Tong
2022-11-27 19:15:42 -05:00
committed by GitHub
2 changed files with 3 additions and 8 deletions
+2 -3
View File
@@ -36,9 +36,8 @@ The forklib relies on hardcoded offsets that are reverse-engineered from `csrss.
```bash
cd forklib/
# python3 is not supported. Please use python2
python2 -m pip install construct pefile # get dependencies
python2 ./gen_csrss_offsets.py
python -m pip install construct pefile # get dependencies
python ./gen_csrss_offsets.py
cat csrss_offsets.h # check the generated output
```
+1 -5
View File
@@ -9,10 +9,6 @@ if not (sys.maxsize > 2**32) and os.name == 'nt':
print('Sorry, 32-bit python is not supported because of WOW64 redirection. Please use 64-bit python')
raise ValueError('Unsupported python version')
if sys.version_info >= (3, 0):
print("Sorry, python3 isn't supported")
raise ValueError('Unsupported python version')
import os.path
from pefile import PE
from shutil import copyfileobj
@@ -365,7 +361,7 @@ def main():
f.close()
print 'Successfully generated ' + genfile
print('Successfully generated ' + genfile)
if __name__ == "__main__":
main()