offlinemark / poet

[unmaintained] Post-exploitation tool
MIT License
183 stars 55 forks source link

restructure #42

Closed offlinemark closed 9 years ago

offlinemark commented 9 years ago

right now we just have a client script and a server script, which works well enough, except for that there's actually shared code between them (the socket communications code) that up to this point has been manually kept in sync. it would be cool to separate that socket code into a separate file that is imported by the client and server. but at least for the client, it's important to have a single executable of some sort to ship over to the target. since i don't think there's a way to compile multiple python files into one, we can use this trick (http://blog.ablepear.com/2012/10/bundling-python-files-into-stand-alone.html) where we zip up multiple python files and include a __main__.py which gets executed when the zip file is fed into the python interpreter. so write a Makefile to creates said zip file when "compiling" poet. of course that would mean that on the client it would be required to run poet via python poet.zip rather than executing it traditionally (./client.py). However there could be some sort of stage zero dropper script that downloads the poet zip file from somewhere on the internet and executes it the proper way, using python.