Function at 0x485360
Capabilities:
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x2c
push ebx
push esi
push edi
mov edi, ecx
cmp dword [edi + 0x3a8], 0xffffffff
jne 0x4853e3
mov dword [edi + 0x3a8], 0
mov eax, edi
jmp 0x485390
cmp byte [eax + 0x213], 0
mov eax, dword [eax + 0x244]
jne 0x4853a5
test eax, eax
jne 0x485390
jmp 0x4853e3
test eax, eax
je 0x4853e3
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0x78]
call eax
cmp dword [0x59b534], 0
je 0x4853c4
mov edx, eax
call fcn.0042ef00
jmp 0x4853c6
xor eax, eax
push 0
push 0x5866e0
push 0x578908
push 0
push eax
call fcn.00511c29
add esp, 0x14
mov dword [edi + 0x3a8], eax
mov ebx, dword [ebp + 0xc]
mov eax, dword [ebx + 8]
mov ecx, dword [ebx + 0x54]
mov edx, dword [ebx + 0x58]
add eax, 0xffffffff
cmp eax, 0x16
mov dword [esp + 0x10], ecx
mov dword [esp + 0x14], edx
ja case.0x48540a.2
movzx eax, byte [eax + 0x485868]
jmp dword [eax*4 + 0x485854]
lea esi, [esp + 0x18]
mov ecx, edi
call fcn.0046b810
mov ecx, dword [esp + 0x18]
cmp ecx, dword [esp + 0x20]
jge 0x485430
mov edx, dword [esp + 0x1c]
cmp edx, dword [esp + 0x24]
jl 0x48543e
mov eax, 4
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
fld dword [esp + 0x10]
fild dword [esp + 0x18]
fcomp st(1)
fnstsw ax
test ah, 0x41
jp 0x48549b
fild dword [esp + 0x20]
fcompp
fnstsw ax
test ah, 0x41
jne 0x48549d
fld dword [esp + 0x14]
fild dword [esp + 0x1c]
fcomp st(1)
fnstsw ax
test ah, 0x41
jp 0x48549b
fild dword [esp + 0x24]
fcompp
fnstsw ax
test ah, 0x41
jne 0x48549d
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
push 0xff
push eax
push ecx
mov ecx, edi
call fcn.0046b900
test al, al
je 0x48549d
mov byte [esp + 0xe], 1
jmp 0x4854a2
fstp st(0)
mov byte [esp + 0xe], 0
cmp dword [edi + 0x3a8], 0
je 0x485558
cmp byte [edi + 0x366], 0
je 0x485548
cmp byte [esp + 0xe], 0
je 0x485548
cmp byte [0x59b495], 0
je 0x485501
mov eax, dword [0x587aa4]
test eax, eax
jne 0x4854ef
push 0x17
call dword [sym.imp.USER32.dll_GetSystemMetrics]
neg eax
sbb eax, eax
neg eax
add eax, 1
mov dword [0x587aa4], eax
push eax
call dword [sym.imp.USER32.dll_GetAsyncKeyState]
test ax, 0x8000
seta al
test al, al
jne 0x485548
mov eax, dword [edi + 0x3ac]
test eax, eax
lea edx, [edi + 0x3ac]
je 0x485548
test dword [eax], 0xffffff00
je 0x485548
cmp byte [eax + 4], 0
je 0x485548
mov ecx, dword [edi + 0x3a8]
or eax, 0xffffffff
lea esi, [esp + 0x28]
push esi
mov dword [esp + 0x2c], eax
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], eax
mov dword [esp + 0x38], eax
mov eax, dword [ecx]
push edx
mov edx, dword [eax + 8]
push edi
call edx
jmp 0x485558
mov ecx, dword [edi + 0x3a8]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push 1
push edi
call edx
mov al, byte [esp + 0xe]
test al, al
sete cl
cmp byte [edi + 0x454], 0
mov byte [edi + 0x366], cl
je 0x4856a7
mov ecx, edi
call fcn.0046b890
cmp byte [esp + 0xe], 0
je 0x4855b7
lea edx, [esp + 0x10]
mov ecx, edi
call fcn.00485880
test eax, eax
jne 0x48570a
mov edx, dword [ebp + 8]
push eax
push eax
push edx
mov esi, edi
call fcn.00485940
mov eax, dword [edi + 8]
neg eax
sbb eax, eax
add eax, 0xf4241
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
fldz
fcom dword [ebx + 0x5c]
fnstsw ax
test ah, 0x41
jp 0x485708
mov eax, dword [edi + 0x464]
fld dword [ebx + 0x5c]
test eax, eax
fild dword [edi + 0x464]
jge 0x4855e0
fadd dword [0x567d50]
fcompp
fnstsw ax
test ah, 0x41
jne 0x485708
fcomp dword [ebx + 0x60]
fnstsw ax
test ah, 0x41
jp 0x48570a
mov ecx, dword [edi + 0x468]
fld dword [ebx + 0x60]
test ecx, ecx
fild dword [edi + 0x468]
jge 0x485614
fadd dword [0x567d50]
fcompp
fnstsw ax
test ah, 0x41
jne 0x48570a
fld dword [ebx + 0x60]
mov ecx, dword [edi + 0x46c]
fnstcw word [esp + 0xe]
push 0
movzx eax, word [esp + 0x12]
or eax, 0xc00
mov dword [esp + 0x14], eax
push 0
fldcw word [esp + 0x18]
mov esi, edi
fistp qword [esp + 0x18]
mov edx, dword [esp + 0x18]
fldcw word [esp + 0x16]
imul edx, dword [edi + 0x460]
fld dword [ebx + 0x5c]
fnstcw word [esp + 0x16]
movzx eax, word [esp + 0x16]
or eax, 0xc00
mov dword [esp + 0x18], eax
fldcw word [esp + 0x18]
fistp qword [esp + 0x18]
mov eax, dword [esp + 0x18]
add edx, eax
mov eax, dword [ebp + 8]
mov edx, dword [ecx + edx*4]
fldcw word [esp + 0x16]
push eax
mov dword [edi + 0x455], edx
call fcn.00485940
mov eax, dword [edi + 8]
neg eax
sbb eax, eax
add eax, 0xf4241
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
test al, al
je 0x4856e1
cmp dword [edi + 0x354], 0
jne 0x4856c5
mov esi, edi
call fcn.0046b770
mov dword [edi + 0x360], 2
mov ecx, edi
call fcn.0046b890
mov eax, dword [edi + 8]
neg eax
sbb eax, eax
add eax, 0xf4241
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
cmp dword [edi + 0x354], 3
jne 0x48570a
push 1
mov ecx, edi
call fcn.0046b520
mov eax, dword [edi + 8]
neg eax
sbb eax, eax
add eax, 0xf4241
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
fstp st(0)
mov eax, dword [edi + 8]
neg eax
sbb eax, eax
add eax, 0xf4241
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
lea esi, [esp + 0x18]
mov ecx, edi
call fcn.0046b810
mov ecx, dword [esp + 0x18]
cmp ecx, dword [esp + 0x20]
jge 0x485430
mov edx, dword [esp + 0x1c]
cmp edx, dword [esp + 0x24]
jge 0x485430
fld dword [esp + 0x10]
mov esi, dword [ebp + 8]
fild dword [esp + 0x18]
fcomp st(1)
fnstsw ax
test ah, 0x41
jp 0x4857e6
fild dword [esp + 0x20]
fcompp
fnstsw ax
test ah, 0x41
jne 0x4857e8
fld dword [esp + 0x14]
fild dword [esp + 0x1c]
fcomp st(1)
fnstsw ax
test ah, 0x41
jp 0x4857e6
fild dword [esp + 0x24]
fcompp
fnstsw ax
test ah, 0x41
jne 0x4857e8
cmp byte [ebx + 0x6c], 0
jne 0x4857e8
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
push 0xff
push eax
push ecx
mov ecx, edi
call fcn.0046b900
test al, al
je 0x4857e8
mov ecx, dword [edi + 0x3a8]
test ecx, ecx
je 0x4857bd
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push 1
push edi
call eax
mov ecx, dword [ebp + 0x10]
mov dword [ecx], esi
cmp byte [edi + 0x454], 0
jne 0x4857f1
lea edx, [esp + 0x10]
push edx
push esi
mov eax, edi
call fcn.00485a80
mov eax, 0xf4240
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
fstp st(0)
cmp byte [edi + 0x454], 0
je case.0x48540a.2
push esi
call fcn.00485c90
mov eax, 0xf4240
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
cmp byte [edi + 0x454], 0
je case.0x48540a.2
cmp dword [ebx + 0x10], 0x1b
jne case.0x48540a.2
mov eax, dword [ebp + 8]
push eax
call fcn.00485c90
mov eax, 0xf4240
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov ecx, dword [ebp + 0x10]
mov edx, dword [ebp + 8]
push ecx
push ebx
push edx
mov ecx, edi
call fcn.00456620
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
pop edi
pop esi
mov eax, 0xf4241
pop ebx
mov esp, ebp
pop ebp
ret 0xc