-1

hello i have a problem in installing mitmf in kali-linux version 2020.1a
during installation i performed following task in shell

  1. apt-get install python-dev python-setuptools libpcap0.8-dev libnetfilter-queue-dev libssl-dev libjpeg-dev libxml2-dev libxslt1-dev libcapstone3 libcapstone-dev libffi-dev file

  2. git clone https://github.com/byt3bl33d3r/MITMf

  3. cd MITMf && git submodule init && git submodule update --recursive

  4. pip install -r requirements.txt

but in step 4 there is obstacle that's: pip command not found

so i try to install pip with command: sudo apt install python-pip

but it doesn't work and says : Unable to locate package python-pip

then i try to install pip3 with command: sudo apt install python3-pip

and it get install and i complete the step 4 command of installing mitmf i.e : 4. pip install -r requirements.txt

after that when i run help command for mitmf i.e., python mitmf.py --help

It display following things

Traceback (most recent call last):

  File "mitmf.py", line 29, in <module>

    import core.responder.settings as settings

  File "/home/tester/MITMf/core/responder/settings.py", line 24, in <module>

    from core.configwatcher import ConfigWatcher

  File "/home/tester/MITMf/core/configwatcher.py", line 20, in <module>

    import pyinotify

ImportError: No module named pyinotify 

I have also try with this command : python3 mitmf.py

then following result popup

File "mitmf.py", line 38
    print get_banner()
          ^
SyntaxError: invalid syntax

so please help me to solve problem with no module name pynotify. what to do to solve this problems. I get stuck here and unable to solve this problem .

Cibin Joseph
  • 1,173
  • 1
  • 11
  • 16
  • Please check [how to ask a question](https://stackoverflow.com/help/how-to-ask) on Stack Overflow. Use formatting to make the question readable. – MrBean Bremen Apr 19 '20 at 13:39

6 Answers6

1

MITMF installation 2021|sep youtube link | https://www.youtube.com/watch?v=kDnQOIQj3zI

apt-get install python-dev-is-python2 python-setuptools libpcap0.8-dev libnetfilter-queue-dev libssl-dev libjpeg-dev libxml2-dev libxslt1-dev libcapstone4 libcapstone-dev

apt install pip

pip install virtualenvwrapper

which python3

export VIRTUALENVWRAPPER_PYTHON=/usr/bin/python3

source `which virtualenvwrapper.sh`

mkvirtualenv MITMf -p /usr/bin/python2.7

git clone https://github.com/byt3bl33d3r/MITMf

cd MITMf && git submodule init && git submodule update --recursive

pip install -r requirements.txt

python mitmf.py --help

this worked for me

0

Hey I have had the same issues you have been having and I finally figured out what I was doing wrong. You need to download packages before you install them. It took me a WHILE to figure that out.
Try pip3 for the -r requirements it might work

I think you need to download get-pip.py first to download and install all the missing modules and to use the -r requirements https://pip.pypa.io/en/stable/installing/ now you may be able to use the pip for -r requirements

Navigate to root directory or cd .. as far back as you can go first cmd curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py

2nd python get-pip.py

Then I think you can start downloading and install all of the missing modules. Whenever you start sudo ./mitmf.py or sudo python mitmf.py you will get an error that says for example no module named pyinotify open 2 terminals 1st terminal Navigate to root directory or cd .. as far back as you can go 2nd terminal navigate to your MITMf directory start mitmf to get the no module name ex no module named pyinotify

1st terminal sudo pip download pyinotify sudo pip install pyinotify

2nd terminal start mitmf with sudo ./mitmf.py or sudo python mitmf.py

if another no module error occurs repeat from the pip download and pip install steps try to start mitmf again Repeat as many times as you need and try both mitmf cmds to see if it is corrected. I had to download and install 8 modules before it actually worked. Hope this helps

Jon
  • 1
0

First, do

sudo pip download pyinotify 
sudo pip install pyinotify

Then, start mitmf with sudo ./mitmf.py or sudo python mitmf.py

If another no module error occurs repeat from the pip download and pip install steps try to start mitmf again Repeat as many times as you need and try both mitmf cmds to see if it is corrected. I had to download and install 8 modules before it actually worked. Hope this helps.

Cibin Joseph
  • 1,173
  • 1
  • 11
  • 16
Jon
  • 1
0

so you would first download with sudo pip download pyinotify then you need to install it with sudo pip install pyinotify then in the other terminal start the mitmf to see if it works or gives another error then repeat those steps again. The module names are not always correct so you may have to search the correct names. for example there was an error i got no module name magic. When I did sudo pip download magic the download failed. then i searched and found that the download cmd needs to be sudo pip download python-magic. the pip download and install need it to be python-magic and not just magic.
these are the 8 modules I had to download and install pyinotify configobj twisted bs4 pefile python-magic instead of magic capstone Pillow instead of PIL

Jon
  • 1
0

Hey I had the same issue recently. Since Kali 2020 a new user is always created in the installation process and we don't login as the root user anymore and it looks like it is causing issues with this. there was an interesting observation done when doing this if you don't use sudo while installing packages it gets installed in a different location compared to running it as sudo which is the reason the program is not able to access them and shows you the error for missing packages.

try running the installation as root i.e

sudo pip install -r requirements.txt

and run the program as root with

sudo ./mitmf.py or sudo python mitimf.py

if you see any more missing packages then don't forget to install them with sudo i.e

sudo pip install package-name

this worked for me.

0

Run the Following commands:

curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py

python get-pip.py

Then install requirements.txt using pip2:

pip2 install -r requirements.txt

python mitmf.py -h