Código: Seleccionar todo
include 'F:\Cracking\fasmw16931\INCLUDE\WIN32AX.INC'
.data
poison db 'Hola Indetectables... esto es un ejemplo de strlen',0
hLen rb 260
contador dd ?
.code
proc lsStrlen,sStr
; Limpiamos los Registros.
xor eax,eax
xor ecx,ecx
;Guardamos la string.
mov eax,[sStr]
mov ecx,-1
bucle:
add ecx,1
inc eax
cmp byte[eax],0
je Listo
jmp bucle
Listo:
push ecx
ret
endp
start:
stdcall lsStrlen,poison
mov [contador],ecx
invoke wsprintfA,hLen,"%d",[contador]
invoke MessageBox,0,hLen,0,0
invoke ExitProcess,0
.end start