Not able to use nmap in python.

+1 vote

I am trying to create a port scanner using python with nmap module. I have imported to nmap module but I am getting error:

>>> nm = nmap.PortScanner()
AttributeError: module 'nmap' has no attribute 'PortScanner'
Jan 28 in Cyber Security & Ethical Hacking by Pavan
116 views

1 answer to this question.

+1 vote

nmap module doesn’t have PortScanner attribute. The module you need to install to use PortScanner is python-nmap.

To install this, you can run the following command in command prompt/terminal:

pip install python-nmap
answered Jan 28 by Omkar
• 68,180 points
i did but it wasn't work in my case
Can you post the error?

Related Questions In Cyber Security & Ethical Hacking

0 votes
0 answers
0 votes
1 answer

Not able to install arpspoof

There is no package called arpspoof. To use the arpspoof command, ...READ MORE

answered Feb 9 in Cyber Security & Ethical Hacking by Omkar
• 68,180 points
2,551 views
0 votes
1 answer

Not able to run nikto scan on nikto-test.com

Hi, the webpage nikto-test.com doesn’t exist anymore. ...READ MORE

answered Apr 1 in Cyber Security & Ethical Hacking by Karan

reshown Apr 1 by Omkar 89 views
0 votes
1 answer

Not able to run Nessus Scanner

You have missed out a step. After ...READ MORE

answered Apr 1 in Cyber Security & Ethical Hacking by Lilly
65 views
0 votes
1 answer

python nmap can't find PortScanner attribute

As I can see in the error ...READ MORE

answered Jan 30 in Python by Omkar
• 68,180 points
702 views
+1 vote
2 answers

how can i count the items in a list?

Syntax :            list. count(value) Code: colors = ['red', 'green', ...READ MORE

answered Jul 6 in Python by Neha
• 330 points

edited Jul 8 by Kalgi 396 views
0 votes
1 answer

Not able to run nmap scan on router.

Might not be the actual router address. ...READ MORE

answered Jan 31 in Cyber Security & Ethical Hacking by Omkar
• 68,180 points
109 views
0 votes
1 answer