calebstewart / pwncat

Fancy reverse and bind shell handler
https://pwncat.readthedocs.io
MIT License
2.61k stars 256 forks source link

[BUG] Missing dependency: base64io #72

Closed Marnick39 closed 3 years ago

Marnick39 commented 3 years ago

Describe the bug When installing on Kali Linux (Debian 5.7.6-1kali2) using: pip3 install git+https://github.com/calebstewart/pwncat.git

I get the following error: File "/home/<user>/.local/lib/python3.8/site-packages/pwncat/gtfobins.py", line 4, in <module> from base64io import Base64IO ModuleNotFoundError: No module named 'base64io'

To Reproduce Steps to reproduce the behavior:

  1. Install on Debian 5.7.6 using pip3 install git+https://github.com/calebstewart/pwncat.git
  2. sudo ln -s /home//.local/bin/pwncat /usr/bin/
  3. run pwncat
  4. See error

Expected behavior I expected not to need to install base64io manually, using pip install base64io. This does fix the error.

Marnick39 commented 3 years ago

Full installation output here, pass:7PNCjJbuDC

Marnick39 commented 3 years ago

I suspect this is happening for the same reason paramiko isn't (always) installing automatically, both depend on your fork: git+https://github.com/JohnHammond/base64io-python git+https://github.com/calebstewart/paramiko (source: requirements.txt)

Paramiko was also not installed automatically, but that is a known issue and was handled 'correctly' by printing the related error:

error: pwncat requires a custom fork of paramiko. This can be installed with `pip install __main__.py:26
           -U git+https://github.com/calebstewart/paramiko` 

How would you like to approach this? Add a similar error for base64io, or is the dependency on your own fork being removed in the near future?

calebstewart commented 3 years ago

I haven't seen this happen yet, but I believe it's basically the same issue as paramiko. The same solution should work here. I'm fairly certain I will be able to fully remove this dependency with the updates I'm working on now. I'll add a reference to the README in the meantime, though. Thanks for the report!

calebstewart commented 3 years ago

I realize in hindsight that you didn't mention actually getting around the problem yourself. As mentioned in the README update, you can manually install the fork with:

pip install git+https://github.com/JohnHammond/base64io-python

And that should allow you to run pwncat as normal.