python-nmap 运行时出现了一下错误

D:\python\untitled5\Scripts\python.exe D:/python/untitled5/test.py
Traceback (most recent call last):
File "D:/python/untitled5/test.py", line 2, in <module>
nm = nmap.PortScanner()
File "D:\python\untitled5\lib\site-packages\nmap\nmap.py", line 131, in __init__
os.getenv('PATH')
nmap.nmap.PortScannerError: 'nmap program was not found in path. PATH is : C:\\Program Files (x86)\\Common Files\\Oracle\\Java\\javapath;C:\\Program Files (x86)\\Intel\\iCLS Client\\;C:\\Program Files\\Intel\\iCLS Client\\;C:\\Windows\\system32;C:\\Windows;C:\\Windows\\System32\\Wbem;C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\;C:\\Program Files\\Intel\\WiFi\\bin\\;C:\\Program Files\\Common Files\\Intel\\WirelessCommon\\;C:\\Program Files\\Intel\\Intel(R) Management Engine Components\\DAL;C:\\Program Files (x86)\\Intel\\Intel(R) Management Engine Components\\DAL;C:\\Program Files\\Intel\\Intel(R) Management Engine Components\\IPT;C:\\Program Files (x86)\\Intel\\Intel(R) Management Engine Components\\IPT;C:\\Program Files\\Lenovo\\Fingerprint Manager Pro\\;D:\\OpenVPN\\bin;C:\\Program Files\\Git\\cmd;D:\\nodejs\\;D:\\nodejs\\node_global;C:\\Users\\Edianzu\\.windows-build-tools\\python27\\;D:\\nodejs\\node_modules\\npm\\node_modules\\npm-lifecycle\\node-gyp-bin;D:\\nodejs\\node_global\\node_modules\\windows-build-tools\\node_modules\\.bin;D:\\nodejs\\node_global\\node_modules\\.bin;C:\\Program Files (x86)\\Common Files\\Oracle\\Java\\javapath;C:\\Program Files (x86)\\Intel\\iCLS Client\\;C:\\Program Files\\Intel\\iCLS Client\\;C:\\Windows\\system32;C:\\Windows;C:\\Windows\\System32\\Wbem;C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\;C:\\Program Files\\Intel\\WiFi\\bin\\;C:\\Program Files\\Common Files\\Intel\\WirelessCommon\\;C:\\Program Files\\Intel\\Intel(R) Management Engine Components\\DAL;C:\\Program Files (x86)\\Intel\\Intel(R) Management Engine Components\\DAL;C:\\Program Files\\Intel\\Intel(R) Management Engine Components\\IPT;C:\\Program Files (x86)\\Intel\\Intel(R) Management Engine Components\\IPT;C:\\Program Files\\Lenovo\\Fingerprint Manager Pro\\;D:\\OpenVPN\\bin;C:\\Program Files\\Git\\cmd;C:\\Program Files (x86)\\Windows Kits\\8.1\\Windows Performance Toolkit\\;D:\\nodejs\\;D:\\nodejs\\node_global;C:\\Users\\Edianzu\\AppData\\Local\\Programs\\Python\\Python37-32\\Scripts\\;C:\\Users\\Edianzu\\AppData\\Local\\Programs\\Python\\Python37-32\\;C:\\Users\\Edianzu\\AppData\\Roaming\\npm;D:\\python\\untitled5\\Scripts'

解决办法

下载一个windows的nmap,找到nmap的exe文件。把他加入nmap.py文件中

    def __init__(self, nmap_search_path=('nmap', '/usr/bin/nmap', '/usr/local/bin/nmap', '/sw/bin/nmap', '/opt/local/bin/nmap',r"D:\nmap-7.70-win32\nmap-7.70\nmap.exe")):
