Whet I try to run Zenmap, the terminal show me this

吃可爱长大的小学妹 提交于 2020-12-27 07:29:06

问题


Could not import the zenmapGUI.App module: 'No module named gtk'. I checked in these directories:

/usr/local/bin
/usr/lib/python2.7
/usr/lib/python2.7/plat-x86_64-linux-gnu
/usr/lib/python2.7/lib-tk
/usr/lib/python2.7/lib-old
/usr/lib/python2.7/lib-dynload
/usr/local/lib/python2.7/dist-packages
/usr/lib/python2.7/dist-packages

If you installed Zenmap in another directory, you may have to add the modules directory to the PYTHONPATH environment variable.

------------------------------------------------resolved--------------------------------------------------------------------

$ mkdir -p ~/Downloads/zenmap
$ cd ~/Downloads/zenmap
$ wget http://archive.ubuntu.com/ubuntu/pool/universe/p/pygtk/python-gtk2_2.24.0-6_amd64.deb
$ wget http://archive.ubuntu.com/ubuntu/pool/universe/n/nmap/zenmap_7.80+dfsg1-1build1_all.deb

you have to unpackage those 2 /.deb and there you go


回答1:


Update for Kali 2020v4 to solve that issue:

Run

sudo bash 
apt-get update 
apt-get upgrade

To clear any existing installation run:

apt remove zenmap

Then

apt-get install python-cairo  

apt --fix-broken install

apt-get install python-gobject-2

apt --fix-broken install

dpkg -i python-gtk2_2.24.0-5.1ubuntu2_amd64.deb 

dpkg -i zenmap_7.80-2_all.deb

Resources:

http://us.archive.ubuntu.com/ubuntu/pool/universe/p/pygtk/

To Install ZenMap for kali

  1. Update the repos: sudo apt update

  2. Download latest package of zenmap, e.g. wget https://nmap.org/dist/zenmap-7.80- 1.noarch.rpm

  3. Install alien: sudo apt install alien -y

  4. Convert pack to deb Sintaxis: sudo alien [RPM downloaded]

  5. Install Sintaxis: sudo dpkg -i [DEB generated]




回答2:


Same issue. I notice that in kali 2019-4, in the path usr/lib/python2.7/dist-packages/gtk-2.0/gtk there are some init files, perhaps they are needed by the zenmap GUI.




回答3:


I had the same issue when I tried to install zenmap. I had to install pygtk2/ py gobject-2/python-cairo.

wget http://archive.ubuntu.com/ubuntu/pool/universe/p/pygtk/python-gtk2_2.24.0-5.1ubuntu2_amd64.deb
wget http://azure.archive.ubuntu.com/ubuntu/pool/universe/p/pygobject-2/python-gobject-2_2.28.6-14ubuntu1_amd64.deb
wget http://security.ubuntu.com/ubuntu/pool/universe/p/pycairo/python-cairo_1.16.2-2ubuntu2_amd64.deb

Then install them use dpkg -i <deb name>.



来源:https://stackoverflow.com/questions/64359059/whet-i-try-to-run-zenmap-the-terminal-show-me-this

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!