Zenmap kali linux no module named gtk

Arch Linux

You are not logged in.

#1 2015-07-27 06:29:18

[SOLVED] Python. No module named gtk

This is one of the most stupidest thing I’ve ever done.

Recently for installing kivy I had to remove my site packages for both python 2.7 and python 3.4 in my Arch since installing kivy was aborted due to conflicts. During that time I also deleted a lot of other python files and directories. I removed both versions of python too.

I knew that reinstalling the whole thing would bring back things to normal, and to my luck most of it did. But recently I found that I cannot import gtk module. I tried installing pygtk via pip and using pacman and I still cant seem to import gtk. How can I bring back gtk ?

Last edited by mahesmohan (2015-07-29 09:10:52)

#2 2015-07-27 08:38:12

Re: [SOLVED] Python. No module named gtk

What command are you using to import the gtk module and in which python version? As far as I know pygtk is only for python2 and for python3 you should use the GObject Inspector module: https://python-gtk-3-tutorial.readthedo … le-example. However, what is the output of the following commands?

— When you have eliminated the impossible, whatever remains, however improbable, must be the truth — Spock | Sherlock Holmes

#3 2015-07-27 20:04:38

Re: [SOLVED] Python. No module named gtk

I noticed the issue when I tried running guake which used to work perfectly before the deletion, I tried running it from the CLI and got a Traceback with message

Here is the complete Traceback

I believe the traceback answers your question regarding the version of python and command used to import gtk module.
Here is the output of the commands you asked me to run:

Источник

Could not import the zenmapGUI.App module: ‘No module named gtk’. #78211

Comments

davidak commented Jan 21, 2020

Describe the bug
zenmap don’t start

To Reproduce
Steps to reproduce the behavior:

  1. nix run nixpkgs.nmap_graphical
  2. zenmap

same when installed with nix-env -iA nixos.nmap_graphical .

Expected behavior
zenmap starts 🙂

Metadata

  • system: «x86_64-linux»
  • host os: Linux 4.19.93, NixOS, 19.09.1815.caad1a78c47 (Loris)
  • multi-user?: yes
  • sandbox: yes
  • version: nix-env (Nix) 2.3.2
  • channels(davidak): «»
  • channels(root): «nixos-19.09.1815.caad1a78c47, nixos-hardware, nixos-unstable-20.03pre208413.e1eedf29e5d»
  • nixpkgs: /nix/var/nix/profiles/per-user/root/channels/nixos

The text was updated successfully, but these errors were encountered:

davidak commented Jan 21, 2020

It works on unstable:

stale bot commented Jul 20, 2020

Hello, I’m a bot and I thank you in the name of the community for opening this issue.

To help our human contributors focus on the most-relevant reports, I check up on old issues to see if they’re still relevant. This issue has had no activity for 180 days, and so I marked it as stale, but you can rest assured it will never be closed by a non-human.

Читайте также:  Windows 10 error start button

The community would appreciate your effort in checking if the issue is still valid. If it isn’t, please close it.

If the issue persists, and you’d like to remove the stale label, you simply need to leave a comment. Your comment can be as simple as «still important to me». If you’d like it to get more attention, you can ask for help by searching for maintainers and people that previously touched related code and @ mention them in a comment. You can use Git blame or GitHub’s web interface on the relevant files to find them.

Lastly, you can always ask for help at our Discourse Forum or at #nixos’ IRC channel.

davidak commented Jul 22, 2020

unstable is now stable and it works

snakepeek commented Dec 8, 2020

Install python-gtk2-dev on kali

installing this solved my issues.

iamrk1729 commented Dec 21, 2020

can you tell me how to install python-gts2-dev i am getting some error while doing that

dpickle13 commented Dec 29, 2020

@snakepeek Yes, can you provide a little more clarification on your fix? Thanks in advance!

ashwani-dcs commented Jan 11, 2021

@snakepeek Yes, can you provide a little more clarification on your fix? Thanks in advance!

sure, gtk2 is not in apt repository so cannot install gtk2-dev package still not able to run zenmap still throwing the same error

basherselmo commented Feb 3, 2021

