Using PowerSploit
With the launch of PowerShell, new ways to exploit Windows machine also came in. As described by Wikipedia, PowerShell (including Windows PowerShell and PowerShell Core) is a task automation and configuration management framework from Microsoft, consisting of a command-line shell and associated scripting language built on the .NET Framework.
In this recipe, we will use PowerSploit, which is a PowerShell-based post exploitation framework to gain access to meterpreter on a system.
How to do it…
Following are the steps to use PowerSploit:
- We will now assume a situation in which we have a Windows-based environment in which we have managed to gain shell access. We do not have admin rights on the system.
- Let's look at a cool way of getting a meterpreter without actually downloading a file on the system using PowerSploit. It comes inbuilt with Kali in Menu.
- The trick here will be to download a PowerShell script and load it into memory, and as it is never saved on HDD, the antivirus...