"""
Initialize PortScanner module

就OK了

windows下python-nmap运行过程中出现的问题及解决办法的更多相关文章

  1. QT5.1在Windows下 出现QApplication: No such file or directory 问题的解决办法

    QT5.0.1在Windows下 出现QApplication: No such file or directory 问题的解决办法 分类: 编程语言学习 软件使用 QT编程学习2013-03-07 ...

  2. iOS 学习笔记二【cocopods安装使用和安装过程中遇到的问题及解决办法】【20160725更新】

    在osx 10.11之前cocopods问题不多,但是升级到11之后的版本,之前的cocopods大多用不了,需要重新安装,对于我这种使用测试版系统的技术狂来说,每次都需要重新安装很多东西, 当然,c ...

  3. iOS cocopods安装使用和安装过程中遇到的问题及解决办法

    在osx 10.11之前cocopods问题不多,但是升级到11之后的版本,之前的cocopods大多用不了,需要重新安装,对于我这种使用测试版系统的技术狂来说,每次都需要重新安装很多东西, 当然,c ...

  4. 解锁Scott过程中出现的问题及解决办法

    一.conn sys/sys as sysdba; //以DBA的身份登录 出现以下错误 经查 协议适配器错误的问题的原因有三个 监听服务没有起起来.windows平台个一如下操作:开始---程序-- ...

  5. oracle安装过程中先决条件检查失败的解决办法

    1:公司数据库开始用的mysql,因为公司做的是保密性项目,所以就在项目日志过多的时候项目有爆炸的迹象啊(3000千万数据,貌似mysql有点撑不住).然后组长开始让我安装oracle,公司的内网也是 ...

  6. vs 2015 结合新配置的IIS 发布网站过程中遇到的问题及解决办法?

    1.由于扩展配置问题而无法提供您请求的页面.如果该页面是脚本,请添加处理程序 错误: HTTP 错误 404.3 - Not Found 由于扩展配置问题而无法提供您请求的页面.如果该页面是脚本,请添 ...

  7. QT4编程过程中遇到的问题及解决办法

    1.QLineEdit显示内容的格式函数: QLineEdit *lineEditPassword = new QLineEdit: lineEditPassword -> setEchoMod ...

  8. windows下composer安装不了或composer命令无效的解决办法

    安装方法: http://docs.phpcomposer.com/00-intro.html#Installation-Windows (官方中文帮助文档) 问题描述1: 通过Composer-Se ...

  9. Windows下python安装运行

    1. 在python官网 https://www.python.org/downloads/windows/ 选择要下载的版本,我下载了最新版本 2. 双击运行 3. naxt 4. install ...

随机推荐

  1. Boost Asioserver使用

    今天主要想说道说道boost里面的网络通信库怎样设计和使用,由于近期一直在和网络一起工作,大数据处理和机器学习都离不开最后使用网络进行上线部署.先看看所有的源码吧. #include <cstd ...

  2. ORACLE 11G 怎样改动 awr 的保留期限小于8天

     ORACLE 11G 怎样改动 awr 的保留期限小于8天 Oracle Database 11g 默认具备一个系统定义的Moving Window Baseline,该基线相应于 AWR 保留 ...

  3. java分页之页面分页

    import java.util.ArrayList; import java.util.List; /** * * @author cheney * * @date Aug 31, 2012 */ ...

  4. Recommendation system

    Dear Prof.Choi: My research interest is mainly the application and optimization of big data and arti ...

  5. C# 数据库访问

    C# 数据库访问 分类: C#学习笔记2011-07-05 11:26 515人阅读 评论(0) 收藏 举报 数据库c#datasettextboxcommandexception   目录(?)[+ ...

  6. 洛谷P2340 奶牛会展

    题目背景 奶牛想证明它们是聪明而风趣的.为此,贝西筹备了一个奶牛博览会,她已经对N 头奶牛进行 了面试,确定了每头奶牛的智商和情商. 题目描述 贝西有权选择让哪些奶牛参加展览.由于负的智商或情商会造成 ...

  7. 03、HelleBaiduMap

    D:\百度地图\百度地图\资料\百度地图与定位SDK\百度地图v3.5.0\BaiduMap_AndroidSDK_v3.5.0_All\BaiduMap_AndroidSDK_v3.5.0_Docs ...

  8. sql简单学习---备忘

    2:Hibernate public boolean deleteFlowerById(int id) { Session session = sessionFactory.openSession() ...

  9. target属性打开方式

    在HTML中target目标的四个参数的用法:1.target="_self"表示:将链接的画面内容,显示在目前的视窗中.(内定值) . 即:同(自己)窗口打开,别的数据还存在,相 ...

  10. php字符串读取函数

    function cc_msubstr($str, $length, $start=0, $charset="utf-8", $suffix=true){ if(function_ ...