上QQ阅读APP看书,第一时间看更新
Running OS commands in MSF
One of the features of Metasploit Framework is that we can execute normal shell commands from the console. You can execute any shell command that is supported by your shell (bash/sh/zsh/csh). In this case, we executed the whoami && id command from the console. The command was executed and the result was displayed in the console itself, as shown in the following screenshot:
We can also use an interactive bash script from the console using the /bin/bash -i command or just /bin/bash (the -i switch is used to run bash in interactive mode):
Note: To get an interactive command prompt in Windows, execute cmd.exe in the console.