katoolin issue in Ubuntu 18.04 - "/usr/bin/katoolin: No such file or directory"
I'm using Ubuntu 18.04 Bionic. I have installed katoolin but it does not run. I'm using below commands
git clone https://github.com/LionSec/katoolin.git
sudo cp katoolin/katoolin.py /usr/bin/katoolin
sudo chmod a+x /usr/bin/katoolin
sudo katoolin
but after all I'm facing below error.
sudo: unable to execute /usr/bin/katoolin: No such file or directory
please help.
Open the terminal and type:
git clone https://github.com/LionSec/katoolin.git
sudo cp katoolin/katoolin.py /usr/bin/katoolin
sudo chmod a+x /usr/bin/katoolin
cd /usr/bin/ # change directories to the directory where katoolin is located
sudo ./katoolin # execute the katoolin script
This is happening because you have different version on python installed and you katoolin have different version.
You have to edit this line
#!/usr/bin/python
I have python3 so adding python3. Add your version here
-
nano /usr/bin/katoolin
-
#!/usr/bin/python
Into -
#!/usr/bin/python3
-
sudo katoolin
After this may be You will get error like this
File "/usr/bin/katoolin", line 8
print "Sorry. This script requires sudo privledges"
^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print("Sorry. This script requires sudo privledges")?
If you got error like this Change this line
print "Sorry. This script requires sudo privledges"
Into
print ("Sorry. This script requires sudo privledges")
If you have different version you will get an error like this
Traceback (most recent call last):
File "/usr/bin/katoolin", line 1294, in main
inicio1()
File "/usr/bin/katoolin", line 41, in inicio1
opcion0 = raw_input("\033[1;36mkat > \033[1;m")
NameError: name 'raw_input' is not defined
Do like this
For Python 3.x, use input()
. For Python 2.x, use raw_input()
- Change all
raw_input
Into -
input
If you are a python3 users. or For python2 useraw_input
.
If you solve your problem can you approve my answer.