Function at 0x10020040
Capabilities:
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x68
cmp byte [0x10168938], 0
push ebx
push esi
mov esi, ecx
push edi
mov dword [ebp - 0x58], esi
je 0x10020811
push dword [0x10168940]
call dword [sym.imp.USER32.dll_GetAsyncKeyState]
test ax, ax
je 0x10020811
mov eax, dword [0x1016bffc]
mov ecx, dword [eax]
test ecx, ecx
je 0x10020811
call fcn.10093ba0
test al, al
je 0x10020811
mov ecx, dword [0x10167e4c]
mov eax, dword [ecx]
mov eax, dword [eax + 0x68]
call eax
test al, al
je 0x10020811
mov ecx, dword [0x10167e4c]
mov eax, dword [ecx]
mov eax, dword [eax + 0x6c]
call eax
test al, al
je 0x10020811
mov eax, dword [0x1016bffc]
mov ecx, dword [eax]
call fcn.10017c60
mov eax, dword [eax]
cmp eax, 0x400
je 0x10020811
cmp eax, 8
je 0x10020811
mov eax, dword [0x1016bffc]
mov eax, dword [eax]
mov eax, dword [eax + 0x25c]
cmp eax, 9
je 0x10020811
cmp eax, 8
je 0x10020811
mov eax, dword fs:[0x2c]
mov ecx, dword [0x1016766c]
mov ecx, dword [eax + ecx*4]
mov eax, dword [0x1016c0b8]
cmp eax, dword [ecx + 4]
jle 0x10020172
push 0x1016c0b8
call fcn.100f5255
add esp, 4
cmp dword [0x1016c0b8], 0xffffffff
jne 0x10020172
push 0x1016c0b8
mov dword [0x1016c050], 0x7f800000
mov dword [0x1016c04c], 0x7f800000
mov dword [0x1016c048], 0x7f800000
mov dword [0x1016c05c], 0x7f800000
mov dword [0x1016c058], 0x7f800000
mov dword [0x1016c054], 0x7f800000
call fcn.100f5204
add esp, 4
cmp byte [esi + 0x60], 0
mov ebx, dword [ebp + 8]
movss xmm3, dword [ebx + 0x24]
movss xmm0, dword [ebx + 0xc]
movss xmm1, dword [ebx + 0x10]
movss xmm2, dword [ebx + 0x14]
mov eax, dword [ebx + 0x30]
movss dword [ebp - 0x4c], xmm3
movss xmm3, dword [ebx + 0x28]
movss dword [ebp - 0x40], xmm0
subss xmm0, dword [esi + 0x7c]
movss dword [ebp - 0x44], xmm1
subss xmm1, dword [esi + 0x80]
movss dword [ebp - 0x48], xmm2
subss xmm2, dword [esi + 0x84]
movss dword [ebp - 0x50], xmm3
mov dword [ebp - 0x5c], eax
jne 0x10020226
movss xmm3, dword [ebp - 0x40]
movss dword [0x1016c048], xmm3
movss xmm3, dword [ebp - 0x44]
movss dword [0x1016c054], xmm0
movss xmm0, dword [ebp - 0x4c]
movss dword [0x1016c04c], xmm3
movss xmm3, dword [ebp - 0x48]
movss dword [0x1016c060], xmm0
movss xmm0, dword [ebp - 0x50]
movss dword [0x1016c050], xmm3
movss dword [0x1016c058], xmm1
movss dword [0x1016c05c], xmm2
movss dword [0x1016c064], xmm0
mov dword [0x1016c068], eax
mov eax, dword [0x1016893c]
xorps xmm0, xmm0
xor edi, edi
mov dword [ebp - 0xc], eax
mov dword [ebp - 0x18], 0
movss dword [ebp - 0x14], xmm0
mov dword [ebp - 0x10], 0
mov dword [ebp - 0x3c], 0
test eax, eax
jle 0x10020704
mov eax, dword [0x1016912c]
mov eax, dword [eax + 0x1c]
dec eax
push eax
mov eax, dword [0x1016654c]
push 0
mov eax, dword [eax]
call eax
mov eax, dword [0x1016bffc]
mov ecx, dword [eax]
call fcn.1001b020
mov ecx, dword [eax]
mov dword [esi + 0x88], ecx
mov ecx, dword [eax + 4]
mov dword [esi + 0x8c], ecx
mov eax, dword [eax + 8]
mov dword [esi + 0x90], eax
cmp byte [esi + 0x60], 0
cmovne edi, dword [0x1016902c]
cmp byte [0x10168939], 0
je 0x100202b2
cmp edi, 2
jl 0x100202ae
cmp edi, 3
jle 0x100202b2
mov cl, 1
jmp 0x100202b4
xor cl, cl
mov byte [ebp - 5], cl
cmp edi, 1
je 0x100202c5
mov byte [ebp + 0xb], 0
cmp edi, 3
jne 0x100202cc
mov byte [ebp + 0xb], 1
cmp edi, 3
jle 0x10020348
cmp dword [ebp - 0x3c], 2
jl 0x10020704
movd xmm2, dword [ebp - 0x10]
movss xmm1, dword [0x1016c054]
movss xmm3, dword [0x10151c6c]
mulss xmm1, xmm3
cvtdq2ps xmm2, xmm2
mulss xmm1, xmm2
addss xmm1, dword [0x1016c054]
movss dword [0x1016c054], xmm1
movss xmm1, dword [0x1016c058]
mulss xmm1, xmm3
mulss xmm1, xmm2
addss xmm1, dword [0x1016c058]
movss dword [0x1016c058], xmm1
movss xmm1, dword [0x1016c05c]
mulss xmm1, xmm3
mulss xmm1, xmm2
addss xmm1, dword [0x1016c05c]
movss dword [0x1016c05c], xmm1
movss xmm1, dword [0x1016c048]
xor edx, edx
movss xmm2, dword [0x1016c04c]
movss xmm3, dword [0x1016c050]
movss dword [ebp - 0x30], xmm1
movss dword [ebp - 0x34], xmm2
movss dword [ebp - 0x38], xmm3
mov dword [ebp - 0x1c], edx
mov eax, dword [ebp - 0xc]
cmp dword [ebp - 0x18], eax
jge 0x100206fa
test cl, cl
je 0x10020533
addss xmm1, dword [0x1016c054]
addss xmm2, dword [0x1016c058]
addss xmm3, dword [0x1016c05c]
movss xmm0, dword [0x1016c060]
mov eax, dword [ebx + 0x14]
movss dword [ebx + 0x24], xmm0
movss xmm0, dword [0x1016c064]
movss dword [ebx + 0x28], xmm0
movq xmm0, qword [ebx + 0xc]
movss dword [ebx + 0x10], xmm2
movss dword [ebx + 0x14], xmm3
movss dword [0x10166540], xmm1
movq qword [ebp - 0x68], xmm0
movss xmm0, dword [ebx + 0x10]
movss dword [0x10166544], xmm0
movss xmm0, dword [ebx + 0x14]
movss dword [0x10166548], xmm0
movss xmm0, dword [ebx + 0x24]
movss dword [ebp - 0x2c], xmm0
movss dword [0x10169174], xmm0
movss xmm0, dword [ebx + 0x28]
movss dword [ebp - 0x28], xmm0
movss dword [0x10169178], xmm0
movss xmm0, dword [ebp - 0x68]
movss dword [ebx + 0xc], xmm0
movss xmm0, dword [ebp - 0x64]
movss dword [ebx + 0x10], xmm0
mov dword [ebp - 0x60], eax
movss xmm0, dword [ebp - 0x60]
movss dword [ebp - 0x30], xmm1
movss dword [ebp - 0x34], xmm2
xorps xmm2, xmm2
movss dword [ebx + 0x14], xmm0
movss xmm1, dword [0x10166544]
comiss xmm2, xmm1
movss dword [ebp - 0x38], xmm3
movss xmm3, dword [0x10151e88]
jbe 0x10020463
addss xmm1, xmm3
movss xmm0, dword [ebx + 0x10]
comiss xmm2, xmm0
jbe 0x10020471
addss xmm0, xmm3
comiss xmm1, xmm0
jbe 0x10020484
subss xmm0, xmm1
call fcn.10012ef0
movaps xmm2, xmm0
jmp 0x10020497
subss xmm1, xmm0
movaps xmm0, xmm1
call fcn.10012ef0
movaps xmm2, xmm3
subss xmm2, xmm0
movaps xmm1, xmm3
subss xmm1, xmm2
movaps xmm0, xmm1
mulss xmm1, dword [0x10151c00]
addss xmm0, dword [0x10151e38]
movss dword [ebp - 0x54], xmm1
mulss xmm0, dword [0x10151c00]
movss dword [ebp - 0x24], xmm0
movaps xmm0, xmm1
call fcn.10012f10
mulss xmm0, dword [ebp - 0x2c]
movss dword [ebp - 0x20], xmm0
movss xmm0, dword [ebp - 0x24]
call fcn.10012f10
mulss xmm0, dword [ebp - 0x28]
movss xmm1, dword [ebp - 0x20]
addss xmm1, xmm0
movss xmm0, dword [ebp - 0x24]
cvtps2pd xmm0, xmm0
movss dword [ebp - 0x20], xmm1
call fcn.1011ac80
cvtsd2ss xmm0, xmm0
mulss xmm0, dword [ebp - 0x28]
movss dword [ebp - 0x28], xmm0
movss xmm0, dword [ebp - 0x54]
cvtps2pd xmm0, xmm0
call fcn.1011ac80
movss xmm1, dword [ebp - 0x28]
cvtsd2ss xmm0, xmm0
mulss xmm0, dword [ebp - 0x2c]
addss xmm1, xmm0
movss xmm0, dword [ebp - 0x20]
jmp 0x10020539
xorps xmm1, xmm1
xorps xmm0, xmm0
movss dword [ebx + 0x24], xmm1
movss dword [ebx + 0x28], xmm0
mov ecx, dword [ebx + 0x30]
mov eax, ecx
and eax, 0xfffffffb
or ecx, 4
cmp byte [ebp + 0xb], 0
cmove ecx, eax
mov dword [ebx + 0x30], ecx
call fcn.10022e00
push ebx
mov ecx, eax
call fcn.1007c710
push ebx
mov ecx, esi
call fcn.1001fbb0
mov byte [esi + 0x60], al
mov eax, dword [0x1016bffc]
mov ecx, dword [eax]
call fcn.1001b020
mov ecx, dword [eax]
mov dword [esi + 0x88], ecx
mov ecx, dword [eax + 4]
mov dword [esi + 0x8c], ecx
mov eax, dword [eax + 8]
mov dword [esi + 0x90], eax
call fcn.10022e00
mov ecx, dword [0x1016bffc]
mov esi, eax
mov ecx, dword [ecx]
mov dword [ecx + 0x3348], 0
mov ecx, dword [esi + 0x30]
mov dword [ecx], 0
mov ecx, dword [esi + 0x2c]
mov dword [ecx], 0xffffffff
mov ecx, dword [0x1016bf84]
mov edx, dword [ecx]
call dword [edx + 8]
mov ecx, dword [0x10167e48]
mov eax, dword [esi]
inc dword [ebp - 0x18]
mov dword [ecx + 0x10], eax
mov eax, dword [esi + 4]
mov dword [ecx + 0x14], eax
mov ecx, dword [0x1016912c]
mov al, byte [esi + 0x24]
mov byte [ecx + 8], al
mov al, byte [esi + 0x25]
mov byte [ecx + 0x18], al
mov byte [esi + 0xec], 0
mov esi, dword [ebp - 0x58]
cmp byte [esi + 0x60], 0
jne 0x1002061e
cmp edi, 3
jle 0x1002061e
mov eax, dword [0x1016bffc]
mov ecx, dword [eax]
call fcn.10012f70
movss xmm0, dword [ebp - 0x14]
comiss xmm0, dword [eax + 8]
ja 0x10020674
mov eax, dword [0x1016bffc]
mov ecx, dword [eax]
call fcn.10017c60
test byte [eax], 1
jne 0x10020680
mov eax, dword [0x1016bffc]
mov eax, dword [eax]
cmp dword [eax + 0x25c], 9
je 0x100206f7
cmp byte [esi + 0x60], 0
jne 0x10020745
mov eax, dword [ebp - 0x1c]
inc eax
mov dword [ebp - 0x1c], eax
cmp eax, dword [ebp - 0xc]
jge 0x100206f7
movss xmm1, dword [ebp - 0x30]
movss xmm2, dword [ebp - 0x34]
movss xmm3, dword [ebp - 0x38]
mov cl, byte [ebp - 5]
jmp 0x10020374
mov dword [ebp - 0x10], 0xffffffff
jmp 0x100206f7
test edi, edi
je 0x100206db
cmp edi, 2
jne 0x100206af
mov eax, dword [0x1016bffc]
mov ecx, dword [eax]
call fcn.10012f70
movss xmm0, dword [ebp - 0x14]
xor ecx, ecx
comiss xmm0, dword [eax + 8]
setbe cl
lea ecx, [ecx*2 - 1]
mov dword [ebp - 0x10], ecx
jmp 0x100206f1
cmp edi, 3
jle 0x100206f1
mov eax, dword [0x1016bffc]
mov dword [ebp - 0x10], 1
mov ecx, dword [eax]
call fcn.10012f70
movss xmm0, dword [ebp - 0x14]
comiss xmm0, dword [eax + 8]
jbe 0x100206db
mov dword [ebp - 0x10], 0xffffffff
jmp 0x100206f1
mov eax, dword [0x1016bffc]
mov ecx, dword [eax]
call fcn.10012f70
movss xmm0, dword [eax + 8]
movss dword [ebp - 0x14], xmm0
mov edx, dword [ebp - 0x1c]
mov dword [ebp - 0x3c], edx
mov eax, dword [ebp - 0xc]
inc edi
cmp dword [ebp - 0x18], eax
jl 0x10020255
movss xmm0, dword [ebp - 0x40]
mov eax, dword [ebp - 0x5c]
movss dword [ebx + 0xc], xmm0
movss xmm0, dword [ebp - 0x44]
movss dword [ebx + 0x10], xmm0
movss xmm0, dword [ebp - 0x48]
movss dword [ebx + 0x14], xmm0
movss xmm0, dword [ebp - 0x4c]
movss dword [ebx + 0x24], xmm0
movss xmm0, dword [ebp - 0x50]
movss dword [ebx + 0x28], xmm0
mov dword [ebx + 0x30], eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
xor eax, eax
cmp edi, 4
cmovge edi, eax
cmp byte [ebp - 5], 0
mov al, byte [ebp + 0xb]
mov dword [0x1016902c], edi
mov byte [esi + 0x5c], al
je 0x100207de
movss xmm0, dword [0x1016c060]
movss dword [ebx + 0x24], xmm0
movss xmm0, dword [0x1016c064]
movss dword [ebx + 0x28], xmm0
movss xmm0, dword [0x1016c050]
movss xmm2, dword [0x1016c048]
movss xmm1, dword [0x1016c04c]
addss xmm0, dword [0x1016c05c]
addss xmm2, dword [0x1016c054]
addss xmm1, dword [0x1016c058]
movss dword [ebx + 0x14], xmm0
movss dword [ebx + 0xc], xmm2
movss dword [ebx + 0x10], xmm1
movss dword [0x1016c048], xmm2
movss xmm0, dword [ebx + 0x10]
movss dword [0x1016c04c], xmm0
movss xmm0, dword [ebx + 0x14]
movss dword [0x1016c050], xmm0
mov ecx, dword [0x10167e48]
mov edx, dword [ebp - 0x1c]
inc edx
mov eax, dword [ecx + 0x1c]
add eax, edx
mov dword [esi + 0x64], eax
mov eax, dword [ebp - 0xc]
mov dword [esi + 0x6c], eax
mov eax, dword [ecx + 0x1c]
mov dword [esi + 0x70], eax
movsx eax, word [ebx + 0x44]
cdq
xor eax, edx
sub eax, edx
mov dword [esi + 0x74], eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
pop edi
mov byte [esi + 0x60], 0
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4