Kali Metasploit的用法

Step1:启动postsql数据库

[email protected]:~# service postgresql start

Step2:初始化msf数据库

[email protected]:~# msfdb init

[i] Database already started
[+] Creating database user ‘msf‘
[+] Creating databases ‘msf‘
[+] Creating databases ‘msf_test‘
[+] Creating configuration file ‘/usr/share/metasploit-framework/config/database.yml‘
[+] Creating initial database schema

Step3:进入msf控制台

[email protected]:~# msfconsole

MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM
MMMMMMMMMMM MMMMMMMMMM
MMMN$ vMMMM
MMMNl MMMMM MMMMM JMMMM
MMMNl MMMMMMMN NMMMMMMM JMMMM
MMMNl MMMMMMMMMNmmmNMMMMMMMMM JMMMM
MMMNI MMMMMMMMMMMMMMMMMMMMMMM jMMMM
MMMNI MMMMMMMMMMMMMMMMMMMMMMM jMMMM
MMMNI MMMMM MMMMMMM MMMMM jMMMM
MMMNI MMMMM MMMMMMM MMMMM jMMMM
MMMNI MMMNM MMMMMMM MMMMM jMMMM
MMMNI WMMMM MMMMMMM MMMM# JMMMM
MMMMR ?MMNM MMMMM .dMMMM
MMMMNm ?MMM MMMM dMMMMM
MMMMMMN ?MM MM? NMMMMMN
MMMMMMMMNe JMMMMMNMMM
MMMMMMMMMMNm, eMMMMMNMMNMM
MMMMNNMNMMMMMNx MMMMMMNMMNMMNM
MMMMMMMMNMMNMMMMm+..+MMNMMNMNMMNMMNMM
https://metasploit.com

=[ metasploit v5.0.71-dev ]

  • -- --=[ 1962 exploits - 1095 auxiliary - 336 post ]
  • -- --=[ 558 payloads - 45 encoders - 10 nops ]
  • -- --=[ 7 evasion ]

msf5 >

Step4:进行主机扫描

msf5 > db_nmap -sV 192.168.1.2

