Function at 0x1002817
Capabilities:
Log keystrokes via polling

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x210
mov eax, dword [0x1046080]
push ebx
push esi
mov dword [ebp - 4], eax
mov esi, ecx
mov ecx, dword [ebp + 8]
mov eax, 0x8004
cmp ecx, eax
push edi
mov edi, dword [ebp + 0xc]
jg 0x1021cc8
je case.0x1002850.4
lea eax, [ecx - 1]
cmp eax, 0xe
ja case.0x1002850.8
jmp dword [eax*4 + 0x1002966]
push edi
mov ecx, esi
call fcn.01002797
cmp eax, 0xffffffff
jne 0x10047df
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
pop ebx
call fcn.01001aff
leave
ret 8
push 1
push dword [0x1046094]
call dword [sym.imp.USER32.dll_SwitchToThisWindow]
push dword [0x1046094]
call dword [sym.imp.USER32.dll_SetForegroundWindow]
jmp case.0x1002850.8
cmp edi, 0xffffffff
jne 0x10028a4
call fcn.0103aab5
jmp 0x1021cc0
mov eax, dword [esi + 0x68]
xor ebx, ebx
cmp dword [eax + 0x14], ebx
jne 0x10028eb
push 0x11
call dword [sym.imp.USER32.dll_GetAsyncKeyState]
test ax, ax
jl 0x10028eb
call dword [sym.imp.USER32.dll_GetForegroundWindow]
mov ecx, dword [0x1047450]
xor edx, edx
cmp eax, dword [0x1046094]
sete dl
cmp ecx, ebx
je 0x10028dd
cmp eax, ecx
jne 0x10028dd
xor edx, edx
inc edx
mov edi, dword [esi + 0x54]
cmp edi, ebx
jne 0x1002903
cmp edx, ebx
jne 0x10028eb
mov dword [esi + 0x54], eax
push ebx
push ebx
push 0x504
push dword [0x1046094]
call dword [sym.imp.USER32.dll_PostMessageW]
jmp 0x1021cc0
cmp edx, ebx
je 0x10028eb
mov ecx, esi
call fcn.0102df0a
push edi
call fcn.0103abd5
push edi
call dword [sym.imp.USER32.dll_SetForegroundWindow]
mov dword [esi + 0x54], ebx
jmp 0x1021cc0
xor ebx, ebx
push ebx
push ebx
push edi
call dword [sym.imp.USER32.dll_EndTask]
jmp case.0x1002850.8
shr edi, 0x10
and edi, 0xfff
push edi
mov ecx, esi
call fcn.0102d2d8
jmp 0x100286a
push edi
mov ecx, esi
call fcn.0102d5c4
jmp case.0x1002850.8
push 0xffffffffffffffff
push eax
push edi
mov ecx, esi
call fcn.010046f8
jmp case.0x1002850.8
push edi
mov ecx, esi
call fcn.010029a7
jmp case.0x1002850.8
push 1
push edi
mov ecx, esi
call fcn.01002b71
jmp case.0x1002850.8
push 1
xor ebx, ebx
push ebx
push eax
mov ecx, esi
call fcn.010021c0
or byte [eax + 5], 1
push ebx
push 0x64
push 4
push dword [esi + 0x20]
call dword [sym.imp.USER32.dll_SetTimer]
jmp case.0x1002850.8
push edi
mov ecx, esi
call fcn.010060fd
jmp case.0x1002850.8
mov dword [esi + 0x58], edi
jmp case.0x1002850.8
mov eax, dword [esi + 0x58]
xor ebx, ebx
cmp eax, ebx
je case.0x1002850.8
push 0xffffffffffffffff
push eax
mov ecx, esi
call fcn.01020786
push edi
mov ecx, esi
call fcn.01002797
cmp eax, 0xffffffff
mov dword [ebp - 0x210], eax
jne 0x1020d76
mov dword [esi + 0x58], ebx
jmp case.0x1002850.8
push 1
push ebx
push eax
mov ecx, esi
call fcn.010021c0
mov edi, eax
mov eax, dword [esi + 0x58]
mov dword [edi], eax
push 0x104
lea eax, [ebp - 0x20c]
push eax
push dword [esi + 0x58]
call fcn.01005a0d
push dword [ebp - 0x210]
mov ecx, esi
call fcn.010027e6
push 1
push ebx
push eax
mov ecx, esi
call fcn.010021c0
lea ecx, [ebp - 0x20c]
push ecx
push dword [eax + 0x14]
call dword [sym.imp.KERNEL32.dll_lstrcmpiW]
neg eax
sbb eax, eax
neg eax
mov dword [edi + 0x20], eax
jmp 0x1020d6e
lea eax, [edi + 4]
push eax
push dword [edi]
mov ecx, esi
call fcn.01021cdf
xor eax, eax
inc eax
jmp 0x100286a
mov eax, 0x8006
cmp ecx, eax
je 0x1002956
jmp case.0x1002850.8