Covenant C2
Covenant is a C2 framework written in .NET core, which makes it cross-platform and easy to use. We will set this up in a docker. Clone the dev branch and then build the docker.
Last updated
Covenant is a C2 framework written in .NET core, which makes it cross-platform and easy to use. We will set this up in a docker. Clone the dev branch and then build the docker.
Last updated
You can reuse the same container later with the following command: sudo docker start covenant -ai
Navigate to Listeners
and create a new listener on port 80. Make sure that the ConnectAddress
is set to the VPN/VM address. Next, go to Launchers
and select BinaryLauncher
. Set DotNetVersion
to 4.0 and the Name
to grunt
. The Delay can be reduced to 3
. Generate and download the binary, then use donut to convert it to shellcode.
Now compile following C# code, which will load this shellcode and execute it.
The code above pins the shellcode into memory, makes it executable and then executes it. This can be compiled with mono on Linux.
Once the compilation succeeds, copy the following PowerShell code for the launcher.
This will load the binary in memory and execute it via reflection.
Browsing to will bring us to the Covenant UI. Create a new account and then cd Cologin. We will be generating a binary and converting it to shellcode using . This will let us evade Windows Defender and inject this to get grunts.