Function at 0x40d5a0
Capabilities:
Check for time delay via gettickcount
Get keyboard layout
Log keystrokes
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x8c
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
cmp byte [edi], 0
je 0x40e721
mov bl, byte [ebp + 0xc]
mov esi, dword [0x4a6440]
mov dword [ebp - 0x40], esi
test bl, bl
jne 0x40d63d
push 7
push 0x49a184
push edi
call fcn.00485b40
add esp, 0xc
test eax, eax
jne 0x40d63d
add edi, 7
mov byte [0x4a8c35], 1
mov dword [ebp + 8], edi
mov eax, dword [esi + 0x5c]
mov ecx, dword [esi + 0x64]
mov dword [ebp - 0x54], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x58], ecx
cmp eax, 1
je 0x40d602
cmp eax, 3
jne 0x40d673
cmp dword [0x4ac550], 0
je 0x40d649
call fcn.00408cc0
test al, al
jne 0x40d646
test bl, bl
jne 0x40d634
call fcn.00408d20
test al, al
je 0x40d634
push 0x49a18c
mov eax, edi
call fcn.004726b0
add esp, 4
test eax, eax
jne 0x40d646
mov dword [ebp + 0x10], 1
jmp 0x40d673
mov byte [0x4a8c35], 0
jmp 0x40d5e9
mov eax, dword [ebp + 0x10]
cmp eax, 3
jne 0x40d657
mov dword [ebp + 0x10], 2
jmp 0x40d673
xor eax, eax
mov dword [ebp + 0x10], eax
cmp dword [esi + 0x5c], eax
jge 0x40d669
cmp dword [esi + 0x64], eax
jge 0x40d669
or eax, 0xffffffff
mov dword [esi + 0x64], eax
mov dword [esi + 0x5c], 0xffffffff
mov esi, dword [ebp + 0x14]
xor ebx, ebx
mov byte [ebp - 0x11], 0
test esi, esi
je 0x40d6cb
push ebx
push esi
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
mov edi, eax
mov dword [ebp - 0x5c], edi
test edi, edi
je 0x40d7c7
cmp edi, dword [0x4abd28]
je 0x40d7c7
call fcn.00476e70
test al, al
jne 0x40d7c7
mov edx, dword [0x4abd28]
push 1
push edi
push edx
call dword [sym.imp.USER32.dll_AttachThreadInput]
test eax, eax
setne byte [ebp - 0x11]
mov ebx, edi
jmp 0x40d7c7
test byte [0x4ac365], 0xc0
je 0x40d7b2
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [0x4ac35c]
cmp eax, 0x32
jae 0x40d7b2
cmp dword [ebp + 0x10], 2
je 0x40d7b2
cmp byte [0x4a8c35], bl
jne 0x40d7b2
cmp byte [0x4ac546], bl
je 0x40d7b2
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp eax, dword [0x4abd28]
jne 0x40d7b2
mov eax, dword [ebp + 8]
mov edi, 0x49a194
call fcn.00409440
cmp byte [ebp + 0xc], bl
je 0x40d783
test eax, eax
setne al
test al, al
je 0x40d7b2
xor esi, esi
mov edi, edi
mov edi, dword [sym.imp.USER32.dll_GetAsyncKeyState]
push 0x5b
call edi
mov ecx, 0x8000
test cx, ax
jne 0x40d762
push 0x5c
call edi
mov edx, 0x8000
test dx, ax
je 0x40d7b2
push 1
push 0x8000012f
mov dword [0x4a63a4], esi
call fcn.00401290
add esp, 8
mov dword [0x4a63a4], 1
jmp 0x40d740
test eax, eax
je 0x40d7b2
jmp 0x40d790
inc eax
mov edi, 0x49a198
call fcn.00409440
test eax, eax
je 0x40d73c
cmp byte [eax], 0x7b
je 0x40d73c
mov edi, 0x49a194
call fcn.00409440
test eax, eax
jne 0x40d790
call dword [sym.imp.USER32.dll_GetForegroundWindow]
test eax, eax
je 0x40d7c7
push 0
push eax
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
mov ebx, eax
push ebx
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
mov dword [0x4a8c5c], eax
push eax
xor eax, eax
call fcn.00411ac0
add esp, 4
push 1
mov dword [0x4a8c58], eax
call fcn.00411590
add esp, 4
cmp dword [0x4a9e50], 0
mov bl, al
mov byte [ebp - 4], bl
je 0x40d817
mov cl, byte [0x4a9d1d]
mov dl, byte [0x4a9d1f]
mov al, cl
not cl
and al, dl
and cl, dl
mov byte [ebp - 3], dl
mov byte [ebp - 9], cl
jmp 0x40d842
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [0x4ac35c]
cmp eax, dword [0x4a639c]
jae 0x40d837
mov al, byte [0x4ac365]
and al, bl
mov byte [ebp - 3], al
jmp 0x40d83e
mov byte [ebp - 3], 0
mov al, byte [ebp - 3]
mov byte [ebp - 9], 0
mov cl, byte [0x4ab625]
not al
and al, bl
and cl, al
mov al, byte [0x4a8c35]
mov byte [0x4ab625], cl
test al, al
je 0x40d869
not cl
and cl, bl
mov byte [ebp - 2], cl
mov byte [ebp - 8], bl
jmp 0x40d870
mov byte [ebp - 2], 0
mov byte [ebp - 8], cl
mov ecx, dword [ebp - 0x40]
cmp byte [ecx + 0xcf], 0
je 0x40d949
test al, al
jne 0x40d949
mov esi, dword [sym.imp.USER32.dll_GetKeyState]
push 0x14
call esi
and al, 1
movsx edi, al
neg edi
sbb edi, edi
add edi, 2
cmp edi, 2
jne 0x40d8ab
mov dword [ebp - 0x44], edi
jmp 0x40d950
push 0xffc3d44d
push 0
push 0
push 0
push 0x14
push 2
call fcn.0040f020
add esp, 0x18
push 0
call dword [sym.imp.USER32.dll_GetForegroundWindow]
push eax
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
cmp eax, dword [0x4abd28]
sete bl
test bl, bl
je 0x40d8fe
push 1
push 0xffffffffffffffff
mov dword [0x4a63a4], 0
call fcn.00401290
add esp, 8
mov dword [0x4a63a4], 1
push 0x14
call esi
test al, 1
je 0x40d941
push 0xffc3d44d
push 0
push 0
push 0
push 0x10
push 2
call fcn.0040f020
add esp, 0x18
test bl, bl
je 0x40d941
push 1
push 0xffffffffffffffff
mov dword [0x4a63a4], 0
call fcn.00401290
add esp, 8
mov dword [0x4a63a4], 1
mov bl, byte [ebp - 4]
mov dword [ebp - 0x44], edi
jmp 0x40d950
mov dword [ebp - 0x44], 0
mov esi, dword [ebp + 0x10]
mov dword [0x4ab678], esi
test esi, esi
je 0x40d9c2
cmp esi, 1
jne 0x40d973
mov eax, 0x36b0
mov dword [0x4a8c4c], 0x1f4
jmp 0x40d982
mov eax, 0x2ee0
mov dword [0x4a8c4c], 0x5dc
call fcn.0048eb40
mov eax, esp
mov dword [0x4a8c54], eax
mov eax, SysReAllocString
mov byte [0x4a8c3d], bl
mov dword [0x4a8c40], eax
mov dword [0x4a8c44], eax
mov byte [0x4a8c3c], 0
mov dword [0x4a8c50], 0
mov byte [0x4a8c37], 0
mov byte [0x4a8c36], 1
mov eax, dword [0x4a6450]
mov dl, byte [0x4aa628]
mov byte [ebp - 0x29], dl
cmp eax, 8
je 0x40d9da
cmp eax, 0xa
jne 0x40da15
test esi, esi
jne 0x40da15
cmp dword [ebp + 0x14], esi
jne 0x40da15
test byte [0x4ace04], 1
mov byte [ebp - 4], 1
jne 0x40da1b
or dword [0x4ace04], 1
push 0x498fcc
push 0x49a17c
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x4ace00], eax
jmp 0x40da20
mov byte [ebp - 4], 0
jmp 0x40da2f
mov eax, dword [0x4ace00]
test eax, eax
je 0x40da28
push 1
call eax
mov byte [0x4aa628], 1
mov eax, dword [ebp + 8]
mov byte [ebp - 0xf], 0
cmp byte [eax], 0
mov byte [ebp - 1], 0
je 0x40e29b
mov bl, byte [ebp - 8]
cmp dword [0x4ab678], 0
mov byte [ebp - 0xa], 0
jne 0x40daaf
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
call esi
sub eax, dword [0x4ac39c]
mov ecx, dword [0x4a6440]
cmp eax, dword [ecx + 0xb4]
jbe 0x40daaf
push 0
push 0
push 0
push 0
lea edx, [ebp - 0x88]
push edx
call dword [sym.imp.USER32.dll_PeekMessageA]
test eax, eax
je 0x40daa8
push 1
push 0xffffffffffffffff
mov dword [0x4a63a4], 0
call fcn.00401290
add esp, 8
mov dword [0x4a63a4], 1
call esi
mov dword [0x4ac39c], eax
cmp byte [ebp + 0xc], 0
jne 0x40e2dd
mov esi, dword [ebp + 8]
movsx eax, byte [esi]
push eax
push 0x49a19c
call fcn.004860b1
add esp, 8
test eax, eax
je 0x40e2dd
movsx eax, byte [esi]
add eax, 0xffffffdf
cmp eax, 0x5c
ja case.0x40daeb.34
movzx eax, byte [eax + 0x40e74c]
jmp dword [eax*4 + 0x40e730]
test bl, 3
jne case.0x40daeb.34
or byte [ebp - 1], 1
jmp case.0x40daeb.34
test bl, 0x30
jne case.0x40daeb.34
or byte [ebp - 1], 0x10
jmp case.0x40daeb.34
test bl, 0xc
jne case.0x40daeb.34
or byte [ebp - 1], 4
jmp case.0x40daeb.34
test bl, 0xc0
jne case.0x40daeb.34
or byte [ebp - 1], 0x40
jmp case.0x40daeb.34
mov esi, dword [ebp + 8]
inc esi
push 0x7d
push esi
call fcn.004860b1
mov edi, eax
add esp, 8
mov dword [ebp - 0x1c], edi
test edi, edi
je case.0x40daeb.34
mov ebx, esi
mov al, byte [ebx]
cmp al, 0x20
je 0x40db62
cmp al, 9
jne 0x40db65
inc ebx
jmp 0x40db58
mov esi, edi
sub esi, ebx
mov dword [ebp - 0x20], ebx
mov dword [ebp + 8], ebx
mov dword [ebp - 0x34], esi
jne 0x40dbfd
mov al, byte [edi + 1]
lea esi, [edi + 1]
cmp al, 0x7d
jne 0x40db8e
mov dword [ebp - 0x1c], esi
mov dword [ebp - 0x34], 1
jmp 0x40dbf7
cmp al, 0x20
je 0x40dba0
cmp al, 9
jne 0x40e275
mov ebx, dword [ebp - 0x20]
lea ecx, [ecx]
mov al, byte [esi]
cmp al, 0x20
je 0x40dbaa
cmp al, 9
jne 0x40dbad
inc esi
jmp 0x40dba0
push 4
push 0x498ac0
push esi
call fcn.00485b40
add esp, 0xc
test eax, eax
je 0x40dbdc
push 2
push 0x498ac8
push esi
call fcn.00485b40
add esp, 0xc
test eax, eax
jne 0x40e275
mov ebx, dword [ebp - 0x20]
push 0x7d
push esi
call fcn.004860b1
add esp, 8
mov dword [ebp - 0x1c], eax
test eax, eax
je 0x40e27f
sub eax, ebx
mov dword [ebp - 0x34], eax
mov esi, dword [ebp - 0x34]
mov edi, dword [ebp - 0x1c]
push 5
push 0x4998e4
push ebx
call fcn.00485b40
add esp, 0xc
test eax, eax
jne 0x40dca5
mov byte [edi], al
lea eax, [ebx + 5]
lea ebx, [ebx]
mov cl, byte [eax]
cmp cl, 0x20
je 0x40dc2c
cmp cl, 9
jne 0x40dc2f
inc eax
jmp 0x40dc20
lea ecx, [ebp - 0x50]
push ecx
lea edx, [ebp - 0x30]
push edx
lea ecx, [ebp - 0x18]
push ecx
lea edx, [ebp - 0x28]
push edx
lea ecx, [ebp - 0x48]
push ecx
lea edx, [ebp - 0x4c]
push edx
call fcn.0040f6f0
mov ecx, dword [ebp - 0x30]
add esp, 0x18
mov byte [edi], 0x7d
cmp ecx, 1
jge 0x40dc80
mov ecx, dword [ebp - 0x40]
movzx edx, byte [ecx + 0xcb]
mov eax, dword [ebp - 0x50]
push eax
push edx
lea eax, [ebp - 0x48]
push eax
lea ecx, [ebp - 0x6c]
lea eax, [ebp - 0x4c]
call fcn.00410360
add esp, 0xc
jmp 0x40e275
mov edx, dword [ebp - 0x50]
mov eax, dword [ebp - 0x48]
push edx
mov edx, dword [ebp - 0x4c]
push eax
mov eax, dword [ebp + 0x14]
push edx
mov edx, dword [ebp - 0x18]
push eax
mov eax, dword [ebp - 8]
push 0
push edx
mov edx, dword [ebp - 0x28]
push eax
push 0
push edx
jmp 0x40e26a
push 3
push 0x49a1a4
push ebx
call fcn.00485b40
add esp, 0xc
test eax, eax
jne 0x40dcc2
mov byte [ebp + 0xc], 1
jmp 0x40e275
mov eax, dword [ebp - 0x1c]
mov byte [eax], 0
mov edi, 0x499ff4
mov eax, ebx
mov dword [ebp - 0x18], 2
mov dword [ebp - 0x30], 1
mov dword [ebp - 0x24], esi
call fcn.00409440
mov dword [ebp - 0x60], eax
test eax, eax
je 0x40dd6b
mov cl, byte [eax]
mov byte [ebp - 0x2b], cl
mov ecx, eax
sub ecx, ebx
mov byte [eax], 0
mov dword [ebp - 0x24], ecx
lea esi, [eax + 1]
mov al, byte [esi]
cmp al, 0x20
je 0x40dd0c
cmp al, 9
jne 0x40dd0f
inc esi
jmp 0x40dd02
mov edx, dword [ebp - 0x1c]
sub edx, esi
je 0x40dd6b
push 4
push 0x498ac0
push esi
call fcn.00485b40
add esp, 0xc
test eax, eax
jne 0x40dd48
push 4
push 0x49a1a8
add esi, 4
push esi
mov dword [ebp - 0x18], eax
call fcn.00485b40
add esp, 0xc
test eax, eax
setne byte [ebp - 0x2a]
jmp 0x40dd6b
push 0x498ac8
push esi
call fcn.004850c1
add esp, 8
test eax, eax
jne 0x40dd63
mov dword [ebp - 0x18], 1
jmp 0x40dd6b
call fcn.0040cf00
mov dword [ebp - 0x30], eax
mov al, byte [ebx]
test al, al
je 0x40ddab
cmp byte [ebx + 1], 0
jne 0x40dd87
mov ecx, dword [0x4a8c5c]
lea esi, [ebp - 1]
call fcn.00411f00
jmp 0x40ddad
xor esi, esi
lea esp, [esp]
mov eax, dword [esi*8 + 0x4a7180]
push ebx
push eax
call fcn.004850c1
add esp, 8
test eax, eax
je 0x40ddc2
inc esi
cmp esi, 0x6d
jl 0x40dd90
xor al, al
mov esi, dword [ebp - 0x20]
mov bl, al
mov byte [ebp - 0x28], bl
test al, al
je 0x40ddcb
mov dword [ebp + 8], 0
jmp 0x40de3d
mov al, byte [esi*8 + 0x4a7184]
jmp 0x40ddad
mov eax, esi
call fcn.00411da0
movzx edi, ax
mov dword [ebp + 8], edi
test di, di
jne 0x40de40
mov al, byte [esi]
call fcn.00409410
cmp al, 0x56
jne 0x40de40
mov al, byte [esi + 1]
call fcn.00409410
cmp al, 0x4b
jne 0x40de40
lea ebx, [esi + 2]
mov edi, 0x49a1b0
mov eax, ebx
call fcn.00409440
mov edi, eax
test edi, edi
je 0x40de2b
mov al, byte [edi + 1]
call fcn.00409410
cmp al, 0x43
jne 0x40de2b
push 0x10
push 0
add edi, 2
push edi
call fcn.00486a44
movzx eax, ax
add esp, 0xc
mov dword [ebp + 8], eax
push 0x10
push 0
push ebx
call fcn.00486a44
mov bl, al
add esp, 0xc
mov byte [ebp - 0x28], bl
mov edi, dword [ebp + 8]
mov eax, dword [ebp - 0x60]
test eax, eax
je 0x40de4c
mov cl, byte [ebp - 0x2b]
mov byte [eax], cl
mov edx, dword [ebp - 0x1c]
mov eax, 1
mov byte [edx], 0x7d
cmp dword [ebp - 0x30], eax
jl 0x40e275
test bl, bl
jne 0x40e1d4
test di, di
jne 0x40e1d4
cmp dword [ebp - 0x24], eax
jne 0x40deac
cmp dword [ebp - 0x18], eax
je 0x40e275
mov eax, dword [ebp + 0x14]
test eax, eax
je 0x40de9d
movsx ecx, byte [esi]
push 0
push ecx
push 0x102
push eax
call dword [sym.imp.USER32.dll_PostMessageA]
jmp 0x40e275
mov eax, dword [ebp - 0x30]
mov cl, byte [esi]
call fcn.0040eb50
jmp 0x40e275
cmp dword [ebp + 0x14], 0
mov esi, dword [ebp - 0x34]
mov edi, dword [ebp - 0x20]
lea edx, [ebp - 8]
push edx
lea eax, [ebp - 0x18]
sete bl
push eax
call fcn.00411f70
add esp, 8
mov byte [ebp - 0x28], al
test al, al
je 0x40e0ab
mov edi, dword [ebp + 0x14]
test edi, edi
jne 0x40deea
cmp dword [ebp - 0x18], edi
jne 0x40dee5
mov byte [ebp - 0xa], al
jmp 0x40deea
call fcn.0040d0d0
cmp dword [0x4ab678], 0
je 0x40defe
mov bl, byte [0x4a8c3d]
jmp 0x40dff0
cmp dword [0x4a9e50], 0
je 0x40df12
mov bl, byte [0x4a9d1d]
jmp 0x40dff0
mov esi, dword [sym.imp.USER32.dll_GetAsyncKeyState]
push 0xa0
xor bl, bl
call esi
mov ecx, 0x8000
test cx, ax
je 0x40df2d
mov bl, 0x10
push 0xa1
call esi
mov edx, 0x8000
test dx, ax
je 0x40df41
or bl, 0x20
push 0xa2
call esi
mov ecx, 0x8000
test cx, ax
je 0x40df55
or bl, 1
push 0xa3
call esi
mov edx, 0x8000
test dx, ax
je 0x40df69
or bl, 2
push 0xa4
call esi
mov ecx, 0x8000
test cx, ax
je 0x40df7d
or bl, 4
push 0xa5
call esi
mov edx, 0x8000
test dx, ax
je 0x40df91
or bl, 8
push 0x5b
call esi
mov ecx, 0x8000
test cx, ax
je 0x40dfa2
or bl, 0x40
push 0x5c
call esi
mov edx, 0x8000
test dx, ax
je 0x40dfb3
or bl, 0x80
cmp dword [0x4a9e50], 0
je 0x40dff0
mov al, bl
not al
and al, byte [0x4a9d1d]
je 0x40dff0
mov cl, byte [0x4a9d1f]
not al
and byte [0x4a9d1d], al
and byte [0x4a9d1e], al
and cl, al
mov al, cl
mov byte [0x4a9d1f], cl
mov ecx, 0x4a9d40
call fcn.00411690
mov eax, dword [ebp - 8]
push 0
push 0
push edi
push ebx
push eax
mov esi, 0xffc3d44d
call fcn.00410e90
mov eax, dword [ebp - 0x30]
add esp, 0x14
test eax, eax
jle 0x40e275
mov ebx, dword [ebp - 0x28]
mov edi, eax
jmp 0x40e020
mov ecx, dword [ebp + 0x14]
mov edx, dword [ebp - 0x18]
push 0xffc3d44d
push 1
push ecx
push 0
push ebx
push edx
call fcn.0040f020
add esp, 0x18
cmp dword [0x4ab678], 0
jne 0x40e09f
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
call esi
sub eax, dword [0x4ac39c]
mov ecx, dword [0x4a6440]
cmp eax, dword [ecx + 0xb4]
jbe 0x40e09f
push 0
push 0
push 0
push 0
lea edx, [ebp - 0x88]
push edx
call dword [sym.imp.USER32.dll_PeekMessageA]
test eax, eax
je 0x40e098
push 1
push 0xffffffffffffffff
mov dword [0x4a63a4], 0
call fcn.00401290
add esp, 8
mov dword [0x4a63a4], 1
call esi
mov dword [0x4ac39c], eax
dec edi
jne 0x40e020
jmp 0x40e275
mov edi, dword [ebp - 0x34]
mov esi, dword [ebp - 0x20]
cmp edi, 4
jbe 0x40e11a
push 4
push 0x49a1b4
push esi
call fcn.00485b40
add esp, 0xc
test eax, eax
jne 0x40e11a
cmp dword [ebp + 0x14], eax
jne 0x40e11a
lea edi, [esi + 3]
mov al, byte [edi]
cmp al, 0x20
je 0x40e0dc
cmp al, 9
jne 0x40e0df
inc edi
jmp 0x40e0d2
call fcn.0040ec30
cmp dword [0x4ab678], 2
jne 0x40e103
mov eax, dword [0x4a6440]
mov eax, dword [eax + 0x60]
push eax
call fcn.00410ad0
add esp, 4
jmp 0x40e275
mov ecx, dword [0x4a6440]
mov eax, dword [ecx + 0x5c]
push eax
call fcn.00410ad0
add esp, 4
jmp 0x40e275
mov ebx, 2
cmp edi, ebx
jbe 0x40e275
push ebx
push 0x49a1bc
push esi
call fcn.00485b40
add esp, 0xc
test eax, eax
jne 0x40e275
push 0x10
push eax
add esi, ebx
push esi
call fcn.00486a44
movzx ecx, ax
mov eax, dword [ebp + 0x14]
add esp, 0xc
test eax, eax
je 0x40e167
push 0
push ecx
push 0x102
push eax
call dword [sym.imp.USER32.dll_PostMessageW]
jmp 0x40e19f
cmp dword [0x4ab678], ebx
je 0x40e184
movzx edx, byte [ebp - 8]
movzx eax, byte [ebp - 1]
or eax, edx
push ecx
call fcn.0040d150
add esp, 4
jmp 0x40e19f
push 0xa
lea eax, [ebp - 0x67]
push eax
push ecx
mov byte [ebp - 0x68], 0x30
call fcn.00484d52
add esp, 0xc
lea edi, [ebp - 0x68]
call fcn.0040ec30
cmp dword [0x4ab678], ebx
jne 0x40e1be
mov edx, dword [0x4a6440]
mov eax, dword [edx + 0x60]
push eax
call fcn.00410ad0
add esp, 4
jmp 0x40e275
mov eax, dword [0x4a6440]
mov eax, dword [eax + 0x5c]
push eax
call fcn.00410ad0
add esp, 4
jmp 0x40e275
xor ecx, ecx
mov edx, edi
mov al, bl
call fcn.00411760
mov byte [ebp - 0x3c], al
test al, al
je 0x40e246
cmp dword [ebp + 0x14], 0
jne 0x40e246
mov eax, dword [ebp - 0x18]
test eax, eax
jne 0x40e20c
mov byte [ebp - 0xa], bl
cmp byte [ebp - 0x2a], al
je 0x40e204
mov cl, byte [ebp - 0x3c]
or byte [0x4ab625], cl
mov dl, byte [ebp - 0x3c]
or byte [ebp - 8], dl
jmp 0x40e246
cmp eax, 1
jne 0x40e246
mov al, bl
call fcn.0040d0d0
mov al, byte [ebp - 0x3c]
mov cl, byte [0x4ab625]
not al
and byte [ebp - 2], al
and cl, al
mov byte [0x4ab625], cl
cmp bl, 0xa5
jne 0x40e240
cmp dword [0x4a8c58], 3
jne 0x40e240
and byte [ebp - 2], 0xfe
or cl, byte [ebp - 2]
mov byte [ebp - 8], cl
mov eax, dword [ebp + 0x14]
mov ecx, dword [ebp - 0x3c]
mov edx, dword [ebp - 0x18]
push 0
push SysReAllocString
push SysReAllocString
push eax
mov eax, dword [ebp - 8]
push ecx
mov ecx, dword [ebp - 0x28]
push edx
push eax
push edi
push ecx
mov ecx, dword [ebp - 0x30]
mov al, byte [ebp - 1]
call fcn.0040e7b0
add esp, 0x24
mov edx, dword [ebp - 0x1c]
mov dword [ebp + 8], edx
mov byte [ebp - 1], 0
mov bl, byte [ebp - 8]
mov eax, dword [ebp + 8]
mov dl, byte [ebp - 0xa]
inc eax
cmp byte [eax], 0
mov dword [ebp + 8], eax
mov byte [0x4ab624], dl
jne 0x40da46
cmp dword [0x4ab678], 0
je 0x40e48e
cmp byte [0x4a8c37], 0
mov dword [ebp - 0x24], 0xffffffff
jne 0x40e444
cmp dword [0x4a8c50], 0
jbe 0x40e444
cmp byte [0x4a8c35], 0
je 0x40e401
xor eax, eax
jmp 0x40e40d
mov eax, dword [ebp + 8]
mov al, byte [eax]
mov byte [ebp - 0x10], al
test al, al
je 0x40e37e
cmp byte [ebp - 0xf], 0
jne 0x40e303
mov ecx, dword [0x4a8c5c]
lea esi, [ebp - 1]
call fcn.00411f00
jmp 0x40e380
movzx esi, al
test esi, 0xffffff80
jne 0x40e320
push 2
push esi
call fcn.004865fe
add esp, 8
test eax, eax
je 0x40e320
and esi, 0xffffffdf
mov eax, esi
cmp al, 0x56
jne 0x40e35c
movzx esi, byte [ebp - 0xf]
test esi, 0xffffff80
jne 0x40e344
push 2
push esi
call fcn.004865fe
add esp, 8
test eax, eax
je 0x40e344
and esi, 0xffffffdf
mov eax, esi
cmp al, 0x4b
jne 0x40e35c
push 0x10
lea ecx, [ebp - 0xe]
push 0
push ecx
call fcn.00486a44
add esp, 0xc
jmp 0x40e380
xor esi, esi
mov edi, edi
mov eax, dword [esi*8 + 0x4a7180]
lea edx, [ebp - 0x10]
push edx
push eax
call fcn.004850c1
add esp, 8
test eax, eax
je 0x40e3c1
inc esi
cmp esi, 0x6d
jl 0x40e360
xor al, al
mov byte [ebp - 0x38], al
mov byte [ebp - 0x28], al
test al, al
mov eax, dword [ebp + 0x14]
je 0x40e3ca
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 0x38]
push 0
push SysReAllocString
push SysReAllocString
push eax
mov al, byte [ebp - 1]
push 0
push 2
push ecx
push 0
push edx
mov ecx, 1
call fcn.0040e7b0
add esp, 0x24
mov byte [ebp - 1], 0
jmp case.0x40daeb.34
mov al, byte [esi*8 + 0x4a7184]
jmp 0x40e380
mov ecx, dword [ebp + 8]
test eax, eax
je 0x40e3ec
movsx edx, byte [ecx]
push 0
push edx
push 0x102
push eax
call dword [sym.imp.USER32.dll_PostMessageA]
mov byte [ebp - 1], 0
jmp case.0x40daeb.34
mov cl, byte [ecx]
mov eax, 1
call fcn.0040eb50
mov byte [ebp - 1], 0
jmp case.0x40daeb.34
movzx eax, byte [ebp - 9]
movzx ecx, byte [ebp - 3]
not eax
and eax, ecx
or al, byte [ebp - 8]
movzx edx, byte [0x4a8c3d]
mov ebx, 1
push ebx
push ebx
mov byte [ebp + 8], al
mov edi, dword [ebp + 8]
push 0
push edx
push edi
mov esi, 0xffc3d44d
call fcn.00410e90
add esp, 0x14
lea eax, [ebp - 0x24]
push edi
push eax
call fcn.00410980
add esp, 8
jmp 0x40e449
mov ebx, 1
mov eax, dword [0x4ab678]
sub eax, ebx
neg eax
sbb eax, eax
and eax, 0x3e8
add eax, 0x1f4
cmp dword [0x4a8c4c], eax
jbe 0x40e475
mov ecx, dword [0x4a8c54]
push ecx
call fcn.004850d8
add esp, 4
mov edx, dword [ebp - 0x24]
xor esi, esi
push edx
mov dword [0x4ab678], esi
call fcn.00410ad0
add esp, 4
jmp 0x40e60b
cmp dword [0x4a9e50], 0
je 0x40e49f
mov cl, byte [0x4a9d1f]
jmp 0x40e4c3
cmp dword [0x4a639c], 0
jl 0x40e4c0
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [0x4ac35c]
cmp eax, dword [0x4a639c]
jb 0x40e4c0
xor cl, cl
jmp 0x40e4c3
mov cl, byte [ebp - 3]
cmp byte [0x4a8c35], 0
je 0x40e4e5
mov dl, byte [ebp - 3]
mov al, cl
xor al, dl
mov bl, al
and bl, dl
not bl
and bl, byte [ebp - 8]
and al, cl
or bl, al
mov byte [ebp + 8], bl
jmp 0x40e4f2
mov al, byte [ebp - 9]
not al
and al, cl
or al, byte [ebp - 8]
mov byte [ebp + 8], al
cmp dword [0x4a9e50], 0
je 0x40e508
mov al, byte [0x4a9d1d]
mov byte [ebp - 0x24], al
jmp 0x40e5e9
mov esi, dword [sym.imp.USER32.dll_GetAsyncKeyState]
push 0xa0
xor bl, bl
call esi
mov ecx, 0x8000
test cx, ax
je 0x40e523
mov bl, 0x10
push 0xa1
call esi
mov edx, 0x8000
test dx, ax
je 0x40e537
or bl, 0x20
push 0xa2
call esi
mov ecx, 0x8000
test cx, ax
je 0x40e54b
or bl, 1
push 0xa3
call esi
mov edx, 0x8000
test dx, ax
je 0x40e55f
or bl, 2
push 0xa4
call esi
mov ecx, 0x8000
test cx, ax
je 0x40e573
or bl, 4
push 0xa5
call esi
mov edx, 0x8000
test dx, ax
je 0x40e587
or bl, 8
push 0x5b
call esi
mov ecx, 0x8000
test cx, ax
je 0x40e598
or bl, 0x40
push 0x5c
call esi
mov edx, 0x8000
test dx, ax
je 0x40e5a9
or bl, 0x80
cmp dword [0x4a9e50], 0
je 0x40e5e6
mov al, bl
not al
and al, byte [0x4a9d1d]
je 0x40e5e6
mov cl, byte [0x4a9d1f]
not al
and byte [0x4a9d1d], al
and byte [0x4a9d1e], al
and cl, al
mov al, cl
mov byte [0x4a9d1f], cl
mov ecx, 0x4a9d40
call fcn.00411690
mov byte [ebp - 0x24], bl
mov eax, dword [ebp + 0x14]
mov ecx, dword [ebp - 0x24]
mov edx, dword [ebp + 8]
mov ebx, 1
push ebx
push ebx
push eax
push ecx
push edx
mov esi, 0xffc3d44d
call fcn.00410e90
add esp, 0x14
xor esi, esi
cmp dword [0x4a9e50], esi
je 0x40e62b
mov al, byte [0x4a9d1e]
mov cl, al
xor cl, byte [0x4a9d1d]
and cl, al
not cl
and al, cl
mov byte [0x4a9d1e], al
cmp dword [ebp - 0x44], ebx
jne 0x40e67d
push 0x14
call dword [sym.imp.USER32.dll_GetKeyState]
test al, 1
jne 0x40e67d
push 0xffc3d44d
push esi
push esi
push esi
push 0x14
push 2
call fcn.0040f020
add esp, 0x18
push esi
call dword [sym.imp.USER32.dll_GetForegroundWindow]
push eax
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
cmp eax, dword [0x4abd28]
jne 0x40e67d
push ebx
push 0xffffffffffffffff
mov dword [0x4a63a4], esi
call fcn.00401290
add esp, 8
mov dword [0x4a63a4], ebx
cmp byte [ebp - 0x11], 0
je 0x40e694
mov edx, dword [ebp - 0x5c]
mov eax, dword [0x4abd28]
push esi
push edx
push eax
call dword [sym.imp.USER32.dll_AttachThreadInput]
cmp byte [ebp - 4], 0
je 0x40e6e0
cmp byte [ebp - 0x29], 0
jne 0x40e6e0
test byte [0x4ace04], 1
jne 0x40e6cd
or dword [0x4ace04], ebx
push 0x498fcc
push 0x49a17c
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x4ace00], eax
jmp 0x40e6d2
mov eax, dword [0x4ace00]
cmp eax, esi
je 0x40e6d9
push esi
call eax
mov byte [0x4aa628], 0
cmp dword [ebp + 0x10], ebx
jne 0x40e712
push esi
call dword [sym.imp.USER32.dll_GetForegroundWindow]
push eax
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
cmp eax, dword [0x4abd28]
jne 0x40e712
push ebx
push 0xffffffffffffffff
mov dword [0x4a63a4], esi
call fcn.00401290
add esp, 8
mov dword [0x4a63a4], ebx
mov eax, dword [ebp - 0x40]
mov ecx, dword [ebp - 0x54]
mov edx, dword [ebp - 0x58]
mov dword [eax + 0x5c], ecx
mov dword [eax + 0x64], edx
lea esp, [ebp - 0x98]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret