Function at 0x4f4660
Capabilities:
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x2c
mov eax, dword [ebp + 8]
cmp dword [eax + 4], 0x201
push ebx
push esi
push edi
mov edi, ecx
mov dword [esp + 0x20], 0
jne 0x4f49de
lea ecx, [esp + 0x1c]
push ecx
mov esi, eax
lea edx, [esp + 0x28]
push edx
add esi, 0x14
push esi
mov ecx, edi
mov dword [edi + 0x318], 0xffffffff
call fcn.004f4250
test eax, eax
mov dword [esp + 0x14], eax
je 0x4f482b
mov ecx, eax
call fcn.004f41d0
mov esi, dword [sym.imp.USER32.dll_GetKeyState]
push 0x10
mov dword [esp + 0x10], eax
call esi
test ax, ax
jge 0x4f47a0
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0xc]
mov ebx, dword [esp + 0x1c]
push 1
push eax
push ecx
mov esi, ebx
call fcn.004f4590
mov eax, dword [edi + 0x314]
test eax, eax
jl 0x4f47e0
cmp eax, ebx
jae 0x4f4704
mov esi, eax
mov eax, ebx
mov dword [esp + 0x24], ebx
jmp 0x4f4708
mov dword [esp + 0x24], eax
cmp esi, eax
jae 0x4f47e0
test esi, esi
jl 0x4f479b
cmp esi, dword [edi + 0x2f4]
jge 0x4f479b
mov edx, dword [edi + 0x2f0]
cmp dword [edx + esi*4], 0
jne 0x4f478c
cmp esi, dword [edi + 0x2f4]
jge 0x4f478c
mov eax, edx
lea ecx, [esi + 1]
mov dword [eax + esi*4], 1
mov eax, dword [esp + 0xc]
push ecx
call fcn.004ef460
mov ebx, eax
test ebx, ebx
je 0x4f4788
cmp esi, dword [edi + 0x308]
jge 0x4f479b
mov edx, dword [edi + 0x304]
mov eax, dword [edx + esi*4]
mov ecx, dword [ebx]
cmp eax, dword [edi + 0x13c]
mov eax, dword [ecx + 0x28]
jne 0x4f4776
mov edx, dword [edi + 0x324]
jmp 0x4f477c
mov edx, dword [edi + 0x31c]
push edx
push ebx
call eax
mov ecx, dword [ebx]
mov edx, dword [ecx + 8]
push ebx
call edx
mov ebx, dword [esp + 0x1c]
add esi, 1
cmp esi, dword [esp + 0x24]
jb 0x4f4710
jmp 0x4f47e0
call fcn.00555520
push 0x11
call esi
test ax, ax
mov ebx, dword [esp + 0x1c]
jge 0x4f48f2
test ebx, ebx
jl 0x4f479b
cmp ebx, dword [edi + 0x2f4]
jge 0x4f479b
mov eax, dword [edi + 0x2f0]
cmp dword [eax + ebx*4], 0
mov esi, ebx
jne 0x4f48e1
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0xc]
push 1
push ecx
push edx
call fcn.004f4590
mov eax, dword [ebp + 8]
mov dword [edi + 0x314], ebx
mov ebx, 1
lea esi, [eax + 0x14]
mov dword [eax + 0x18], ebx
mov eax, dword [esp + 0x14]
mov dword [esi], ebx
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
call edx
mov eax, dword [edi + 0xf0]
push eax
mov dword [edi + 0x32c], ebx
call dword [sym.imp.USER32.dll_SetCapture]
push eax
call fcn.00558074
mov eax, dword [esp + 0xc]
test eax, eax
je 0x4f482b
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
call edx
push esi
mov ecx, edi
call fcn.004f4440
mov ebx, eax
test ebx, ebx
mov dword [esp + 0x14], ebx
je 0x4f49de
mov ecx, ebx
call fcn.004f41d0
xor esi, esi
cmp dword [edi + 0x2f4], esi
mov dword [esp + 0x24], eax
jle 0x4f49c6
lea ebx, [ebx]
test esi, esi
jl 0x4f479b
cmp esi, dword [edi + 0x2f4]
jge 0x4f479b
mov eax, dword [edi + 0x2f0]
cmp dword [eax + esi*4], 1
jne 0x4f49b3
cmp esi, dword [edi + 0x2f4]
jge 0x4f49b3
mov ecx, eax
mov eax, dword [esp + 0x24]
lea edx, [esi + 1]
push edx
mov dword [ecx + esi*4], 0
call fcn.004ef460
mov ebx, eax
test ebx, ebx
je 0x4f49b3
cmp esi, dword [edi + 0x308]
jge 0x4f479b
mov eax, dword [edi + 0x304]
mov ecx, dword [eax + esi*4]
mov edx, dword [ebx]
cmp ecx, dword [edi + 0x13c]
mov ecx, dword [edx + 0x28]
jne 0x4f49a1
mov eax, dword [edi + 0x328]
jmp 0x4f49a7
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0xc]
push 0
push eax
push ecx
jmp 0x4f47db
test ebx, ebx
jl 0x4f479b
cmp ebx, dword [edi + 0x2f4]
jge 0x4f479b
mov edx, dword [edi + 0x2f0]
cmp dword [edx + ebx*4], 0
je 0x4f4931
push 0x7f86
push 0
mov dword [edi + 0x318], ebx
call dword [sym.imp.USER32.dll_LoadCursorW]
push eax
call dword [sym.imp.USER32.dll_SetCursor]
jmp 0x4f47e0
xor eax, eax
cmp dword [edi + 0x2f4], eax
mov dword [esp + 0x1c], eax
jle 0x4f47e0
cmp eax, ebx
jne 0x4f4957
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0xc]
push 1
push eax
push ecx
mov esi, ebx
jmp 0x4f4984
test eax, eax
jl 0x4f479b
cmp eax, dword [edi + 0x2f4]
jge 0x4f479b
mov edx, dword [edi + 0x2f0]
cmp dword [edx + eax*4], 1
jne 0x4f498d
mov eax, dword [esp + 0xc]
mov esi, dword [esp + 0x1c]
push 0
push 0
push eax
call fcn.004f4590
mov eax, dword [esp + 0x1c]
add eax, 1
cmp eax, dword [edi + 0x2f4]
mov dword [esp + 0x1c], eax
jl 0x4f4943
jmp 0x4f47e0
mov eax, dword [edi + 0x320]
push eax
push ebx
call ecx
mov edx, dword [ebx]
mov eax, dword [edx + 8]
push ebx
call eax
add esi, 1
cmp esi, dword [edi + 0x2f4]
jl 0x4f4860
mov ebx, dword [esp + 0x14]
mov ecx, dword [ebx]
mov edx, dword [ecx + 8]
push ebx
call edx
mov eax, dword [esp + 0x24]
test eax, eax
je 0x4f49de
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
call edx
mov esi, dword [ebp + 8]
mov eax, dword [esi + 4]
cmp eax, 0x200
jne 0x4f4d08
cmp dword [edi + 0x32c], 0
je 0x4f4d57
cmp dword [edi + 0x318], 0
jge 0x4f4b9c
mov ebx, dword [sym.imp.USER32.dll_GetKeyState]
push 0x11
call ebx
test ax, ax
jl 0x4f4b9c
push 0x10
call ebx
test ax, ax
jl 0x4f4b9c
lea ecx, [esp + 0x20]
push ecx
lea edx, [esp + 0x28]
lea eax, [esi + 0x14]
push edx
push eax
mov ecx, edi
call fcn.004f4250
test eax, eax
mov dword [esp + 0x14], eax
je 0x4f4b3a
mov esi, eax
mov ecx, esi
call fcn.004f41d0
xor ebx, ebx
cmp dword [edi + 0x2f4], ebx
mov dword [esp + 0x1c], eax
jle 0x4f4b2f
mov ecx, dword [esp + 0x20]
cmp ebx, ecx
jne 0x4f4aa3
test ebx, ebx
jl 0x4f479b
cmp ebx, dword [edi + 0x2f4]
jge 0x4f479b
mov eax, dword [edi + 0x2f0]
cmp dword [eax + ebx*4], 0
jne 0x4f4b1c
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x1c]
mov esi, dword [esp + 0x20]
push 1
push ecx
push edx
jmp 0x4f4b17
mov eax, dword [edi + 0x314]
cmp ebx, eax
jl 0x4f4acb
cmp ebx, ecx
jg 0x4f4ac7
lea ecx, [edi + 0x2ec]
mov eax, ebx
call fcn.004bfa80
cmp dword [eax], 0
jne 0x4f4b1c
push 1
jmp 0x4f4b0e
cmp ebx, eax
jg 0x4f4aec
cmp ebx, ecx
jl 0x4f4aec
lea ecx, [edi + 0x2ec]
mov eax, ebx
call fcn.004bfa80
cmp dword [eax], 0
jne 0x4f4b1c
mov ecx, dword [esp + 0x1c]
push 1
push 0
push ecx
jmp 0x4f4b15
test ebx, ebx
jl 0x4f479b
cmp ebx, dword [edi + 0x2f4]
jge 0x4f479b
mov edx, dword [edi + 0x2f0]
cmp dword [edx + ebx*4], 0
je 0x4f4b1c
push 0
mov eax, dword [esp + 0x20]
push 0
push eax
mov esi, ebx
call fcn.004f4590
add ebx, 1
cmp ebx, dword [edi + 0x2f4]
jl 0x4f4a65
mov esi, dword [esp + 0x14]
mov ecx, dword [esi]
mov edx, dword [ecx + 8]
push esi
call edx
mov esi, dword [ebp + 8]
mov ecx, dword [edi + 0x20]
lea eax, [esp + 0x28]
push eax
push ecx
call dword [sym.imp.USER32.dll_GetClientRect]
mov edx, dword [esi + 0x14]
mov eax, dword [esi + 0x18]
lea ecx, [esp + 0xc]
mov dword [esp + 0xc], edx
mov edx, dword [edi + 0x20]
push ecx
push edx
mov dword [esp + 0x18], eax
call dword [sym.imp.USER32.dll_ScreenToClient]
mov ecx, edi
mov dword [esp + 0x20], 0xffffffff
call fcn.004eb260
mov ebx, eax
test ebx, ebx
je 0x4f4b93
mov eax, dword [ebx]
mov edx, dword [eax + 0x14c]
lea ecx, [esp + 0x20]
push ecx
push ebx
call edx
mov eax, dword [ebx]
mov ecx, dword [eax + 8]
push ebx
call ecx
mov eax, dword [esp + 0x10]
jmp 0x4f4cb4
cmp dword [edi + 0x32c], 0
je 0x4f4d57
cmp dword [edi + 0x318], 0
jl 0x4f4d57
push 0x7f86
push 0
call dword [sym.imp.USER32.dll_LoadCursorW]
push eax
call dword [sym.imp.USER32.dll_SetCursor]
lea edx, [esp + 0x1c]
push edx
lea eax, [esp + 0x28]
push eax
lea ebx, [esi + 0x14]
push ebx
mov ecx, edi
call fcn.004f4250
test eax, eax
mov dword [esp + 0x24], eax
jne 0x4f4bfb
push eax
call dword [sym.imp.USER32.dll_MessageBeep]
push 0xa0
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x4f4c58
mov ecx, dword [edi + 0x318]
cmp ecx, dword [esp + 0x1c]
je 0x4f4c50
mov edx, dword [esp + 0x1c]
push edx
mov eax, ecx
mov esi, edi
call fcn.004f5230
test eax, eax
je 0x4f4c36
mov eax, dword [esp + 0x1c]
mov ecx, dword [edi + 0x318]
push eax
push ecx
call fcn.004f52b0
mov edx, dword [esp + 0x1c]
mov dword [edi + 0x318], edx
jmp 0x4f4c49
push 0
call dword [sym.imp.USER32.dll_MessageBeep]
push 0xa0
call dword [sym.imp.KERNEL32.dll_Sleep]
mov esi, dword [ebp + 8]
mov eax, dword [esp + 0x24]
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
call edx
mov ecx, dword [edi + 0x20]
lea eax, [esp + 0x28]
push eax
push ecx
call dword [sym.imp.USER32.dll_GetClientRect]
mov edx, dword [ebx]
mov eax, dword [ebx + 4]
lea ecx, [esp + 0x14]
mov dword [esp + 0x14], edx
mov edx, dword [edi + 0x20]
push ecx
push edx
mov dword [esp + 0x20], eax
call dword [sym.imp.USER32.dll_ScreenToClient]
mov ecx, edi
mov dword [esp + 0x20], 0xffffffff
call fcn.004eb260
mov ebx, eax
test ebx, ebx
je 0x4f4cb0
mov eax, dword [ebx]
mov edx, dword [eax + 0x14c]
lea ecx, [esp + 0x20]
push ecx
push ebx
call edx
mov eax, dword [ebx]
mov ecx, dword [eax + 8]
push ebx
call ecx
mov eax, dword [esp + 0x18]
test eax, eax
jge 0x4f4cdf
mov eax, dword [esp + 0x20]
test eax, eax
jle 0x4f4cfe
mov edx, dword [edi + 0x20]
add eax, 0xffffffec
push eax
push 0
push 0x6c6
push edx
call dword [sym.imp.USER32.dll_PostMessageW]
mov dword [esp + 0x20], 1
jmp 0x4f4d57
cmp eax, dword [esp + 0x34]
jle 0x4f4cfe
mov eax, dword [esp + 0x20]
mov ecx, dword [edi + 0x20]
add eax, 0x14
push eax
push 0
push 0x6c6
push ecx
call dword [sym.imp.USER32.dll_PostMessageW]
mov dword [esp + 0x20], 1
jmp 0x4f4d57
cmp eax, 0x202
jne 0x4f4d57
mov dword [edi + 0x32c], 0
mov dword [edi + 0x318], 0xffffffff
call dword [sym.imp.USER32.dll_ReleaseCapture]
lea edx, [esp + 0x24]
push edx
lea eax, [esp + 0x20]
push eax
lea ebx, [esi + 0x14]
push ebx
mov ecx, edi
call fcn.004f4250
test eax, eax
je 0x4f4d57
mov dword [ebx], 1
mov dword [esi + 0x18], 1
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
call edx
cmp dword [esi + 4], 0x204
jne 0x4f4e98
lea eax, [esp + 0x1c]
push eax
lea ecx, [esp + 0x28]
push ecx
lea edx, [esi + 0x14]
push edx
mov ecx, edi
call fcn.004f4250
test eax, eax
mov dword [esp + 0x14], eax
je 0x4f4e98
mov esi, dword [esp + 0x1c]
test esi, esi
jl 0x4f479b
cmp esi, dword [edi + 0x2f4]
jge 0x4f479b
mov eax, dword [edi + 0x2f0]
cmp dword [eax + esi*4], 0
jne 0x4f4e81
mov ecx, dword [esp + 0x14]
call fcn.004f41d0
xor ebx, ebx
cmp dword [edi + 0x2f4], ebx
mov dword [esp + 0x24], eax
jle 0x4f4e81
jmp 0x4f4dd4
mov esi, dword [esp + 0x1c]
cmp ebx, esi
jne 0x4f4df2
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x24]
mov esi, dword [esp + 0x1c]
push 1
push ecx
push edx
call fcn.004f4590
jmp 0x4f4e72
test ebx, ebx
jl 0x4f479b
cmp ebx, dword [edi + 0x2f4]
jge 0x4f479b
mov eax, dword [edi + 0x2f0]
cmp dword [eax + ebx*4], 1
jne 0x4f4e72
cmp ebx, dword [edi + 0x2f4]
jge 0x4f4e72
mov ecx, eax
mov eax, dword [esp + 0x24]
lea edx, [ebx + 1]
push edx
mov dword [ecx + ebx*4], 0
call fcn.004ef460
mov esi, eax
test esi, esi
je 0x4f4e72
cmp ebx, dword [edi + 0x308]
jge 0x4f479b
mov eax, dword [edi + 0x304]
mov ecx, dword [eax + ebx*4]
mov edx, dword [esi]
cmp ecx, dword [edi + 0x13c]
mov ecx, dword [edx + 0x28]
jne 0x4f4e60
mov eax, dword [edi + 0x328]
jmp 0x4f4e66
mov eax, dword [edi + 0x320]
push eax
push esi
call ecx
mov edx, dword [esi]
mov eax, dword [edx + 8]
push esi
call eax
add ebx, 1
cmp ebx, dword [edi + 0x2f4]
jl 0x4f4dd0
mov eax, dword [esp + 0x14]
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
mov dword [esp + 0x24], 1
call edx
mov esi, dword [ebp + 8]
mov eax, dword [esi + 4]
cmp eax, 0x205
jne 0x4f4f0d
mov esi, dword [ebp + 8]
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x20]
push ecx
add esi, 0x14
push esi
mov ecx, edi
call fcn.004f4250
mov ebx, eax
test ebx, ebx
je 0x4f4eec
push 0
push esi
push edi
call fcn.004f3040
mov edx, dword [ebx]
mov eax, dword [edx + 8]
push ebx
call eax
cmp dword [esp + 0x20], 0
jne 0x4f4f4a
mov ecx, dword [ebp + 8]
push ecx
mov ecx, edi
call fcn.004ec600
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
push esi
mov ecx, edi
call fcn.004f4440
mov ebx, eax
test ebx, ebx
je 0x4f4ed1
push 1
push esi
push edi
call fcn.004f3040
mov ecx, dword [ebx]
mov edx, dword [ecx + 8]
push ebx
call edx
jmp 0x4f4ed1
cmp eax, 0x203
jne 0x4f4ed1
lea eax, [esp + 0x1c]
push eax
lea ecx, [esp + 0x28]
push ecx
add esi, 0x14
push esi
mov ecx, edi
call fcn.004f4250
mov esi, eax
test esi, esi
je 0x4f4ed1
mov eax, dword [0x63c454]
test eax, eax
je 0x4f4f42
mov ecx, dword [esp + 0x24]
push eax
call fcn.004870a0
mov edx, dword [esi]
mov eax, dword [edx + 8]
push esi
call eax
pop edi
pop esi
mov eax, 1
pop ebx
mov esp, ebp
pop ebp
ret 4