Function at 0x417370
Capabilities:
Check for foreground window switch
Check for time delay via gettickcount
Get keyboard layout
Log keystrokes
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x98
push ebx
push esi
mov esi, ecx
mov ebx, edx
push edi
mov dword [ebp - 0x1c], ebx
cmp word [esi], 0
je 0x418382
mov edi, dword [0x4e211c]
mov eax, dword fs:[0x24]
mov dword [ebp - 0x28], edi
mov dword [ebp - 0x48], eax
test ebx, ebx
jne 0x4173c4
push 7
push str.Blind
push esi
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsnicmp]
add esp, 0xc
test eax, eax
jne 0x4173c4
mov byte [0x4e7b17], 1
add esi, 0xe
jmp 0x4173cf
mov byte [0x4e7b17], 0
test ebx, ebx
jne 0x4173ee
push 6
push 0x4cf6ac
push esi
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsnicmp]
add esp, 0xc
test eax, eax
jne 0x4173ee
mov dword [ebp - 0x1c], 2
add esi, 0xc
mov eax, dword [edi + 0x5c]
mov ecx, dword [ebp + 8]
mov dword [ebp - 0x68], eax
mov eax, dword [edi + 0x64]
mov dword [ebp - 0x54], eax
cmp ecx, 1
je 0x41740b
cmp ecx, 3
jne 0x4174be
cmp dword [0x4e7a2c], 0
je 0x41748c
mov eax, dword [0x4e7a54]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
je 0x417426
push eax
call edi
push str.AHK_Keybd
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateMutexW]
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp dword [0x4e7a54], 0
mov dword [ebp - 0x30], eax
je 0x417451
mov dword [0x4e7a54], ebx
jmp 0x417457
push ebx
call edi
mov eax, dword [ebp - 0x30]
cmp eax, 0xb7
je 0x417486
cmp dword [ebp - 0x1c], 0
jne 0x41747d
call fcn.00412900
test al, al
je 0x41747d
mov edx, str.Click
mov ecx, esi
call fcn.0049c600
test eax, eax
jne 0x417486
mov dword [ebp + 8], 1
jmp 0x4174be
mov edi, dword [ebp - 0x28]
mov ecx, dword [ebp + 8]
cmp ecx, 3
jne 0x41749a
mov dword [ebp + 8], 2
jmp 0x4174be
cmp dword [edi + 0x5c], 0
mov dword [ebp + 8], 0
jge 0x4174b2
cmp dword [edi + 0x64], 0
jge 0x4174b2
or eax, 0xffffffff
jmp 0x4174b4
xor eax, eax
mov dword [edi + 0x64], eax
mov dword [edi + 0x5c], 0xffffffff
mov ebx, dword [ebp + 0xc]
xor edi, edi
mov byte [ebp - 0xb], 0
test ebx, ebx
je 0x417518
push edi
push ebx
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
mov dword [ebp - 0x38], eax
test eax, eax
je 0x4175bc
cmp eax, dword [0x4e6ce0]
je 0x4175bc
mov ecx, ebx
call fcn.004a1f60
test al, al
jne 0x4175bc
mov ebx, dword [ebp - 0x38]
push 1
push ebx
push dword [0x4e6ce0]
call dword [sym.imp.USER32.dll_AttachThreadInput]
test eax, eax
mov edi, ebx
setne byte [ebp - 0xb]
jmp 0x4175bc
test byte [0x4e7832], 0xc0
je 0x4175a7
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [0x4e7828]
cmp eax, 0x32
jae 0x4175a7
cmp dword [ebp + 8], 2
je 0x4175a7
cmp byte [0x4e7b17], 0
jne 0x4175a7
mov ebx, dword [ebp - 0x1c]
cmp ebx, 2
je 0x4175a7
cmp byte [0x4e7a16], 0
je 0x4175a7
mov eax, dword [ebp - 0x48]
cmp eax, dword [0x4e6ce0]
jne 0x4175a7
mov edx, 0x4cf90c
mov ecx, esi
call fcn.00406460
test ebx, ebx
jne 0x417603
test eax, eax
je 0x4175a7
nop dword [eax]
lea ecx, [eax + 2]
mov edx, 0x4cf914
call fcn.00406460
test eax, eax
je 0x417607
cmp word [eax], 0x7b
je 0x417607
mov edx, 0x4cf90c
mov ecx, eax
call fcn.00406460
test eax, eax
jne 0x417580
call dword [sym.imp.USER32.dll_GetForegroundWindow]
mov edx, eax
call fcn.0041b510
mov edi, eax
mov eax, dword [ebp - 0x54]
mov dword [ebp - 0x38], eax
push edi
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
xor edx, edx
mov dword [0x4e7af8], eax
mov ecx, eax
call fcn.0041b5b0
mov cl, 1
mov dword [0x4e7afc], eax
call fcn.0041af60
mov bl, al
and byte [0x4e7aa6], bl
cmp dword [0x4e4bb4], 0
je 0x417649
mov al, byte [0x4e4c43]
mov cl, byte [0x4e4c3f]
mov bh, al
not al
and bh, cl
and al, cl
jmp 0x41766d
test eax, eax
je 0x4175a7
mov edi, dword [sym.imp.USER32.dll_GetAsyncKeyState]
mov ebx, 0x8000
push 0x5b
call edi
test bx, ax
jne 0x417624
push 0x5c
call edi
test bx, ax
je 0x4175a7
mov edx, 1
mov dword [0x4e2114], 0
mov ecx, 0x8000012f
call fcn.00401a30
mov dword [0x4e2114], 1
jmp 0x417612
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [0x4e7828]
cmp eax, dword [0x4e3368]
jae 0x417667
mov cl, byte [0x4e7832]
and cl, bl
jmp 0x417669
xor cl, cl
mov bh, cl
xor al, al
not bh
mov byte [ebp - 3], cl
and bh, byte [0x4e7aa5]
and bh, bl
mov byte [ebp - 6], al
cmp byte [0x4e7b17], 0
mov byte [ebp - 1], bh
mov byte [0x4e7aa5], bh
je 0x41769c
not bh
and bh, bl
mov al, bh
mov bh, bl
mov byte [ebp - 1], bh
jmp 0x41769e
xor al, al
mov byte [ebp - 4], al
mov eax, dword [ebp - 0x28]
mov byte [ebp - 0x10], bh
cmp byte [eax + 0xf3], 0
je 0x4176d0
cmp byte [0x4e7b17], 0
jne 0x4176d0
cmp dword [ebp - 0x1c], 2
je 0x4176d0
mov edx, 2
mov cl, 0x14
call fcn.0041a800
mov dword [ebp - 0x30], eax
jmp 0x4176d7
mov dword [ebp - 0x30], 0
mov ecx, dword [ebp + 8]
mov eax, 0x1f4
mov dword [0x4e7b18], ecx
mov edx, 0x5dc
test ecx, ecx
je 0x417750
cmp ecx, 1
cmovne eax, edx
mov edx, 0x2ee0
mov dword [0x4e7b04], eax
mov eax, 0x36b0
cmovne eax, edx
call fcn.004b71a0
mov eax, dword [0x4e3ae4]
mov ecx, esp
mov byte [0x4e7aa7], bl
mov byte [0x4e7b14], 0
mov dword [0x4e7b00], 0
mov dword [eax], ecx
mov ecx, dword [ebp + 8]
mov dword [0x4e7b0c], 0x80000000
mov dword [0x4e7b10], 0x80000000
mov byte [0x4e7b15], 0
mov byte [0x4e7b16], 1
mov al, byte [0x4e4c0e]
mov byte [ebp - 0x1d], al
mov eax, dword [0x4e25bc]
cmp eax, 8
je 0x417767
cmp eax, 0xa
jne 0x41777f
mov edi, dword [ebp + 0xc]
test ecx, ecx
jne 0x417782
test edi, edi
jne 0x417782
mov cl, 1
mov byte [ebp - 0xc], 1
call fcn.004471a0
jmp 0x417786
mov edi, dword [ebp + 0xc]
mov byte [ebp - 0xc], 0
xor bl, bl
cmp word [esi], 0
mov byte [ebp - 0xa], bl
je 0x418117
jmp 0x4177a3
mov edi, dword [ebp + 0xc]
cmp dword [0x4e7b18], 0
mov byte [ebp - 5], 0
jne 0x41780f
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, dword [0x4e211c]
sub eax, dword [0x4e786c]
cmp eax, dword [ecx + 0xd8]
jbe 0x41780f
push 0
push 0
push 0
push 0
lea eax, [ebp - 0x98]
push eax
call dword [sym.imp.USER32.dll_PeekMessageW]
test eax, eax
je 0x417804
mov edx, 1
mov dword [0x4e2114], 0
or ecx, 0xffffffff
call fcn.00401a30
mov dword [0x4e2114], 1
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [0x4e786c], eax
mov eax, dword [ebp - 0x1c]
test eax, eax
jne 0x41803e
movzx eax, word [esi]
push eax
push 0x4cf91c
call dword [sym.imp.VCRUNTIME140.dll_wcschr]
add esp, 8
test eax, eax
je 0x41807b
movzx eax, word [esi]
add eax, 0xffffffdf
cmp eax, 0x5c
ja case.0x41784a.34
movzx eax, byte [eax + 0x4183ac]
jmp dword [eax*4 + 0x418390]
test bh, 3
jne case.0x41784a.34
or bl, 1
jmp 0x4180ff
test bh, 0x30
jne case.0x41784a.34
or bl, 0x10
jmp 0x4180ff
test bh, 0xc
jne case.0x41784a.34
or bl, 4
jmp 0x4180ff
test bh, 0xc0
jne case.0x41784a.34
or bl, 0x40
jmp 0x4180ff
lea edi, [esi + 2]
push 0x7d
push edi
call dword [sym.imp.VCRUNTIME140.dll_wcschr]
add esp, 8
mov dword [ebp - 0x18], eax
test eax, eax
je case.0x41784a.34
mov esi, edi
movzx ecx, word [esi]
cmp ecx, 0x20
je 0x4178be
cmp ecx, 9
jne 0x4178c3
add esi, 2
jmp 0x4178b1
mov edi, eax
sub edi, esi
sar edi, 1
mov dword [ebp - 0x34], edi
jne 0x417956
lea edi, [eax + 2]
movzx eax, word [edi]
cmp eax, 0x7d
jne 0x4178e5
mov dword [ebp - 0x18], edi
lea edi, [eax - 0x7c]
jmp 0x417953
cmp eax, 0x20
je 0x4178f3
cmp eax, 9
jne 0x418036
cmp ax, 0x20
je 0x4178ff
cmp ax, 9
jne 0x417908
movzx eax, word [edi + 2]
add edi, 2
jmp 0x4178f3
push 4
push str.Down
push edi
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsnicmp]
add esp, 0xc
test eax, eax
je 0x417936
push 2
push 0x4ce63c
push edi
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsnicmp]
add esp, 0xc
test eax, eax
jne 0x418036
push 0x7d
push edi
call dword [sym.imp.VCRUNTIME140.dll_wcschr]
add esp, 8
mov dword [ebp - 0x18], eax
test eax, eax
je case.0x41784a.34
mov edi, eax
sub edi, esi
sar edi, 1
mov dword [ebp - 0x34], edi
push 5
push 0x4ccb38
push esi
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsnicmp]
add esp, 0xc
test eax, eax
jne 0x417a16
mov eax, dword [ebp - 0x18]
xor ecx, ecx
mov word [eax], cx
lea ecx, [esi + 0xa]
nop word [eax + eax]
movzx eax, word [ecx]
cmp eax, 0x20
je 0x41798d
cmp eax, 9
jne 0x417992
add ecx, 2
jmp 0x417980
lea eax, [ebp - 0x4c]
push eax
lea eax, [ebp - 0x3c]
push eax
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 2]
push eax
lea eax, [ebp - 0x50]
push eax
lea edx, [ebp - 0x44]
call fcn.00419020
mov eax, dword [ebp - 0x18]
add esp, 0x14
mov ecx, 0x7d
push dword [ebp - 0x4c]
mov word [eax], cx
mov eax, dword [ebp - 0x3c]
cmp eax, 1
jge 0x4179ec
mov eax, dword [ebp - 0x28]
lea edx, [ebp - 0x50]
lea ecx, [ebp - 0x44]
movzx eax, byte [eax + 0xef]
push eax
lea eax, [ebp - 0x6c]
push eax
call fcn.00419ca0
mov esi, dword [ebp - 0x18]
add esp, 0xc
jmp 0x4180fd
push dword [ebp - 0x50]
mov cl, byte [ebp - 2]
xor edx, edx
push dword [ebp - 0x44]
push dword [ebp + 0xc]
push 0
push dword [ebp - 0x14]
push eax
push dword [ebp - 0x10]
push dword [ebp - 0xa]
call fcn.00418430
mov esi, dword [ebp - 0x18]
add esp, 0x24
jmp 0x4180fd
push 3
push 0x4cf92c
push esi
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsnicmp]
add esp, 0xc
test eax, eax
jne 0x417a3a
mov esi, dword [ebp - 0x18]
mov dword [ebp - 0x1c], 1
jmp 0x4180fd
push 4
push str.Text
push esi
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsnicmp]
add esp, 0xc
test eax, eax
jne 0x417a7c
lea ecx, [esi + 8]
movzx eax, word [ecx]
cmp eax, 0x20
je 0x417a5f
cmp eax, 9
jne 0x417a64
add ecx, 2
jmp 0x417a52
cmp ecx, dword [ebp - 0x18]
jne 0x418036
mov esi, dword [ebp - 0x18]
mov dword [ebp - 0x1c], 2
jmp 0x4180fd
mov eax, dword [ebp - 0x18]
xor ecx, ecx
mov ebx, 1
mov dword [ebp - 0x14], 2
mov edx, 0x4cf49c
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x3c], ebx
mov word [eax], cx
mov ecx, esi
mov dword [ebp - 0x40], edi
call fcn.00406460
mov dword [ebp - 0x58], eax
test eax, eax
je 0x417b63
movzx ecx, word [eax]
lea edi, [eax + 2]
mov dword [ebp - 0x5c], ecx
xor ecx, ecx
mov word [eax], cx
mov ecx, eax
sub ecx, esi
sar ecx, 1
mov dword [ebp - 0x40], ecx
movzx eax, word [edi]
cmp eax, 0x20
je 0x417ad4
cmp eax, 9
jne 0x417ad9
add edi, 2
jmp 0x417ac7
mov eax, dword [ebp - 0x18]
sub eax, edi
sar eax, 1
je 0x417b63
push 4
push str.Down
push edi
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsnicmp]
add esp, 0xc
test eax, eax
jne 0x417b3c
push 4
add edi, 8
mov dword [ebp - 0x14], eax
push str.Temp
push edi
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsnicmp]
add esp, 0xc
test eax, eax
jne 0x417b1b
mov dword [ebp - 0x2c], eax
jmp 0x417b63
xor eax, eax
cmp word [edi], 0x52
sete al
push eax
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_toupper]
add esp, 4
mov edi, eax
neg edi
sbb edi, edi
neg edi
inc edi
mov dword [ebp - 0x2c], edi
jmp 0x417b63
push 0x4ce63c
push edi
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsicmp]
add esp, 8
test eax, eax
jne 0x417b54
mov dword [ebp - 0x14], ebx
jmp 0x417b63
mov ecx, edi
call fcn.00417020
mov ebx, eax
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x3c], ebx
push dword [0x4e7af8]
lea eax, [ebp - 0xa]
mov ecx, esi
push eax
lea eax, [ebp - 0x60]
push eax
lea edx, [ebp - 2]
call fcn.0041bb90
mov eax, dword [ebp - 0x58]
add esp, 0xc
test eax, eax
je 0x417b8b
mov ecx, dword [ebp - 0x5c]
mov word [eax], cx
mov eax, dword [ebp - 0x18]
mov ecx, 0x7d
mov word [eax], cx
cmp ebx, 1
jl 0x418033
mov bh, byte [ebp - 2]
mov edi, dword [ebp - 0x60]
test bh, bh
jne 0x417f74
test di, di
jne 0x417f74
movzx eax, byte [esi]
push eax
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_isdigit]
add esp, 4
test eax, eax
mov eax, dword [ebp - 0x40]
je 0x417c6e
cmp eax, 1
jbe 0x417c71
cmp dword [0x4e7b18], 0
je 0x417c03
mov ecx, esi
call fcn.00417020
push eax
push 0
push 0
xor dl, dl
xor cl, cl
call fcn.00419fd0
mov bh, byte [ebp - 1]
add esp, 0xc
mov esi, dword [ebp - 0x18]
jmp 0x4180fd
mov eax, dword [ebp - 0x48]
mov dword [0x4e2114], 0
cmp dword [0x4e6ce0], eax
je 0x417c46
mov ecx, esi
call fcn.00417020
test eax, eax
js 0x417c46
mov ecx, esi
call fcn.00417020
push eax
call dword [sym.imp.KERNEL32.dll_Sleep]
mov bh, byte [ebp - 1]
mov esi, dword [ebp - 0x18]
mov dword [0x4e2114], 1
jmp 0x4180fd
mov ecx, esi
call fcn.00417020
mov edx, 1
mov ecx, eax
call fcn.00401a30
mov bh, byte [ebp - 1]
mov esi, dword [ebp - 0x18]
mov dword [0x4e2114], 1
jmp 0x4180fd
cmp eax, 1
jne 0x417cd4
cmp dword [ebp - 0x14], 1
je 0x418033
mov edi, dword [ebp + 0xc]
test edi, edi
je 0x417cb2
mov ebx, dword [ebp - 0x24]
test ebx, ebx
jle 0x418033
nop
movzx eax, word [esi]
push 0
push eax
push 0x102
push edi
call dword [sym.imp.USER32.dll_PostMessageW]
sub ebx, 1
jne 0x417c90
mov bh, byte [ebp - 1]
mov esi, dword [ebp - 0x18]
jmp 0x4180fd
mov al, byte [ebp - 0xa]
mov bh, byte [ebp - 1]
mov edx, dword [ebp - 0x24]
or al, bh
mov cx, word [esi]
movzx eax, al
push eax
call fcn.004185e0
mov esi, dword [ebp - 0x18]
add esp, 4
jmp 0x4180fd
mov ebx, dword [ebp + 0xc]
mov ecx, esi
mov edi, dword [ebp - 0x34]
test ebx, ebx
mov edx, edi
sete al
movzx eax, al
push eax
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x14]
push eax
call fcn.0041bc60
add esp, 0xc
mov byte [ebp - 2], al
test al, al
je 0x417df3
mov esi, dword [ebp - 0x14]
mov edi, ebx
test edi, edi
jne 0x417d1b
test esi, esi
jne 0x417d14
mov byte [ebp - 5], al
jmp 0x417d1b
mov cl, al
call fcn.004171f0
cmp dword [0x4e7b18], 0
je 0x417d2b
mov al, byte [0x4e7aa7]
jmp 0x417d32
xor cl, cl
call fcn.0041af60
push 0xffc3d44d
push 0
mov dl, al
mov al, byte [ebp - 0x10]
push 0
push edi
mov cl, al
mov byte [ebp - 1], al
call fcn.0041a910
mov ebx, dword [ebp - 0x24]
add esp, 0x10
test ebx, ebx
jle 0x418033
nop dword [eax]
mov dl, byte [ebp - 2]
mov ecx, esi
push 0xffc3d44d
push 1
push edi
push 0
call fcn.004189d0
add esp, 0x10
cmp dword [0x4e7b18], 0
jne 0x417ddf
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, dword [0x4e211c]
sub eax, dword [0x4e786c]
cmp eax, dword [ecx + 0xd8]
jbe 0x417ddf
push 0
push 0
push 0
push 0
lea eax, [ebp - 0x98]
push eax
call dword [sym.imp.USER32.dll_PeekMessageW]
test eax, eax
je 0x417dd4
mov edx, 1
mov dword [0x4e2114], 0
or ecx, 0xffffffff
call fcn.00401a30
mov dword [0x4e2114], 1
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [0x4e786c], eax
sub ebx, 1
jne 0x417d60
mov bh, byte [ebp - 1]
mov esi, dword [ebp - 0x18]
jmp 0x4180fd
cmp edi, 4
jbe 0x417e65
push 4
push str.ASC
push esi
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsnicmp]
add esp, 0xc
test eax, eax
jne 0x417e65
test ebx, ebx
jne 0x417e65
lea ecx, [esi + 6]
movzx eax, word [ecx]
cmp eax, 0x20
je 0x417e21
cmp eax, 9
jne 0x417e26
add ecx, 2
jmp 0x417e14
call fcn.004186f0
cmp dword [0x4e7b18], 2
mov eax, dword [0x4e211c]
jne 0x417e4f
mov ecx, dword [eax + 0x60]
call fcn.0041a5d0
mov bh, byte [ebp - 0x10]
mov esi, dword [ebp - 0x18]
mov byte [ebp - 1], bh
jmp 0x4180fd
mov ecx, dword [eax + 0x5c]
call fcn.0041a5d0
mov bh, byte [ebp - 0x10]
mov esi, dword [ebp - 0x18]
mov byte [ebp - 1], bh
jmp 0x4180fd
cmp edi, 2
jbe 0x417e57
push 2
push 0x4cf94c
push esi
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsnicmp]
add esp, 0xc
test eax, eax
jne 0x417e57
push 0x10
push eax
lea eax, [esi + 4]
push eax
call dword [sym.imp.api_ms_win_crt_convert_l1_1_0.dll_wcstol]
mov edx, eax
add esp, 0xc
cmp edx, 0x10000
jb 0x417ec4
sub edx, 0x10000
mov ecx, edx
mov eax, edx
shr ecx, 0xa
and eax, 0x3ff
and ecx, 0x3ff
sub ecx, 0x2800
sub eax, 0x2400
movzx ecx, cx
movzx esi, ax
jmp 0x417ec9
movzx ecx, dx
xor esi, esi
mov edi, ebx
mov bh, byte [ebp - 0x10]
mov byte [ebp - 1], bh
test edi, edi
je 0x417f00
push 0
movzx eax, cx
push eax
push 0x102
push edi
call dword [sym.imp.USER32.dll_PostMessageW]
test si, si
je 0x417f46
push 0
movzx eax, si
push eax
push 0x102
push edi
call dword [sym.imp.USER32.dll_PostMessageW]
jmp 0x417f46
cmp dword [0x4e7b18], 2
je 0x417f25
mov bl, byte [ebp - 0xa]
or bl, bh
mov dl, bl
call fcn.00417270
test si, si
je 0x417f46
mov dl, bl
mov ecx, esi
call fcn.00417270
jmp 0x417f46
mov eax, 0x30
mov word [ebp - 0x7c], ax
lea eax, [ebp - 0x7a]
push 0xa
push eax
push edx
call dword [sym.imp.api_ms_win_crt_convert_l1_1_0.dll__itow]
add esp, 0xc
lea ecx, [ebp - 0x7c]
call fcn.004186f0
cmp dword [0x4e7b18], 2
mov eax, dword [0x4e211c]
jne 0x417f64
mov ecx, dword [eax + 0x60]
call fcn.0041a5d0
mov esi, dword [ebp - 0x18]
jmp 0x4180fd
mov ecx, dword [eax + 0x5c]
call fcn.0041a5d0
mov esi, dword [ebp - 0x18]
jmp 0x4180fd
push 0
mov edx, edi
mov cl, bh
call fcn.0041b150
mov esi, dword [ebp - 0x14]
mov bl, al
add esp, 4
mov byte [ebp - 0x64], bl
test bl, bl
je 0x41800b
cmp dword [ebp + 0xc], 0
jne 0x41800b
test esi, esi
jne 0x417fc6
mov eax, dword [ebp - 0x2c]
mov byte [ebp - 5], bh
cmp eax, 1
jne 0x417fb4
mov al, byte [ebp - 1]
or byte [0x4e7aa5], bl
or al, bl
jmp 0x418005
cmp eax, 2
jne 0x417fbf
or byte [0x4e7aa6], bl
mov al, byte [ebp - 1]
or al, bl
jmp 0x418005
cmp esi, 1
jne 0x41800b
mov cl, bh
call fcn.004171f0
mov cl, byte [ebp - 4]
not bl
and byte [0x4e7aa6], bl
mov al, bl
and al, byte [0x4e7aa5]
and cl, bl
mov byte [0x4e7aa5], al
mov byte [ebp - 4], cl
cmp bh, 0xa5
jne 0x418003
cmp dword [0x4e7afc], 3
jne 0x418003
and cl, 0xfe
mov byte [ebp - 4], cl
or al, cl
mov byte [ebp - 0x10], al
mov byte [ebp - 1], al
push 0
push connect
push connect
push dword [ebp + 0xc]
mov edx, edi
mov cl, bh
push dword [ebp - 0x64]
push esi
push dword [ebp - 0x24]
push dword [ebp - 0x10]
push dword [ebp - 0xa]
call fcn.00418430
add esp, 0x24
mov bh, byte [ebp - 1]
mov esi, dword [ebp - 0x18]
jmp 0x4180fd
cmp eax, 2
jne 0x41807e
movzx eax, word [esi]
add eax, 0xfffffff8
cmp eax, 5
ja case.0x41804e.11
jmp dword [eax*4 + 0x41840c]
cmp word [esi + 2], 0xa
lea eax, [esi + 2]
cmove esi, eax
mov al, 0xd
mov byte [ebp - 2], al
jmp 0x4180a8
mov al, 8
mov byte [ebp - 2], al
jmp 0x4180a8
mov al, 9
mov byte [ebp - 2], al
jmp 0x4180a8
mov byte [ebp - 2], 0
jmp 0x4180d2
mov eax, dword [ebp - 0x1c]
or bl, bh
je 0x41808a
test eax, eax
jne 0x41808a
mov al, 1
jmp 0x41808c
xor al, al
mov cx, word [esi]
lea edx, [ebp - 0xa]
push eax
push dword [0x4e7af8]
call fcn.0041bad0
add esp, 8
mov byte [ebp - 2], al
test al, al
je 0x4180cf
push 0
push connect
push connect
push edi
push 0
push 2
push 1
push dword [ebp - 0x10]
xor edx, edx
mov cl, al
push dword [ebp - 0xa]
call fcn.00418430
add esp, 0x24
jmp 0x4180fd
mov bl, byte [ebp - 0xa]
movzx ecx, word [esi]
test edi, edi
je 0x4180ea
push 0
push ecx
push 0x102
push edi
call dword [sym.imp.USER32.dll_PostMessageW]
jmp 0x4180fd
or bl, bh
mov edx, 1
movzx eax, bl
push eax
call fcn.004185e0
add esp, 4
xor bl, bl
mov byte [ebp - 0xa], bl
mov al, byte [ebp - 5]
add esi, 2
mov byte [0x4e7aa4], al
cmp word [esi], 0
jne 0x4177a0
cmp dword [0x4e7b18], 0
je 0x4181c2
or esi, 0xffffffff
cmp byte [0x4e7b15], 0
mov dword [ebp - 0x2c], esi
jne 0x418181
cmp dword [0x4e7b00], 0
jbe 0x418181
cmp byte [0x4e7b17], 0
je 0x418149
xor bl, bl
jmp 0x418151
mov bl, byte [ebp - 6]
not bl
and bl, byte [ebp - 3]
or bl, byte [0x4e7aa6]
mov dl, byte [0x4e7aa7]
or bl, bh
push 0xffc3d44d
push 1
push 1
push 0
mov cl, bl
call fcn.0041a910
add esp, 0x10
lea ecx, [ebp - 0x2c]
mov dl, bl
call fcn.0041a3c0
mov esi, dword [ebp - 0x2c]
cmp dword [0x4e7b18], 1
mov eax, 0x5dc
mov ecx, 0x1f4
cmove eax, ecx
cmp dword [0x4e7b04], eax
jbe 0x4181ac
push dword [0x4e56f0]
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov ecx, esi
mov dword [0x4e7b18], 0
call fcn.0041a5d0
jmp 0x418248
cmp dword [0x4e4bb4], 0
je 0x4181d6
mov cl, byte [0x4e4c3f]
mov dl, byte [ebp - 3]
jmp 0x4181ff
cmp dword [0x4e3368], 0
jl 0x4181fa
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [0x4e7828]
cmp eax, dword [0x4e3368]
jb 0x4181fa
mov dl, byte [ebp - 3]
xor cl, cl
jmp 0x4181ff
mov dl, byte [ebp - 3]
mov cl, dl
or cl, byte [0x4e7aa6]
cmp byte [0x4e7b17], 0
je 0x418220
mov al, cl
xor al, dl
mov bl, al
and al, cl
and bl, dl
not bl
and bl, bh
or bl, al
jmp 0x418229
mov bl, byte [ebp - 6]
not bl
and bl, cl
or bl, bh
push 0xffc3d44d
push 1
push 1
push dword [ebp + 0xc]
xor cl, cl
call fcn.0041af60
mov dl, al
mov cl, bl
call fcn.0041a910
add esp, 0x10
cmp dword [0x4e4bb4], 0
je 0x41826b
mov cl, byte [0x4e4c42]
mov al, cl
xor al, byte [0x4e4c43]
and al, cl
not al
and cl, al
mov byte [0x4e4c42], cl
cmp dword [ebp - 0x30], 1
jne 0x418307
mov esi, dword [sym.imp.USER32.dll_GetKeyState]
push 0x14
call esi
test al, 1
jne 0x418307
push 0x14
call esi
mov ecx, 0x8000
test cx, ax
je 0x4182af
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 0x14
mov ecx, 1
call fcn.004189d0
add esp, 0x10
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 0x14
mov ecx, 2
call fcn.004189d0
mov ebx, dword [sym.imp.USER32.dll_GetForegroundWindow]
add esp, 0x10
push 0
call ebx
mov esi, dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
push eax
call esi
cmp eax, dword [0x4e6ce0]
jne 0x418313
mov edx, 1
mov dword [0x4e2114], 0
or ecx, 0xffffffff
call fcn.00401a30
mov dword [0x4e2114], 1
jmp 0x418313
mov ebx, dword [sym.imp.USER32.dll_GetForegroundWindow]
mov esi, dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
cmp byte [ebp - 0xb], 0
je 0x41832a
push 0
push dword [ebp - 0x38]
push dword [0x4e6ce0]
call dword [sym.imp.USER32.dll_AttachThreadInput]
cmp byte [ebp - 0xc], 0
je 0x41833d
cmp byte [ebp - 0x1d], 0
jne 0x41833d
xor cl, cl
call fcn.004471a0
cmp dword [ebp + 8], 1
jne 0x418373
push 0
call ebx
push eax
call esi
cmp eax, dword [0x4e6ce0]
jne 0x418373
mov edx, 1
mov dword [0x4e2114], 0
or ecx, 0xffffffff
call fcn.00401a30
mov dword [0x4e2114], 1
mov eax, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x68]
mov dword [eax + 0x5c], ecx
mov ecx, dword [ebp - 0x54]
mov dword [eax + 0x64], ecx
lea esp, [ebp - 0xa4]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret