Código (asm) [Seleccionar]
;Traducido por YST , codigo original por Karcrack
include 'win32ax.inc'
.code
start:
stdcall ConseguirApi,Libreria,yapi
stdcall eax,0,0,0,0
invoke ExitProcess
proc ConseguirApi,pLib,pProc
locals
struct tAPICall
ptsLIB dd ? ; Pointer to ANSI String that contains Library
ptsProc dd ? ; Pointer to ANSI String that contains Procedure
lReserved dd ? ; Just reserved...
lPointer dd ? ; Pointer to the buffer that will contain temp variables from DllFunctionCall
lpBuffer dd 4 dup (0); Buffer that will contain temp variables
ends
tAPI tAPICall
endl
push [pLib]
pop [tAPI.ptsLIB]
push [pProc]
pop [tAPI.ptsProc]
mov [tAPI.lReserved],40000h
lea eax,[tAPI.lPointer]
mov [tAPI.lPointer],eax
invoke DllFunctionCall,addr tAPI
ret
endp
.data
Libreria db "user32.dll" ,0
yapi db "MessageBoxA",0
section '.idata' import data readable writeable
library kernel32,'kernel32.dll',MSVBVM60,'MSVBVM60'
include 'api/kernel32.inc'
import MSVBVM60,DllFunctionCall,'DllFunctionCall'