Function at 0x4104f0
Capabilities:
Log keystrokes via polling

Disassembly:
sub esp, 0x11c
push ebx
mov bl, byte [esp + 0x128]
push ebp
mov ebp, dword [esp + 0x128]
push esi
movzx eax, bl
push edi
mov edi, dword [esp + 0x138]
or ax, di
je 0x410b0b
cmp dword [esp + 0x144], 0
jne 0x410530
mov dword [esp + 0x144], 0xffc3d44d
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp eax, dword [0x4ab1d8]
mov eax, dword [0x4acb4c]
sete byte [esp + 0x11]
test eax, eax
je 0x410556
cmp byte [esp + 0x11], 0
mov byte [esp + 0x12], 1
je 0x41055b
mov byte [esp + 0x12], 0
cmp eax, 1
je 0x410567
cmp byte [esp + 0x11], 0
je 0x41056f
mov byte [esp + 0x140], 0
test bl, bl
jne 0x410583
mov ebx, edi
call fcn.00413b50
mov byte [esp + 0x134], al
jmp 0x4105a4
test di, di
jne 0x4105ab
mov ecx, dword [esp + 0x134]
push ecx
xor bl, bl
call fcn.00413840
movzx edi, ax
add esp, 4
mov dword [esp + 0x138], edi
mov bl, byte [esp + 0x134]
mov edx, edi
xor eax, eax
shr edx, 8
test dl, dl
setne al
cmp dword [0x4acb4c], 2
mov dword [esp + 0x1c], eax
jne case.default.0x4105d1
movzx eax, bl
add eax, 0xffffff60
cmp eax, 5
ja case.default.0x4105d1
jmp dword [eax*4 + 0x410b18]
mov byte [esp + 0x134], 0x11
jmp 0x4105f4
mov byte [esp + 0x134], 0x10
jmp 0x4105f4
mov byte [esp + 0x134], 0x12
mov bl, byte [esp + 0x134]
mov esi, dword [esp + 0x13c]
test esi, esi
je 0x41073b
xor ecx, ecx
mov edx, edi
mov al, bl
call fcn.00412be0
test al, al
je 0x4106c4
lea ecx, [esp + 0x28]
push ecx
call dword [sym.imp.USER32.dll_GetKeyboardState]
mov cl, 0x80
mov dl, 0x7f
test ebp, ebp
jne 0x41063d
movzx eax, bl
or byte [esp + eax + 0x28], cl
lea eax, [esp + eax + 0x28]
jmp 0x41064d
cmp ebp, 1
jne 0x41064d
movzx eax, bl
and byte [esp + eax + 0x28], dl
lea eax, [esp + eax + 0x28]
movzx eax, bl
add eax, 0xffffff60
cmp eax, 5
ja case.default.0x41065a
jmp dword [eax*4 + 0x410b30]
test byte [esp + 0xca], cl
jne 0x410679
test byte [esp + 0xcb], cl
jne 0x410679
and byte [esp + 0x39], dl
jmp case.default.0x41065a
or byte [esp + 0x39], cl
jmp case.default.0x41065a
test byte [esp + 0xc8], cl
jne 0x410697
test byte [esp + 0xc9], cl
jne 0x410697
and byte [esp + 0x38], dl
jmp case.default.0x41065a
or byte [esp + 0x38], cl
jmp case.default.0x41065a
test byte [esp + 0xcc], cl
jne 0x4106b5
test byte [esp + 0xcd], cl
jne 0x4106b5
and byte [esp + 0x3a], dl
jmp case.default.0x41065a
or byte [esp + 0x3a], cl
lea edx, [esp + 0x28]
push edx
call dword [sym.imp.USER32.dll_SetKeyboardState]
movzx edi, word [esp + 0x138]
mov eax, ebp
mov ebp, dword [sym.imp.USER32.dll_PostMessageA]
shl edi, 0x10
cmp eax, 1
je 0x4106f5
mov eax, edi
or eax, 1
push eax
movzx ecx, bl
push ecx
push 0x100
push esi
call ebp
mov eax, dword [esp + 0x130]
cmp byte [esp + 0x140], 0
je 0x410714
cmp eax, 2
jne 0x410714
mov edx, dword [0x4a8978]
mov esi, dword [edx + 0x64]
call fcn.00411f70
jmp 0x41071c
test eax, eax
je 0x410ad2
mov ecx, dword [esp + 0x13c]
or edi, 0xc0000001
push edi
movzx eax, bl
push eax
push 0x101
push ecx
call ebp
jmp 0x410ad2
cmp byte [0x4acade], 0
mov dword [0x4ab20c], ebp
mov byte [0x4acb12], bl
je 0x41077c
cmp bl, 0x12
je 0x41075f
cmp bl, 0xa4
je 0x41075f
cmp bl, 0xa5
jne 0x41077c
cmp byte [esp + 0x11], 0
jne 0x41077c
push 0
mov byte [esp + 0x1a], 1
call dword [sym.imp.USER32.dll_BlockInput]
mov byte [0x4acade], 0
jmp 0x41078c
cmp byte [esp + 0x11], 0
mov byte [esp + 0x16], 0
lea esi, [esp + 0x24]
jne 0x410791
mov esi, 0x4ab204
mov dword [esp + 0x18], esi
cmp bl, 0xa5
jne 0x4107ae
cmp byte [esp + 0x12], 0
jne 0x4107ae
cmp dword [0x4ac3fc], 0
je 0x4107ae
mov al, 1
jmp 0x4107b0
xor al, al
mov byte [esp + 0x14], al
mov byte [esp + 0x13], al
test al, al
je 0x410819
cmp byte [esp + 0x11], 0
jne 0x4107cb
mov ebp, dword [0x4ab208]
jmp 0x4107e5
call dword [sym.imp.USER32.dll_GetForegroundWindow]
call fcn.00412f00
mov ebp, eax
push ebp
xor eax, eax
call fcn.00412f50
add esp, 4
mov dword [esi], eax
cmp dword [esi], 0
je 0x4107f1
mov byte [esp + 0x13], 0
jmp 0x41081d
push 0xa2
mov byte [esp + 0x19], 0xa2
call dword [sym.imp.USER32.dll_GetAsyncKeyState]
mov edx, dword [esp + 0x144]
mov dword [0x4ac3f0], edx
shr eax, 0xf
and al, 1
mov byte [esp + 0x17], al
jmp 0x41081d
mov ebp, dword [esp + 0x24]
cmp byte [esp + 0x12], 0
je 0x410835
xor ecx, ecx
mov edx, edi
mov al, bl
call fcn.00412be0
mov byte [esp + 0x20], al
jmp 0x41083a
mov byte [esp + 0x20], 0
cmp byte [esp + 0x11], 0
jne 0x410860
mov eax, dword [0x4acb4c]
cmp eax, 2
je 0x410860
cmp dword [0x4ac3fc], 0
je 0x410859
cmp eax, 1
jne 0x410860
mov byte [esp + 0x11], 1
jmp 0x410865
mov byte [esp + 0x11], 0
cmp dword [esp + 0x130], 1
mov edi, dword [sym.imp.USER32.dll_keybd_event]
mov ebx, dword [esp + 0x20]
je 0x41096b
cmp byte [esp + 0x12], 0
je 0x4108af
mov eax, dword [esp + 0x144]
mov ecx, dword [esp + 0x1c]
mov esi, dword [esp + 0x138]
mov edx, dword [esp + 0x134]
push eax
push ecx
push esi
push edx
push ebx
call fcn.00411a50
add esp, 0x14
jmp 0x41094f
cmp byte [esp + 0x14], 0
je 0x4108cc
mov eax, dword [esp + 0x18]
cmp dword [eax], 3
jne 0x4108cc
mov ecx, dword [esp + 0x144]
mov dword [0x4ac3f4], ecx
mov edx, dword [esp + 0x144]
mov eax, dword [esp + 0x1c]
mov esi, dword [esp + 0x138]
mov ecx, dword [esp + 0x134]
push edx
push eax
push esi
push ecx
call edi
cmp byte [esp + 0x13], 0
mov dword [0x4ac3f4], 0
je 0x41094f
cmp dword [0x4ac3f0], 0
mov byte [esp + 0x13], 0
je 0x41091b
mov dword [0x4ac3f0], 0
mov eax, 4
jmp 0x410940
cmp byte [esp + 0x17], 0
jne 0x41094f
movzx eax, byte [esp + 0x15]
push eax
call dword [sym.imp.USER32.dll_GetAsyncKeyState]
mov ecx, 0x8000
and ax, cx
movzx eax, ax
neg eax
sbb eax, eax
add eax, 4
push ebp
call fcn.00412f50
mov edx, dword [esp + 0x1c]
mov dword [edx], eax
add esp, 4
cmp byte [esp + 0x11], 0
je 0x410972
mov eax, dword [esp + 0x134]
push esi
push eax
xor dl, dl
call fcn.00412130
add esp, 8
jmp 0x410972
mov esi, dword [esp + 0x138]
cmp byte [esp + 0x140], 0
je 0x4109c0
mov eax, 2
cmp dword [esp + 0x130], eax
jne 0x4109c0
cmp dword [0x4acb4c], eax
jne 0x4109a9
mov ecx, dword [0x4a8978]
mov esi, dword [ecx + 0x68]
call fcn.00411f70
mov esi, dword [esp + 0x138]
jmp 0x4109ce
mov edx, dword [0x4a8978]
mov esi, dword [edx + 0x64]
call fcn.00411f70
mov esi, dword [esp + 0x138]
jmp 0x4109ce
cmp dword [esp + 0x130], 0
je 0x410abc
or dword [esp + 0x1c], 2
cmp byte [esp + 0x12], 0
je 0x4109fe
mov eax, dword [esp + 0x144]
mov ecx, dword [esp + 0x1c]
mov edx, dword [esp + 0x134]
push eax
push ecx
push esi
push edx
push ebx
call fcn.00411a50
add esp, 0x14
jmp 0x410a88
cmp byte [esp + 0x14], 0
je 0x410a1b
mov eax, dword [esp + 0x18]
cmp dword [eax], 3
jne 0x410a1b
mov ecx, dword [esp + 0x144]
mov dword [0x4ac3f8], ecx
mov edx, dword [esp + 0x144]
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x134]
push edx
push eax
push esi
push ecx
call edi
xor eax, eax
mov dword [0x4ac3f8], eax
cmp byte [esp + 0x13], al
je 0x410a88
cmp dword [0x4ac3f0], eax
je 0x410a54
mov dword [0x4ac3f0], eax
mov eax, 4
jmp 0x410a79
cmp byte [esp + 0x17], al
je 0x410a88
movzx eax, byte [esp + 0x15]
push eax
call dword [sym.imp.USER32.dll_GetAsyncKeyState]
mov ecx, 0x8000
test cx, ax
mov eax, 0
setne al
add eax, 3
push ebp
call fcn.00412f50
mov edx, dword [esp + 0x1c]
mov dword [edx], eax
add esp, 4
mov eax, dword [esp + 0x18]
cmp dword [eax], 0
je 0x410aa2
mov ecx, 0x138
cmp si, cx
jne 0x410aa2
and byte [0x4ab1e9], 0xfe
cmp byte [esp + 0x11], 0
je 0x410abc
mov edx, dword [esp + 0x134]
push esi
push edx
mov dl, 1
call fcn.00412130
add esp, 8
cmp byte [esp + 0x16], 0
je 0x410ad2
push 1
call dword [sym.imp.USER32.dll_BlockInput]
mov byte [0x4acade], 1
cmp byte [esp + 0x140], 0
je 0x410b0b
cmp dword [0x4acb4c], 2
jne 0x410afd
mov eax, dword [0x4a8978]
mov esi, dword [eax + 0x60]
call fcn.00411f70
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x11c
ret
mov ecx, dword [0x4a8978]
mov esi, dword [ecx + 0x5c]
call fcn.00411f70
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x11c
ret