hey everyone can someone help me in this proplem when i try to install zenmap
Could not import the zenmapGUI.App module: ‘No module named gtk’.
I checked in these directories:
/usr/bin
/usr/share/offsec-awae-wheels/colorama-0.4.3-py2.py3-none-any.whl
/usr/share/offsec-awae-wheels/six-1.15.0-py2.py3-none-any.whl
/usr/share/offsec-awae-wheels/certifi-2020.4.5.1-py2.py3-none-any.whl
/usr/share/offsec-awae-wheels/backports.functools_lru_cache-1.6.1-py2.py3-none-any.whl
/usr/share/offsec-awae-wheels/pycparser-2.20-py2.py3-none-any.whl
/usr/share/offsec-awae-wheels/urllib3-1.25.9-py2.py3-none-any.whl
/usr/share/offsec-awae-wheels/PySocks-1.7.1-py27-none-any.whl
/usr/share/offsec-awae-wheels/pyOpenSSL-19.1.0-py2.py3-none-any.whl
/usr/share/offsec-awae-wheels/ipaddress-1.0.23-py2.py3-none-any.whl
/usr/share/offsec-awae-wheels/chardet-3.0.4-py2.py3-none-any.whl
/usr/share/offsec-awae-wheels/soupsieve-1.9.5-py2.py3-none-any.whl
/usr/share/offsec-awae-wheels/requests-2.23.0-py2.py3-none-any.whl
/usr/share/offsec-awae-wheels/enum34-1.1.10-py2-none-any.whl
/usr/share/offsec-awae-wheels/ply-3.11-py2.py3-none-any.whl
/usr/share/offsec-awae-wheels/idna-2.9-py2.py3-none-any.whl
/usr/share/offsec-awae-wheels/beautifulsoup4-4.9.1-py2-none-any.whl
/usr/share/cffi-wheels/setuptools-44.1.0-py2.py3-none-any.whl
/usr/share/cffi-wheels/py-1.8.1-py2.py3-none-any.whl
/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
/usr/lib/python2.7/dist-packages
/usr/lib/python2.6/site-packages
If you installed Zenmap in another directory, you may have to add the
modules directory to the PYTHONPATH environment variable.

UnknownSoldier32 commented Jun 12, 2021 •

installing this solved my issues.

It took me a while to install all the dependencies manually, but it worked: D
Thank you!

Источник

Zenmap — Easy GUI version of Nmap

Zenmap is Graphical User Interface (GUI) version of Nmap. Zenmap is also very powerful tool like nmap. For it’s graphical interface and easy menus makes it very easy to use.

Installing Zenmap on Kali Linux 2021

To install Zenmap we need to download it from Nmap’s official website. On the website we can download Zenmap rpm file, or we can click here to directly download it.

On the download screen we can click to save it as we did in the following screenshot.

This a a very small file (approximately 700kb) to download, download will finish in some seconds.

After downloading it we can open our terminal and run following command to update our system:

This may ask for root password. After finishing the update we need alien. Alien means not 👽👾 (the creatures from other planet). Alien is a program that can converts an RPM package (RedHat) file into a Debian package file.

Читайте также:  Kali linux install github

This is not a standard way to install software packages on Debian based distribution. But in this case we need to do this.

We can install alien by using following command:

Then the alien will be installed as we can see on the following screenshot:

Then we need to navigate to our Downloads directory where we have the downloaded Zenmap rpm file.

Then we need to convert our downloaded rpm file to deb file using alien by using following command:

This command will convert zenmap rpm file to zenmap deb file. As we can see in the following screenshot:

Now we can install it on our system by running following command:

After applying the above command Zenmap will be installed as we can see in the following screenshot:

Zenmap uses Python GTK for creating a graphical user interface, that’s why we have to install that as well on our Kali Linux system.

We need to download it from Ubuntu’s website and install it. To download it we use following command:

Then we install it by using following command:

Now we can search for Zenmap on our application menu or we can run zenmap or sudo zenmap command on our terminal to open Zenmap.

Using Zenmap on Kali Linux

After a successful installation we can use Zenmap. If we use Zenmap with root then we can use it’s all options. So we open it with root by using following command:

We can see that Zenmap is opened on the following screenshot:

Here everything is very easy. Here we need to put the IP address of our target network. For an example we are choosing our localhost system’s IP address (192.168.122.148), we also can choose the website’s address.

Then we need to choose the profile as «Quick Scan«. For an example we have chosen «Quick Scan» we can choose other profiles as per our requirements. Then we just need to click on «Scan». Then the result will comes in front of us as the following screenshot:

In the above screenshot we can see the open ports on our target.

Once the scan has completed, we can click on each tab to get further details about our target. If we’re performing a scan on an entire network, the «Topology» tab will help us create a network diagram of the target network.

Zenmap is very easy to use and user-friendly. This is how we can install Zenmap on Kali Linux new versions and it’s uses.

Liked our article? Then make sure to follow our mail-subscription to get new articles directly on inbox. We also update articles on our Twitter and GitHub profiles. Make sure to follow us there. We also have Telegram group for chatting with everyone.

For any kind of problem and queries make sure to comment in the comment section. We always reply.

You may like these posts

Comments