[] Nmap: Starting Nmap 7.80 ( https://nmap.org ) at 2020-01-30 05:18 EST
[
] Nmap: Nmap scan report for 192.168.1.2
[] Nmap: Host is up (0.00024s latency).
[
] Nmap: All 1000 scanned ports on 192.168.1.2 are filtered
[] Nmap: MAC Address: 98:3B:8F:18:C9:8C (Intel Corporate)
[
] Nmap: Service detection performed. Please report any incorrect results at https://nmap.org/submit/ .
[*] Nmap: Nmap done: 1 IP address (1 host up) scanned in 22.60 seconds

Step5:进行smb扫描测试

use auxiliary/scanner/smb/smb_version

msf5 auxiliary(scanner/smb/smb_version) >

msf5 auxiliary(scanner/smb/smb_version) > set RHOSTS 192.168.1.2
RHOSTS => 192.168.1.2

msf5 auxiliary(scanner/smb/smb_version) > set THREADS 100
THREADS => 100

msf5 auxiliary(scanner/smb/smb_version) > run

use auxiliary/scanner/smb/smb_version(smb版本扫描)

use auxiliary/scanner/smb/pipe_auditor(扫描命名管道,判断smb服务类型,帐号,密码)

use auxiliary/scanner/smb/pipe_dcerpc_auditor(扫描通过smb管道可以访问的RCERPC服务)

use auxiliary/scanner/smb/smb_enumshares(smb共享枚举---帐号,密码)

use auxiliary/scanner/smb/smb_enumusers(smb用户枚举----帐号密码)

use auxiliary/scanner/smb/smb_lookupsid(sid枚举--帐号,密码)

use auxiliary/scanner/ssh/ssh_version(ssh版本扫描)

use auxiliary/scanner/ssh/ssh_login (ssh密码爆破)

use auxiliary/scanner/ssh/ssh_login_pubkey(ssh公钥登录---set KEY_FILE id_rsa set USERNAME root)

use post/windows/gather/enum_patches(基于已经获取了session进行检测windows缺少的补丁)

use auxiliary/scanner/mssql/mssql_ping(mssql端口扫描)

use auxiliary/scanner/mssql/mssql_login(爆破mssql密码)

use auxiliary/admin/mssql/mssql_exec(远程执行代码--set CMD net user user pass /ADD)

use auxiliary/scanner/ftp/ftp_version(FTP版本扫描)

use auxiliary/scanner/ftp/anonymous(FTP匿名登录)

use auxiliary/scanner/ftp/ftp_login(FTP暴力破解)

use auxiliary/scanner/vnc/vnc_login(vnc密码破解)

use auxiliary/scanner/vnc/vnc_none_auth(vnc无密码访问---supported:None, free access!)

use auxiliary/scanner/rdp/ms12_020_check(RDP远程桌面漏洞---检查会不会造成DoS***)

use auxiliary/scanner/ssh/juniper_backdoor(设备后门)

use auxiliary/scanner/ssh/fortinet_backdoor(设备后门)

use auxiliary/scanner/vmware/vmauthd_login(VMWare ESXi密码破解)

use auxiliary/scanner/vmware/vmware_enum_vms(VMWare ESXi密码破解)

use auxiliary/admin/vmware/poweron_vm(利用web api远程开启虚拟机)

HTTP 弱点扫描

use auxiliary/scanner/http/cert(过期证书扫描)
use auxiliary/scanner/http/dir_listing(显示目录及文件)
use auxiliary/scanner/http/files_dir显示目录及文件)
use auxiliary/scanner/http/dir_webdav_unicode_bypass(WebDAV Unicode 编码身份验证绕过)
use auxiliary/scanner/http/tomcat_mgr_login(Tomcat 管理登录页面)
use auxiliary/scanner/http/verb_auth_bypass(基于HTTP方法的身份验证绕过)
use auxiliary/scanner/http/wordpress_login_enum(Wordpress 密码爆破--- set URI /wordpress/wp-login.php

mysql相关

use auxiliary/scanner/mysql/mysql_login

auxiliary/admin/http/manageengine_pmp_privesc

auxiliary/scanner/mysql/mysql_version

auxiliary/server/capture/mysql

post/multi/manage/dbvis_add_db_admin

原文地址:https://blog.51cto.com/14773580/2485195

时间: 2024-10-11 03:15:15

Kali Metasploit的用法的相关文章

kali metasploit 数据库配置

kali 网络服务策略使得其没有自动启动的网络服务,包括数据库服务, 而metasploit需要数据库服务的支持,所以开启数据库服务的自动启动 msf > db_status [*] postgresql selected, no connection 简单开启服务: service postgresql start service metasploit start msfconsole db_rebuild_cache 开机开启服务: update-rc.d postgresql enable

kali metasploit 之 autopwn 浏览器钓鱼,java漏洞

本文介绍的autopwn是kali中自带的那个autopwn, 不是相对于bt5被删除的那个autopwn. 1.打开msfconsole, 找出autopwn目录及使用 msf > search autopwn Matching Modules ================ Name Disclosure Date Rank Description ---- --------------- ---- ----------- auxiliary/server/browser_autopwn

ms12-020漏洞复现(kali metasploit)

1.进入kali终端,输入命令msfconsole,使用search命令搜索ms12-020模块.(tip:靶机win7) 2.使用use + [模块名或模块前的序号]选择对应的模块后使用show options查看所需参数 3.根据所需参数使用set命令配置对应参数(这里是配置靶机的地址),然后使用run或exploit运行 4.结果(目标蓝屏重启) 原文地址:https://www.cnblogs.com/walkwaters/p/12244620.html

MS17-010漏洞复现(kali metasploit)

1.终端进入msf(在终端输入msfconsole),使用search命令查找漏洞模块: 2.根据靶机选择漏洞模块(此处靶机为win7 sp1),使用use+漏洞模块(msf5可以直接使用编号代替模块名称),然后使用show options查看需要的参数. 使用show options查看模块所需参数: 3.通过set [参数名] [参数值]设置参数(配置需要的参数(set rhost 192.168.43.222),run或exploit运行): 4.靶机的cmd: 预防:在微软官网根据漏洞编

Kali dvwa的用法

Step1:下载dvwa到本地 [email protected]:~# git clone https://github.com/ethicalhack3r/DVWA.git Step2:重命名文件夹 [email protected]:~# mv DVWA dvwa Step3:安装 [email protected]:~# service apache2 stop [email protected]:~# cp -r dvwa /var/www/html/ [email protected

3 CVE-2017-11882漏洞分析

CVE-2017-11882漏洞分析 操作系统:Windows7 32/64位 专业版.Linux 软件:office 2003 sp3 工具:OD.IDA.Python模块.msfconsole 1漏洞分析: 获取POC: https://github.com/embedi/CVE-2017-11882 下载即可 打开例程,发现文档打开了计算器,应该是ShellCode. 查找漏洞点: 打开Microsoft Word 2003,快捷键Alt+i+o(插入.对象)打开Microsoft 公式

更新Kali中的metasploit

1. Kali中的metasploit默认使用apt-get进行更新,看一下metasploit路径中的.apt文件. 默认情况下会出现这种情况 # msfupdate [*] [*] Attempting to update the Metasploit Framework... [*] [*] Checking for updates via the APT repository [*] Note: expect weekly(ish) updates using this method [

kali linux 系列教程之metasploit 连接postgresql可能遇见的问题

kali linux 系列教程之metasploit 连接postgresql可能遇见的问题 文/玄魂   目录 kali linux 下metasploit 连接postgresql可能遇见的问题................................ 1 前言............................................................................................................... 1

metasploit用法

1.msfconsole 进入metasploit 2.help connect 查看帮助 3.msfcli -h 查看帮助 4.ms08_067_netapi O 字符命令后加"O",查看配置 5.armitage 图形化用户接口 6.msfpayload -h 攻击载荷的帮助 7.msfencode -l 可用的编码器清单 连接数据库? metasploit用法,布布扣,bubuko.com