Function at 0x40ba30
Capabilities:
Log keystrokes via polling

Disassembly:
mov eax, dword [esp + 4]
sub esp, 0xc
mov ecx, dword [eax + 4]
push ebx
push ebp
push esi
cmp ecx, 0x104
push edi
jne 0x40ba6a
mov dl, byte [0x4377ea]
test dl, dl
je 0x40ba6a
mov edx, dword [eax + 8]
cmp edx, 0x12
je 0x40ba5d
cmp edx, 0x79
jne 0x40ba6a
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0xc
ret
cmp ecx, 0x100
jne case.0x40bc0d.5
mov eax, dword [eax + 8]
lea ecx, [eax - 9]
cmp ecx, 0x69
ja case.0x40bc0d.5
mov esi, dword [0x43723c]
mov ebp, dword [0x437244]
mov edi, dword [0x437238]
mov eax, dword [0x4377f0]
xor edx, edx
mov dl, byte [ecx + 0x40c078]
jmp dword [edx*4 + 0x40c050]
push 0x10
call dword [sym.imp.USER32.dll_GetAsyncKeyState]
test ax, ax
jl 0x40bb0d
mov ecx, dword [0x4377f0]
mov eax, dword [0x437244]
cmp ecx, eax
jae 0x40bafb
mov eax, dword [0x43723c]
cmp byte [eax + ecx], 0
je 0x40bafb
lea eax, [ecx*8]
sub eax, ecx
lea edx, [eax + eax*2]
lea eax, [ecx + edx*2]
mov ecx, dword [0x437238]
lea eax, [ecx + eax*4]
cmp dword [eax + 8], 0x15
jne 0x40bafb
mov cl, byte [eax + 0x43]
test cl, cl
je case.0x40bc0d.5
call fcn.004166c0
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0xc
ret
call fcn.004167c0
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0xc
ret
mov eax, dword [0x4377f0]
mov ebp, dword [0x437244]
cmp eax, ebp
jae case.0x40bc0d.5
mov esi, dword [0x43723c]
cmp byte [esi + eax], 0
je case.0x40baa4.14
lea ecx, [eax*8]
sub ecx, eax
lea edx, [ecx + ecx*2]
lea ecx, [eax + edx*2]
cmp dword [edi + ecx*4 + 8], 0xa
jne case.0x40baa4.14
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0xc
ret
cmp eax, ebp
jae case.0x40bc0d.5
cmp byte [esi + eax], 0
je case.0x40bc0d.5
lea ecx, [eax*8]
sub ecx, eax
lea edx, [ecx + ecx*2]
lea eax, [eax + edx*2]
mov eax, dword [edi + eax*4 + 8]
add eax, 0xfffffffe
cmp eax, 7
ja case.0x40bc0d.5
jmp dword [eax*4 + 0x40c0e4]
call fcn.004168f0
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0xc
ret
cmp eax, ebp
jae case.0x40bc0d.5
cmp byte [esi + eax], 0
je case.0x40baa4.12
lea ecx, [eax*8]
sub ecx, eax
lea ecx, [ecx + ecx*2]
lea edx, [eax + ecx*2]
cmp dword [edi + edx*4 + 8], 0xa
jne case.0x40baa4.12
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0xc
ret
cmp eax, ebp
jae case.0x40bc0d.5
cmp byte [esi + eax], 0
je case.0x40bc0d.5
lea ecx, [eax*8]
sub ecx, eax
lea ecx, [ecx + ecx*2]
lea edx, [eax + ecx*2]
mov eax, dword [edi + edx*4 + 8]
add eax, 0xfffffffe
cmp eax, 7
ja case.0x40bc0d.5
jmp dword [eax*4 + 0x40c104]
call fcn.00416ad0
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0xc
ret
mov ecx, dword [0x4377f0]
mov eax, dword [0x437244]
mov edx, dword [0x437238]
cmp ecx, eax
jae case.0x40bc6c.4
mov eax, dword [0x43723c]
cmp byte [eax + ecx], 0
je case.0x40bc6c.4
lea eax, [ecx*8]
sub eax, ecx
lea eax, [eax + eax*2]
lea ecx, [ecx + eax*2]
mov eax, dword [edx + ecx*4 + 8]
add eax, 0xfffffffe
lea esi, [edx + ecx*4]
cmp eax, 0x13
ja case.0x40bc6c.4
xor ecx, ecx
mov cl, byte [eax + 0x40c130]
jmp dword [ecx*4 + 0x40c124]
mov edx, dword [esi]
mov edi, dword [sym.imp.USER32.dll_SendMessageA]
push 0
push 0x20
push 0x100
push edx
call edi
mov eax, dword [esi]
push 0
push 0x20
push 0x101
push eax
call edi
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0xc
ret
mov al, byte [esi + 0x43]
test al, al
je case.0x40bc0d.5
mov esi, dword [0x4377ec]
lea eax, [esi*8]
sub eax, esi
lea ecx, [eax + eax*2]
lea eax, [esi + ecx*2]
mov eax, dword [edx + eax*4 + 0x10]
cmp eax, esi
je case.0x40bc0d.5
mov edi, 3
lea ecx, [eax*8]
sub ecx, eax
lea ecx, [ecx + ecx*2]
lea ecx, [eax + ecx*2]
mov ebx, dword [edx + ecx*4 + 8]
lea ecx, [edx + ecx*4]
cmp ebx, edi
jne 0x40bcec
mov bl, byte [ecx + 0x43]
test bl, bl
je 0x40bcfd
mov eax, dword [ecx + 0x10]
cmp eax, esi
jne 0x40bccb
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0xc
ret
lea ecx, [eax*8]
mov dword [0x4377f0], eax
sub ecx, eax
lea ecx, [ecx + ecx*2]
lea esi, [eax + ecx*2]
shl esi, 2
mov edx, dword [esi + edx]
push edx
call dword [sym.imp.USER32.dll_SetFocus]
mov eax, dword [0x437238]
mov edi, dword [sym.imp.USER32.dll_SendMessageA]
push 0
push 0x20
mov ecx, dword [esi + eax]
push 0x100
push ecx
call edi
mov edx, dword [0x437238]
push 0
push 0x20
push 0x101
mov eax, dword [esi + edx]
push eax
call edi
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0xc
ret
mov ecx, dword [0x4377f0]
mov eax, dword [0x437244]
cmp ecx, eax
jae case.0x40bc0d.5
mov edx, dword [0x43723c]
cmp byte [edx + ecx], 0
je case.0x40bc0d.5
lea eax, [ecx*8]
mov edx, dword [0x437238]
sub eax, ecx
lea eax, [eax + eax*2]
lea ecx, [ecx + eax*2]
lea eax, [edx + ecx*4]
mov ecx, dword [edx + ecx*4 + 8]
cmp ecx, 0x14
jl case.0x40bc0d.5
cmp ecx, 0x15
jg case.0x40bc0d.5
mov cl, byte [eax + 0x43]
test cl, cl
jne case.0x40bc0d.5
mov eax, dword [0x437338]
test eax, eax
jne case.0x40bc0d.5
mov esi, dword [sym.imp.USER32.dll_GetAsyncKeyState]
push 0x11
call esi
test ax, ax
jge case.0x40bc0d.5
push 0x12
call esi
test ax, ax
jl case.0x40bc0d.5
mov eax, dword [0x437330]
test eax, eax
jne 0x40bdfa
mov ecx, 0x80
call fcn.0040d3a0
mov dword [0x437330], eax
mov byte [eax], 0
mov eax, dword [0x43733c]
test eax, eax
jne 0x40be13
push str.commdlg_FindReplace
call dword [sym.imp.USER32.dll_RegisterWindowMessageA]
mov dword [0x43733c], eax
mov eax, dword [0x437308]
mov dword [0x4372b0], 0x28
mov dword [0x4372b4], eax
mov al, byte [0x437334]
test al, al
mov dword [0x4372bc], 0x4000
je 0x40be44
mov dword [0x4372bc], 0x4004
mov al, byte [0x437335]
test al, al
je 0x40be59
mov eax, dword [0x4372bc]
or al, 2
mov dword [0x4372bc], eax
mov ecx, dword [0x437330]
mov edx, dword [0x4377f0]
push 0x4372b0
mov dword [0x4372c0], ecx
mov word [0x4372c8], 0x80
mov dword [0x4372cc], edx
call sub.comdlg32.dll_FindTextA
pop edi
pop esi
mov dword [0x437338], eax
pop ebp
mov eax, 1
pop ebx
add esp, 0xc
ret
mov ecx, dword [0x4377f0]
mov eax, dword [0x437244]
cmp ecx, eax
jae case.0x40bc0d.5
mov eax, dword [0x43723c]
cmp byte [eax + ecx], 0
je case.0x40bc0d.5
lea eax, [ecx*8]
sub eax, ecx
lea edx, [eax + eax*2]
lea eax, [ecx + edx*2]
mov ecx, dword [0x437238]
lea esi, [ecx + eax*4]
mov eax, dword [ecx + eax*4 + 8]
cmp eax, 0x14
jl case.0x40bc0d.5
cmp eax, 0x15
jg case.0x40bc0d.5
mov al, byte [esi + 0x43]
test al, al
jne case.0x40bc0d.5
mov edi, dword [sym.imp.USER32.dll_GetAsyncKeyState]
push 0x11
call edi
test ax, ax
jl case.0x40bc0d.5
push 0x10
call edi
test ax, ax
jl case.0x40bc0d.5
push 0x12
call edi
test ax, ax
jl case.0x40bc0d.5
mov eax, dword [0x437330]
test eax, eax
je 0x40bfba
cmp byte [eax], 0
je 0x40bfba
mov eax, dword [esi]
mov edi, dword [sym.imp.USER32.dll_SendMessageA]
lea edx, [esp + 0x10]
push edx
push 0
push 0x434
push eax
call edi
mov eax, dword [0x4372bc]
mov ecx, dword [0x437330]
mov ebp, dword [esp + 0x10]
lea edx, [esp + 0x10]
and eax, 6
mov dword [esp + 0x18], ecx
mov ecx, dword [esi]
push edx
push eax
inc ebp
push 0x438
push ecx
mov dword [esp + 0x20], ebp
mov dword [esp + 0x24], 0xffffffff
call edi
mov ebx, eax
test ebx, ebx
jl 0x40bfba
mov edx, dword [0x437330]
mov dword [esp + 0x10], ebx
push edx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov ecx, dword [esi]
add eax, ebx
mov dword [esp + 0x14], eax
lea eax, [esp + 0x10]
push eax
push 0
push 0x437
push ecx
call edi
mov edx, dword [esi]
push 0
push 0
push 0xb7
push edx
call edi
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0xc
ret
mov ecx, dword [0x436914]
mov eax, dword [0x437244]
cmp ecx, eax
jae case.0x40bc0d.5
mov eax, dword [0x43723c]
cmp byte [eax + ecx], 0
je case.0x40bc0d.5
lea eax, [ecx*8]
sub eax, ecx
lea edx, [eax + eax*2]
lea eax, [ecx + edx*2]
mov ecx, dword [0x437238]
lea ecx, [ecx + eax*4]
mov al, byte [ecx + 0x43]
test al, al
jne case.0x40bc0d.5
mov eax, dword [ecx + 8]
test eax, eax
je 0x40c03f
cmp eax, 1
je 0x40c03f
cmp eax, 2
je 0x40c03f
cmp eax, 3
je 0x40c03f
cmp eax, 4
je 0x40c03f
cmp eax, 6
je 0x40c03f
cmp eax, 0x11
je 0x40c03f
cmp eax, 0x12
je 0x40c03f
cmp eax, 0x13
jne case.0x40bc0d.5
pop edi
pop esi
pop ebp
mov byte [ecx + 0x44], 1
mov eax, 1
pop ebx
add esp, 0xc
ret