好记性不如铅笔头

安全, 操作系统

某《魔鬼训练营》读书笔记:网络主机漏洞扫描工具Nexpose

!!!笔记仅供学习交流使用,请勿进行其他用途!!!

Nexpose是一个非常强大的扫描工具,这里只笔记下最简单的功能。kali下默认没有安装Nexpose,因此这里需要手动下载和安装。

CONTENTS

下载和安装:

进入【 https://www.rapid7.com/products/nexpose/compare-downloads.jsp 】下载Nexpose,这里我们下载社区版本,并且下载linux版本安转包,需要注意的是:

1 Nexpose已经不提供32位的支持了,我们这里下载64位的Linux版本安装到kali里。
2 nexpose为了防止被滥用,对key的发放做了限制,申请key的email不能是个人用email
3 kali不在Nexpose的支持系统内,可能会有问题。
4 Nexpose对硬盘消耗较大(20G+),对内存的要求也较高(4G-8G)。

安装很简单,如下图输入命令,会启动GUI的安装界面,默认选项安装即可。
不过google了下,最好在安装前先停止PostgreSQL,命令:service postgresql stop安装结束之前,如果启动Nexpose失败,可以根据提示运行命令:

root@kali:~# cd /opt/rapid7/nexpose/nsc/
root@kali:/opt/rapid7/nexpose/nsc# sh nsc.sh 
。。。。。
。。。。。

来手动启动和初始化,这里的时间比较久。待命令行显示ready之后,可以根据提示使用浏览器打开【  https://127.0.0.1:3780 】。这里要输入激活码。

注意:
1 这里的命令行当前上下文为Nexpose Console,不要退出该console。如果要退出console,可以输入命令exit,即可退出Nexpose。
2 如果需要重新启动Nexpose Console,可以执行命令:

root@kali:/opt/rapid7/nexpose/nsc# sh nsc.sh 

使用web版本:

首先新建一个site,名称为WinXPSP2,包含我们要扫描的IP。Scan Setup中的Scan Template设置为【 full audit without web spider 】:

新建好之后就可以在site页面点击【 scan 】按钮开始扫描了。扫描结束后我们可以查看漏洞列表,及详细信息。具体如下图:

详细信息:

在Metasploit中使用:

root@kali:~# msfconsole
。。。。。
msf > load nexpose 
。。。。。
msf > help

Nexpose Commands
================

    Command                   Description
    -------                   -----------
    nexpose_activity          Display any active scan jobs on the Nexpose instance
    nexpose_command           Execute a console command on the Nexpose instance
    nexpose_connect           Connect to a running Nexpose instance ( user:pass@host[:port] )
    nexpose_disconnect        Disconnect from an active Nexpose instance
    nexpose_discover          Launch a scan but only perform host and minimal service discovery
    nexpose_dos               Launch a scan that includes checks that can crash services and devices (caution)
    nexpose_exhaustive        Launch a scan covering all TCP ports and all authorized safe checks
    nexpose_report_templates  List all available report templates
    nexpose_save              Save credentials to a Nexpose instance
    nexpose_scan              Launch a Nexpose scan against a specific IP range and import the results
    nexpose_site_devices      List all discovered devices within a site
    nexpose_site_import       Import data from the specified site ID
    nexpose_sites             List all defined sites
    nexpose_sysinfo           Display detailed system information about the Nexpose instance

不知什么原因,作者使用nexpose_connect命令无法登陆Nexpose,最后没有笔记这方面的命令。不过看了下Metasploit的命令列表,估计也是简化版的Nexpose的使用。这里也请各位路过的大牛给点提示,如何才能在Metasploit中使用Nexpose。

发表评论

6 + 4 =

此站点使用Akismet来减少垃圾评论。了解我们如何处理您的评论数据