root@kali /h/e/Downloads# python /usr/bin/zenmap
File «/usr/bin/zenmap», line 114
except ImportError, e:
^
SyntaxError: invalid syntax
root@kali /h/e/Downloads# python2 /usr/bin/zenmap
Could not import the zenmapGUI.App module: ‘No module named gtk’.
I checked in these directories:
/usr/bin
/home/ezri/Remarkable/remarkable
/home/ezri/Remarkable/remarkable_lib
/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/local/lib/python2.7/dist-packages/LinkFinder-1.0-py2.7.egg
/usr/local/lib/python2.7/dist-packages/EditorConfig-0.12.2-py2.7.egg
/usr/local/lib/python2.7/dist-packages/py_altdns-1.0.0-py2.7.egg
/usr/local/lib/python2.7/dist-packages/termcolor-1.1.0-py2.7.egg
/usr/local/lib/python2.7/dist-packages/dnspython-2.0.0-py2.7.egg
/usr/local/lib/python2.7/dist-packages/requests_file-1.5.1-py2.7.egg
/usr/local/lib/python2.7/dist-packages/idna-2.10-py2.7.egg
/usr/local/lib/python2.7/dist-packages/urllib3-1.25.10-py2.7.egg
/usr/local/lib/python2.7/dist-packages/certifi-2020.6.20-py2.7.egg
/usr/local/lib/python2.7/dist-packages/shodan-1.23.0-py2.7.egg
/usr/local/lib/python2.7/dist-packages/ipaddress-1.0.23-py2.7.egg
/usr/local/lib/python2.7/dist-packages/click_plugins-1.1.1-py2.7.egg
/usr/lib/python2.7/dist-packages
/usr/lib/python2.6/site-packages
If you installed Zenmap in another directory, you may have to add the
modules directory to the PYTHONPATH environment variable.

Читайте также:  Soft gps для windows

Your problem solved here .

python3 /usr/bin/zenmap
File «/usr/bin/zenmap», line 114
except ImportError, e:
^
SyntaxError: invalid syntax

Please check the updated article. Thanks

Hello I want to hack someone’s WhatsApp

This will be illegal. Sorry we can’t lead you in this matter.

I have same problem even though i followed all your instructions it has the same error: If you installed Zenmap in another directory, you may have to add the
modules directory to the PYTHONPATH environment variable.

It seems to happen with the latest kali linux version.

Also when i try to install python as you show in your steps, i get this error:
Note, selecting ‘python-gtk2’ instead of ‘./python-gtk2_2.24.0-5.1ubuntu2_amd64.deb’
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
python-gtk2 : Depends: python-cairo (>= 1.0.2-1.1) but it is not installable
Depends: python-gobject-2 (>= 2.21.3) but it is not installable
E: Unable to correct problems, you have held broken packages.

Have you tried
sudo dkpg -i —force-all nameofpackage.deb

March 2021, I sadly get this error both on the newest version and the older one.

sudo dpkg -i zenmap_7.91-1_all.deb
dpkg: warning: parsing file ‘/var/lib/dpkg/tmp.ci/control’ near line 7 package ‘zenmap’:
‘Depends’ field, reference to ‘rpmlib’:
«implicit exact match on version number, suggest using ‘=’ instead
dpkg: error processing archive zenmap_7.91-1_all.deb (—install):
parsing file ‘/var/lib/dpkg/tmp.ci/control’ near line 7 package ‘zenmap’:
‘Depends’ field, reference to ‘rpmlib’: version ‘PartialHardlinkSets’: version number does not start with digit
Errors were encountered while processing:
zenmap_7.91-1_all.deb»

Something with me missing rpmlib? Too n00b to totally understand sorry.

Thanks for all your hard work.

This problem is very similar to this

Using the newest Desktop Windows 10, version of Kali Linux, March 2021, on Oracle Vm.

Alien is giving me an Error 25 on VirtualBox 6.1. Please help.

Package build failed. Here’s the log:
dh
dh: error: specify a sequence to run
make: *** [debian/rules:7: binary] Error 25

Thank you in advance.

We can install it without converting try following command:

sudo alien -i zenmap*.rpm

Try it and tell if it working or not in your system.

──(root��kali)-[/home/kali/Downloads]
└─# apt install ./python-gtk2_2.24.0-5.1ubuntu2_amd64.deb
Reading package lists. Done
Building dependency tree. Done
Reading state information. Done
Note, selecting ‘python-gtk2’ instead of ‘./python-gtk2_2.24.0-5.1ubuntu2_amd64.deb’
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
python-gtk2 : Depends: python-cairo (>= 1.0.2-1.1) but it is not installable
Depends: python-gobject-2 (>= 2.21.3) but it is not installable
E: Unable to correct problems, you have held broken packages.

You already wrote the solutions. try the unmet dependencies which are not installed. Install them first.

Post a Comment

Please do not spam here. It is comment box not a spambox. Promotional links are not allowed.

Источник

Оцените статью