How to create a contextual menu on Windows Explorer for PyInstaller packaging

Package your python application (for Windows and Linux) with just a right-click!

Recently I’ve written a brief post about the packaging of a python script for Linux and Windows on a Linux machine, using PyInstaller and Wine.

Today i want to propose the same process, performed on Windows.


Prerequisites


How

  • Install Python (with Pip) on Windows (get latest build from¬†https://www.python.org/downloads/)
  • Install Python and Pip on Ubuntu (installing pip solve all python dependencies):
    apt install python-pip
  • Install PyInstallter on Windows and Linux:
    pip install pyinstaller

Once the enviroment is correctly configured, you can create the contextual menu:

  • Download this template and save it as .reg file:

https://gist.github.com/andreafortuna/a1fbc701cb739b05131cbf2157ea7e46

  • Modify the file with the correct paths (on lines 15 and 22).
  • Finally, import the .reg file and test the configuration.

Here a brief demo:

 


References

Related posts

  1. How to block Windows 10 telemetry using “hosts” file
  2. Social Engineering in penetration tests: my point of view and my own custom tool
  3. SpiderFoot 3.0: OSINT reconnaissance tool
  4. Playing with the cat (in the command line)
  5. PEpper: a python script to perform malware static analysis on Portable Executable format