cobbr / SharpSploit

SharpSploit is a .NET post-exploitation library written in C#
https://sharpsploit.cobbr.io/api/
BSD 3-Clause "New" or "Revised" License
1.75k stars 307 forks source link

Added configPersist #46

Open NotoriousRebel opened 4 years ago

NotoriousRebel commented 4 years ago

Added a modified version of ConfigPersist. What this does:

  1. Create a keyfile
  2. Invoke C# compiler to compile assembly with C# payload of user's choice Compilation also signs the assembly with keyfile
  3. Install assembly onto Global Assembly Cache (GAC)
  4. Modify machine.config's runtime appDomainType and appDomainManagerAssembly elements to point to our assembly installed onto the GAC.

TODO