Function at 0x40f258
Capabilities:
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xac
push esi
mov dword [ebp - 4], 2
mov eax, dword [ebp + 8]
cmp dword [eax + 4], 0x102
je 0x40f28d
mov ecx, dword [ebp + 8]
cmp dword [ecx + 4], 0x100
je 0x40f28d
mov edx, dword [ebp + 8]
cmp dword [edx + 4], 0x101
jne 0x40f299
mov eax, dword [ebp + 8]
mov cl, byte [eax + 8]
mov byte [0x4301fc], cl
mov edx, dword [0x42d9d0]
push edx
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
je 0x40fb5b
mov eax, dword [ebp + 8]
mov ecx, dword [eax]
push ecx
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
je 0x40fb5b
mov edx, dword [ebp + 8]
mov eax, dword [edx]
push eax
call dword [sym.imp.USER32.dll_GetParent]
mov dword [ebp - 0x24], eax
call fcn.0040b06f
mov dword [ebp - 0x10], eax
mov ecx, dword [ebp - 0x24]
push ecx
call fcn.0041d58c
add esp, 4
mov dword [ebp - 0x98], eax
push 0x19
lea edx, [ebp - 0x88]
push edx
mov eax, dword [ebp + 8]
mov ecx, dword [eax]
push ecx
call dword [sym.imp.USER32.dll_GetClassNameA]
mov edx, dword [ebp - 0x24]
cmp edx, dword [ebp - 0x10]
jne 0x40fb5b
cmp dword [ebp - 0x98], 0xffffffff
jle 0x40fb5b
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 4]
mov dword [ebp - 0xa4], ecx
cmp dword [ebp - 0xa4], 0x100
je 0x40f545
cmp dword [ebp - 0xa4], 0x101
je 0x40f352
cmp dword [ebp - 0xa4], 0x102
je 0x40f357
jmp 0x40fb54
jmp 0x40fb5b
mov edx, dword [ebp + 8]
cmp dword [edx + 8], 9
je 0x40f391
mov eax, dword [ebp + 8]
cmp dword [eax + 8], 0x1b
je 0x40f391
push 0
push 0
push 0x42c47c
lea ecx, [ebp - 0x88]
push ecx
call fcn.0040a67d
add esp, 0x10
test eax, eax
je 0x40f391
mov byte [0x4301fc], 1
jmp 0x40f540
mov edx, dword [ebp - 0x98]
imul edx, edx, 0x1bc
mov eax, dword [ebp + 8]
mov ecx, dword [edx + 0x42e7fc]
cmp ecx, dword [eax]
jne 0x40f4fd
xor edx, edx
mov dl, byte [0x4301fc]
cmp edx, 8
je 0x40f4fd
xor eax, eax
mov al, byte [0x4301fc]
push eax
mov ecx, dword [ebp - 0x98]
imul ecx, ecx, 0x1bc
add ecx, 0x42e870
push ecx
call fcn.00408d31
add esp, 8
test eax, eax
jne 0x40f444
xor edx, edx
mov dl, byte [0x4301fc]
push edx
call dword [sym.imp.USER32.dll_CharUpperA]
mov byte [0x4301fc], al
xor eax, eax
mov al, byte [0x4301fc]
mov ecx, dword [ebp + 8]
mov dword [ecx + 8], eax
xor edx, edx
mov dl, byte [0x4301fc]
push edx
mov eax, dword [ebp - 0x98]
imul eax, eax, 0x1bc
add eax, 0x42e870
push eax
call fcn.00408d31
add esp, 8
test eax, eax
jne 0x40f444
mov byte [0x4301fc], 0
push 0x30
call dword [sym.imp.USER32.dll_MessageBeep]
mov dword [ebp - 4], 0
xor ecx, ecx
mov cl, byte [0x4301fc]
test ecx, ecx
je 0x40f4fb
push 0
push 0
push 0xe
mov edx, dword [0x42c69c]
imul edx, edx, 0x1bc
mov eax, dword [edx + 0x42e7fc]
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
mov ecx, dword [0x42c69c]
imul ecx, ecx, 0x1bc
cmp eax, dword [ecx + 0x42e864]
jl 0x40f4fb
push 0
push 0
push 0xb0
mov edx, dword [0x42c69c]
imul edx, edx, 0x1bc
mov eax, dword [edx + 0x42e7fc]
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
mov esi, eax
and esi, 0xffff
and esi, 0xffff
push 0
push 0
push 0xb0
mov ecx, dword [0x42c69c]
imul ecx, ecx, 0x1bc
mov edx, dword [ecx + 0x42e7fc]
push edx
call dword [sym.imp.USER32.dll_SendMessageA]
shr eax, 0x10
and eax, 0xffff
cmp esi, eax
jne 0x40f4fb
mov byte [0x4301fc], 0
push 0x30
call dword [sym.imp.USER32.dll_MessageBeep]
mov dword [ebp - 4], 0
jmp 0x40f540
mov eax, dword [ebp - 0x98]
imul eax, eax, 0x1bc
mov ecx, dword [ebp + 8]
mov edx, dword [ecx]
cmp edx, dword [eax + 0x42e800]
jne 0x40f540
mov eax, dword [ebp - 0x98]
imul eax, eax, 0x1bc
mov ecx, dword [ebp + 8]
mov edx, dword [ecx]
cmp edx, dword [eax + 0x42e7fc]
je 0x40f540
mov eax, dword [ebp + 8]
cmp dword [eax + 8], 0x20
je 0x40f540
push 0x30
call dword [sym.imp.USER32.dll_MessageBeep]
jmp 0x40fb5b
mov ecx, dword [ebp - 0x98]
imul ecx, ecx, 0x1bc
mov edx, dword [ecx + 0x42e7d8]
xor eax, eax
cmp edx, dword [0x42e148]
setne al
mov dword [ebp - 0x90], eax
push 0x11
call dword [sym.imp.USER32.dll_GetKeyState]
movsx ecx, ax
and ecx, 0x8000
neg ecx
sbb ecx, ecx
neg ecx
mov dword [ebp - 0xc], ecx
push 0x10
call dword [sym.imp.USER32.dll_GetKeyState]
movsx edx, ax
and edx, 0x8000
neg edx
sbb edx, edx
neg edx
mov dword [ebp - 0x14], edx
mov dword [ebp - 0x1c], 0
mov eax, dword [ebp - 0x98]
imul eax, eax, 0x1bc
mov ecx, dword [eax + 0x42e7d8]
push ecx
call fcn.00409520
add esp, 4
mov dword [ebp - 0x8c], eax
mov edx, dword [ebp - 0x8c]
mov dword [ebp - 8], edx
cmp dword [ebp - 0x90], 0
je 0x40f5ef
mov eax, dword [ebp - 0x98]
imul eax, eax, 0x1bc
mov ecx, dword [eax + 0x42e7fc]
push ecx
call dword [sym.imp.USER32.dll_HideCaret]
mov edx, dword [ebp - 8]
cmp dword [edx + 0x3c], 0
jne 0x40f6ce
mov dword [ebp - 0x1c], 1
mov eax, dword [ebp - 0x98]
imul eax, eax, 0x1bc
mov ecx, dword [eax + 0x42e7d8]
push ecx
call fcn.00407862
add esp, 4
mov edx, dword [ebp - 8]
mov dword [edx + 0x3c], eax
mov eax, dword [ebp - 8]
mov ecx, dword [eax + 0xe]
push ecx
mov edx, dword [ebp - 8]
mov eax, dword [edx + 0x3c]
push eax
call dword [sym.imp.GDI32.dll_SelectObject]
mov dword [ebp - 0x94], eax
mov ecx, dword [ebp - 0x94]
push ecx
call fcn.0040943f
add esp, 4
mov edx, dword [ebp - 8]
mov eax, dword [edx + 0xe]
push eax
call fcn.00409368
add esp, 4
mov ecx, dword [ebp - 8]
mov edx, dword [ecx + 0x2c]
push edx
mov eax, dword [ebp - 8]
mov ecx, dword [eax + 0x3c]
push ecx
call dword [sym.imp.GDI32.dll_SetTextColor]
mov edx, dword [ebp - 8]
mov eax, dword [edx + 0x30]
push eax
mov ecx, dword [ebp - 8]
mov edx, dword [ecx + 0x3c]
push edx
call dword [sym.imp.GDI32.dll_SetBkColor]
push 1
mov eax, dword [ebp - 8]
mov ecx, dword [eax + 0x3c]
push ecx
call dword [sym.imp.GDI32.dll_SetBkMode]
mov edx, dword [ebp - 8]
cmp dword [edx + 0x38], 0
je 0x40f6ce
mov eax, dword [ebp - 8]
mov ecx, dword [eax + 0x38]
push ecx
mov edx, dword [ebp - 8]
mov eax, dword [edx + 0x3c]
push eax
call dword [sym.imp.GDI32.dll_SelectObject]
mov dword [ebp - 0x18], eax
mov ecx, dword [ebp - 0x18]
push ecx
call fcn.0040943f
add esp, 4
mov edx, dword [ebp - 8]
mov eax, dword [edx + 0x38]
push eax
call fcn.00409368
add esp, 4
mov ecx, dword [ebp - 0x98]
imul ecx, ecx, 0x1bc
mov edx, dword [ecx + 0x42e7d8]
mov dword [0x42e148], edx
mov eax, dword [ebp - 8]
mov ecx, dword [eax + 0x3c]
mov dword [0x42e14c], ecx
mov edx, dword [ebp - 0x98]
mov dword [0x42c69c], edx
mov dword [0x430d48], 0
xor eax, eax
mov al, byte [0x4301fc]
cmp eax, 0x1b
jne 0x40f746
mov ecx, dword [0x42c69c]
imul ecx, ecx, 0x1bc
cmp dword [ecx + 0x42e7f0], 0
je 0x40f72e
call fcn.0040d834
mov dword [0x430d48], 0
mov byte [0x4301fc], 0
mov dword [ebp - 4], 0
xor edx, edx
mov dl, byte [0x4301fc]
mov dword [ebp - 0xa8], edx
mov eax, dword [ebp - 0xa8]
sub eax, 8
mov dword [ebp - 0xa8], eax
cmp dword [ebp - 0xa8], 0x26
ja case.0x40f77e.3
mov edx, dword [ebp - 0xa8]
xor ecx, ecx
mov cl, byte [edx + 0x40fb73]
jmp dword [ecx*4 + 0x40fb63]
mov eax, dword [0x42c69c]
imul eax, eax, 0x1bc
mov ecx, dword [0x42c69c]
imul ecx, ecx, 0x1bc
mov edx, dword [eax + 0x42e7fc]
cmp edx, dword [ecx + 0x42e800]
jne 0x40f7d0
mov eax, dword [0x42c69c]
imul eax, eax, 0x1bc
cmp dword [eax + 0x42e844], 1
jle 0x40f7d0
cmp dword [ebp - 0xc], 0
je 0x40f7d0
mov dword [0x430d48], 0
jmp 0x40f817
mov ecx, dword [0x42c69c]
imul ecx, ecx, 0x1bc
mov edx, dword [ecx + 0x42e7d8]
push edx
call fcn.0041f0f5
add esp, 4
test eax, eax
je 0x40f7fb
mov dword [0x430d48], 0xd
jmp 0x40f817
cmp dword [ebp - 0xc], 0
je 0x40f80d
mov dword [0x430d48], 0xd
jmp 0x40f817
mov dword [0x430d48], 0xb
jmp case.0x40f77e.3
cmp dword [ebp - 0x14], 0
je 0x40f82b
mov dword [0x430d48], 0xf
jmp 0x40f835
mov dword [0x430d48], 0xc
jmp case.0x40f77e.3
mov eax, dword [0x42c69c]
imul eax, eax, 0x1bc
cmp dword [eax + 0x42e85c], 6
jne case.0x40f77e.3
mov dword [0x430d48], 7
cmp dword [0x430d48], 0xd
jne 0x40f8f2
mov ecx, dword [0x42c69c]
imul ecx, ecx, 0x1bc
mov edx, dword [ecx + 0x42e7ec]
mov dword [ebp - 0x20], edx
mov eax, dword [0x42c69c]
imul eax, eax, 0x1bc
cmp dword [eax + 0x42e800], 0
je 0x40f8c8
push 0
push 0
push 0x87
mov ecx, dword [0x42c69c]
imul ecx, ecx, 0x1bc
mov edx, dword [ecx + 0x42e800]
push edx
call dword [sym.imp.USER32.dll_SendMessageA]
and eax, 0x10
test eax, eax
je 0x40f8c8
mov eax, dword [0x42c69c]
imul eax, eax, 0x1bc
mov ecx, dword [eax + 0x42e800]
mov dword [ebp - 0x20], ecx
cmp dword [ebp - 0x20], 0
je 0x40f8f2
mov edx, dword [ebp - 0x20]
push edx
call fcn.0040d7c7
add esp, 4
mov dword [0x430d48], 0
mov byte [0x4301fc], 0
mov dword [ebp - 4], 0
xor eax, eax
mov al, byte [0x4301fc]
test eax, eax
je 0x40f993
mov ecx, dword [0x42c69c]
imul ecx, ecx, 0x1bc
cmp dword [ecx + 0x42e848], 0
je 0x40f993
mov edx, dword [0x42c69c]
imul edx, edx, 0x1bc
cmp dword [edx + 0x42e85c], 6
jne 0x40f972
cmp dword [0x430d48], 0xe
je 0x40f958
cmp dword [0x430d48], 0xa
je 0x40f958
cmp dword [0x430d48], 9
je 0x40f958
cmp dword [0x430d48], 8
je 0x40f958
cmp dword [0x430d48], 7
jne 0x40f970
mov dword [0x430d48], 0
mov byte [0x4301fc], 0
mov dword [ebp - 4], 0
jmp 0x40f993
cmp dword [0x430d48], 0
je 0x40f993
mov byte [0x4301fc], 0
mov dword [0x430d48], 0
mov dword [ebp - 4], 0
mov eax, dword [0x430d48]
mov dword [ebp - 0xac], eax
mov ecx, dword [ebp - 0xac]
sub ecx, 0xa
mov dword [ebp - 0xac], ecx
cmp dword [ebp - 0xac], 5
ja case.0x40f9c0.3
mov edx, dword [ebp - 0xac]
jmp dword [edx*4 + 0x40fb9a]
cmp dword [0x430810], 0
jne 0x40fa36
mov eax, dword [0x42c69c]
imul eax, eax, 0x1bc
mov ecx, dword [eax + 0x42e850]
mov edx, dword [0x4304e8]
cmp dword [edx + ecx*4], 0
je 0x40fa36
mov eax, dword [0x42c69c]
imul eax, eax, 0x1bc
mov ecx, dword [eax + 0x42e848]
mov dword [ebp - 0x9c], ecx
mov edx, dword [0x42c69c]
imul edx, edx, 0x1bc
mov eax, dword [edx + 0x42e84c]
mov dword [ebp - 0xa0], eax
mov ecx, dword [0x42c69c]
imul ecx, ecx, 0x1bc
mov edx, dword [ecx + 0x42e850]
mov eax, dword [0x4304e8]
call dword [eax + edx*4]
mov byte [0x4301fc], 0
mov dword [ebp - 4], 0
mov dword [0x430d48], 0
cmp dword [ebp - 0x1c], 0
je 0x40fae7
mov ecx, dword [ebp - 0x8c]
mov dword [ebp - 8], ecx
mov edx, dword [ebp - 8]
mov eax, dword [edx + 0xe]
push eax
call fcn.0040943f
add esp, 4
mov ecx, dword [ebp - 8]
cmp dword [ecx + 0x38], 0
je 0x40fa88
mov edx, dword [ebp - 8]
mov eax, dword [edx + 0x38]
push eax
call fcn.0040943f
add esp, 4
mov ecx, dword [ebp - 0x94]
push ecx
mov edx, dword [ebp - 8]
mov eax, dword [edx + 0x3c]
push eax
call dword [sym.imp.GDI32.dll_SelectObject]
cmp dword [ebp - 0x18], 0
je 0x40fab3
mov ecx, dword [ebp - 0x18]
push ecx
mov edx, dword [ebp - 8]
mov eax, dword [edx + 0x3c]
push eax
call dword [sym.imp.GDI32.dll_SelectObject]
mov ecx, dword [ebp - 8]
mov edx, dword [ecx + 0x3c]
push edx
mov eax, dword [ebp - 0x98]
imul eax, eax, 0x1bc
mov ecx, dword [eax + 0x42e7d8]
push ecx
call dword [sym.imp.USER32.dll_ReleaseDC]
mov edx, dword [ebp - 8]
mov dword [edx + 0x3c], 0
mov dword [0x42e14c], 0
mov eax, dword [ebp - 0x98]
mov dword [0x42c69c], eax
cmp dword [ebp - 0x90], 0
je 0x40fb14
mov ecx, dword [0x42c69c]
imul ecx, ecx, 0x1bc
mov edx, dword [ecx + 0x42e7fc]
push edx
call dword [sym.imp.USER32.dll_ShowCaret]
mov eax, dword [0x42c69c]
cmp eax, dword [0x430dc8]
jge 0x40fb3e
mov ecx, dword [0x42c69c]
imul ecx, ecx, 0x1bc
mov edx, dword [ecx + 0x42e7d8]
push edx
call fcn.00409825
add esp, 4
jmp 0x40fb52
mov dword [0x42e148], 0
mov dword [0x42e14c], 0
jmp 0x40fb5b
mov dword [ebp - 4], 1
mov eax, dword [ebp - 4]
pop esi
mov esp, ebp
pop ebp
ret