Function at 0x405590
Capabilities:
Check for time delay via gettickcount
Encrypt data using speck

Disassembly:
sub esp, 0x114
push ebx
push ebp
push esi
mov eax, 0x7fff
mov dword [esp + 0x24], edx
push edi
mov di, word [esp + 0x134]
mov esi, ecx
mov dword [esp + 0x44], eax
mov eax, dword [esp + 0x13c]
mov dword [esp + 0x1c], esi
movzx edx, di
cmp eax, 0xffc3d44f
je 0x4055d9
cmp eax, 0xffc3d44e
je 0x4055d9
mov byte [esp + 0x22], 0
cmp eax, 0xffc3d44d
jne 0x4055de
mov byte [esp + 0x22], 1
mov ecx, dword [0x4dbc80]
mov ebp, dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ebx, dword [esp + 0x130]
test ecx, ecx
jne 0x405602
lea eax, [esp + 0x50]
mov dword [esp + 0x14], eax
jmp 0x4056be
mov eax, dword [0x4dbcac]
imul esi, eax, 0xd4
inc eax
add esi, ecx
xor ecx, ecx
cmp eax, dword [0x4d78cc]
mov dword [esp + 0x14], esi
cmovge eax, ecx
mov dword [0x4dbcac], eax
mov eax, dword [esp + 0x138]
mov byte [esi], bl
mov byte [esi + 6], al
call ebp
mov ecx, eax
mov dword [0x4dbca8], eax
sub ecx, dword [0x4dd5f0]
mov dword [0x4dd5f0], eax
movd xmm0, ecx
cvtdq2pd xmm0, xmm0
shr ecx, 0x1f
addsd xmm0, qword [ecx*8 + 0x4d17a0]
cvtpd2ps xmm0, xmm0
divss xmm0, dword [0x4d1704]
movss dword [esi + 8], xmm0
call dword [sym.imp.USER32.dll_GetForegroundWindow]
mov esi, eax
mov eax, dword [esp + 0x14]
lea ecx, [eax + 0xc]
test esi, esi
je 0x4056a4
cmp esi, dword [0x4dbca4]
je 0x40569d
push esi
push ecx
push 0x418
push dword [0x4dbc70]
call dword [sym.imp.USER32.dll_PostMessageW]
mov eax, dword [esp + 0x14]
jmp 0x4056b1
xor edx, edx
mov word [ecx], dx
jmp 0x4056b1
mov dword [ecx], 0x2f004e
mov dword [ecx + 4], 0x41
mov dword [0x4dbca4], esi
mov esi, dword [esp + 0x1c]
movzx edx, di
cmp bl, 0xe7
jne 0x405714
mov edx, dword [esp + 0x14]
mov ecx, dword [esp + 0x12c]
push 0x7fff
push edx
push dword [esp + 0x140]
mov ax, word [ecx + 4]
push 0
mov word [edx + 2], ax
mov eax, 0x55
push 0xe7
push ecx
mov word [edx + 4], ax
mov ecx, esi
push dword [esp + 0x140]
mov edx, dword [esp + 0x44]
call fcn.00406f40
add esp, 0x1c
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x114
ret
mov word [eax + 2], di
mov cl, 3
mov edi, dword [esp + 0x1c]
mov al, bl
add al, 0x64
mov esi, 0x20
cmp cl, al
sbb eax, eax
and eax, edx
movzx eax, ax
mov dword [esp + 0x24], eax
cmp edi, dword [0x4dbeac]
jne 0x40576e
mov cl, byte [esp + 0x140]
and cl, 1
mov dword [esp + 0x34], ecx
jne 0x4057f1
mov al, byte [esp + 0x138]
movzx ecx, bl
xor al, 1
shl al, 7
mov byte [ecx + 0x4dbec0], al
mov ecx, dword [esp + 0x34]
jmp 0x4057f1
mov edx, dword [esp + 0x140]
mov ecx, edx
mov ebp, dword [0x4dd674]
movzx edi, bl
shr ecx, 4
and ecx, 0xffffff01
mov dword [esp + 0x34], ecx
lea eax, [edi + edi*4]
cmp byte [ebp + eax*4 + 8], 0
mov ebp, dword [sym.imp.KERNEL32.dll_GetTickCount]
jne 0x4057ed
test dl, 0x10
jne 0x4057ed
cmp bl, 0xa0
je 0x4057ac
cmp bl, 0xa1
jne 0x4057cb
cmp byte [esp + 0x138], 0
jne 0x4057cb
cmp bl, 0xa0
mov eax, esi
mov edx, 0x10
cmove eax, edx
test byte [0x4dbeba], al
jne 0x4057ed
call ebp
mov ecx, dword [esp + 0x34]
mov dword [0x4dd5f8], eax
mov dword [0x4dd5f4], eax
mov al, byte [esp + 0x138]
xor al, 1
shl al, 7
mov byte [edi + 0x4dbec0], al
mov edi, dword [esp + 0x1c]
mov dl, byte [esp + 0x22]
test dl, dl
je 0x405800
mov eax, 0x69
jmp 0x40580d
mov eax, 0x61
test cl, cl
cmovne esi, eax
movzx eax, si
cmp byte [0x4dbeb8], 0
mov ecx, dword [esp + 0x14]
lea esi, [ecx + 4]
mov word [esi], ax
mov dword [esp + 0x3c], esi
je 0x405850
cmp bl, 0x5b
je 0x40582e
cmp bl, 0x5c
jne 0x405850
mov eax, dword [esp + 0x138]
test al, al
jne 0x405857
push 0
push SysReAllocString
push 0x7fff
push ecx
push 0
push ecx
mov ecx, edi
jmp 0x406db6
mov eax, dword [esp + 0x138]
cmp byte [0x4dd666], 0
mov esi, dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
mov ebp, dword [sym.imp.USER32.dll_FindWindowW]
je 0x4058fc
cmp bl, 0x1b
jne 0x4058fc
test al, al
jne 0x4058fc
push 0
push 0x4c5b30
call ebp
test eax, eax
je 0x4058f8
push 0
push eax
call esi
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp esi, eax
jne 0x4058f2
push 0xffc3d44d
push 0
push 0
push 0
mov dl, bl
xor ecx, ecx
call fcn.004103a0
mov dl, byte [0x4dbebd]
mov ecx, 1
push 0xffc3d44d
shr dl, 3
push 0
and dl, 1
push 0
push 0
or dl, 0xa4
call fcn.004103a0
add esp, 0x20
push 0
push SysReAllocString
push 0x7fff
push dword [esp + 0x20]
push 0
push ecx
push 0x1b
mov ecx, edi
jmp 0x406db7
mov esi, dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
mov dl, byte [esp + 0x22]
mov eax, dword [esp + 0x24]
movzx eax, ax
mov dword [esp + 0x34], eax
lea ecx, [eax + eax*4]
mov eax, dword [0x4dd678]
lea edi, [eax + ecx*4]
mov eax, dword [esp + 0x1c]
mov cl, byte [edi + 0x13]
mov byte [esp + 0x1b], cl
cmp eax, dword [0x4dbeb0]
jne 0x405929
test cl, cl
jne 0x40593c
mov ecx, dword [0x4dd674]
movzx eax, bl
lea eax, [eax + eax*4]
lea edi, [ecx + eax*4]
mov eax, dword [esp + 0x1c]
test dl, dl
je 0x4059aa
cmp dword [esp + 0x13c], 0xffc3d44e
mov eax, dword [esp + 0x138]
jne 0x405972
test al, al
je 0x405972
cmp dword [0x4dbfcc], edi
jne 0x405972
mov byte [edi + 0xd], 0
mov byte [edi + 0x10], 0
mov dword [0x4dbfcc], 0
push 0x7fff
push dword [esp + 0x18]
push eax
mov ecx, dword [esp + 0x28]
push dword [esp + 0x30]
mov edx, dword [esp + 0x38]
push ebx
push dword [esp + 0x140]
push dword [esp + 0x140]
call fcn.00406f40
add esp, 0x1c
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x114
ret
mov ecx, dword [esp + 0x138]
mov edx, 0x7fff
mov dword [esp + 0x4c], edx
test cl, cl
jne 0x4059c5
mov byte [edi + 0x11], cl
mov word [edi + 4], dx
cmp eax, dword [0x4dbeac]
jne 0x405a3c
test bl, bl
jne 0x405a08
mov edx, dword [esp + 0x28]
push 0x7fff
push dword [esp + 0x18]
push ecx
push dword [esp + 0x30]
mov ecx, eax
push 0
push dword [esp + 0x140]
push dword [esp + 0x140]
call fcn.00406f40
add esp, 0x1c
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x114
ret
cmp bl, 1
je 0x405a12
cmp bl, 2
jne 0x405a3c
cmp dword [0x4dbc4c], 0
jne 0x405a6a
push 0
push str.32768
call ebp
test eax, eax
je 0x405a35
push 0
push eax
call esi
cmp eax, dword [0x4dcd34]
je 0x405a63
mov ecx, dword [esp + 0x138]
mov eax, dword [0x4dbfcc]
mov ebp, dword [esp + 0x1c]
test eax, eax
je 0x405a9a
cmp eax, edi
je 0x405a9a
test cl, cl
jne 0x405a9a
cmp ebp, dword [0x4dbeb0]
jne 0x405a84
xor eax, eax
cmp byte [edi + 8], al
sete al
jmp 0x405a8d
mov ecx, dword [esp + 0x138]
mov al, cl
mov byte [edi + 0x10], 0
xor al, 1
mov byte [edi + 0xd], al
push 0x7fff
push dword [esp + 0x18]
push ecx
jmp 0x40597c
mov eax, dword [0x4dbfcc]
movzx eax, byte [eax + 8]
test eax, eax
je 0x405a9a
mov eax, dword [0x4dbfcc]
mov byte [eax + 0x12], 1
cmp byte [edi + 9], 0
jne 0x405abe
cmp byte [edi + 0xa], 0
jne 0x405abe
push 0x7fff
push dword [esp + 0x18]
mov al, cl
xor al, 1
push ecx
mov byte [edi + 0xd], al
mov ecx, ebp
jmp 0x405980
mov esi, 0x7fff
xor eax, eax
mov dword [esp + 0x2c], esi
mov dword [esp + 0x30], esi
mov dword [esp + 0x38], eax
test cl, cl
je 0x405b00
mov dh, byte [edi + 0x10]
mov al, byte [edi + 0xd]
mov byte [esp + 0x13], al
movzx eax, word [edi + 4]
mov byte [esp + 0x12], dh
mov edx, esi
mov byte [edi + 0x10], 0
cmp ax, dx
je 0x405b10
mov dword [esp + 0x2c], eax
mov dword [esp + 0x30], eax
mov word [edi + 4], dx
jmp 0x405b10
mov al, byte [esp + 0x13]
mov byte [esp + 0x13], al
mov al, byte [esp + 0x13]
mov byte [esp + 0x12], al
mov al, cl
xor dl, dl
xor al, 1
mov byte [edi + 0xd], al
cmp ebp, dword [0x4dbeb0]
jne 0x405b90
cmp byte [edi + 8], dl
je 0x405bac
mov ecx, dword [0x4dd674]
cmp byte [ecx + 0xcb5], dl
jne 0x405b44
cmp byte [ecx + 0xcc9], dl
jne 0x405b44
xor al, al
jmp 0x405b46
mov al, 1
cmp byte [ecx + 0xcdd], 0
mov byte [ecx + 0x161], al
jne 0x405b62
cmp byte [ecx + 0xcf1], 0
jne 0x405b62
xor al, al
jmp 0x405b64
mov al, 1
cmp byte [ecx + 0xc8d], 0
mov byte [ecx + 0x175], al
jne 0x405b86
cmp byte [ecx + 0xca1], 0
jne 0x405b86
xor al, al
mov byte [ecx + 0x14d], al
jmp 0x405bac
mov al, 1
mov byte [ecx + 0x14d], al
jmp 0x405bac
cmp dword [0x4dbeb0], 0
jne 0x405bac
mov cl, 1
call fcn.00412810
mov byte [0x4dbebc], al
mov dl, 1
mov byte [0x4dbebd], al
mov eax, dword [edi]
test eax, eax
je 0x405bbc
cmp dword [eax], 6
mov byte [esp + 0x22], 1
je 0x405bc1
mov byte [esp + 0x22], 0
test dl, dl
jne 0x405bcc
mov cl, 1
call fcn.00412810
mov cl, byte [edi + 9]
mov edx, dword [esp + 0x138]
test cl, cl
je 0x405e48
test dl, dl
jne 0x405e48
mov eax, dword [0x4dbfcc]
test eax, eax
je 0x405bfc
cmp byte [edi + 0xa], dl
je 0x405bfc
cmp edi, eax
jne 0x405e48
cmp cl, 1
jne 0x405ca9
cmp byte [esp + 0x1b], 0
mov ecx, dword [esp + 0x34]
jne 0x405c13
movzx ecx, bl
xor edx, edx
movzx eax, cx
cmp byte [esp + 0x1b], dl
mov dword [esp + 0x48], ecx
cmovne edx, eax
movzx eax, cl
xor ecx, ecx
cmp byte [esp + 0x1b], cl
push 0
cmovne eax, ecx
mov cl, al
call fcn.00412a20
mov ch, al
xor edx, edx
xor eax, eax
mov byte [esp + 0x27], ch
add esp, 4
mov dword [esp + 0x40], edx
cmp ax, word [0x4dbffc]
jae 0x405d88
mov cl, byte [0x4dbea0]
nop dword [eax]
cmp byte [esp + 0x1b], 0
mov eax, dword [0x4dbfec]
mov ebp, dword [eax + edx*4]
je 0x405c75
movzx eax, word [ebp + 0xa]
jmp 0x405c79
movzx eax, byte [ebp + 0x11]
cmp dword [esp + 0x48], eax
je 0x405c88
test byte [ebp + 0xe], ch
je 0x405d70
cmp word [ebp + 6], 0
je 0x405d14
cmp byte [ebp + 0x19], 0
je 0x405d70
test cl, cl
jne 0x405d70
mov ebp, dword [esp + 0x1c]
xor dl, dl
cmp edi, dword [0x4dbfcc]
je 0x405cbc
mov dword [0x4dbfcc], edi
mov byte [edi + 0x12], dl
cmp byte [edi + 0xa], 0
je 0x405dd8
mov al, byte [edi + 8]
mov cl, byte [0x4dbebc]
test al, al
je 0x405cd7
not al
and cl, al
test cl, cl
jne 0x405ce9
test dl, dl
jne 0x405ce9
test byte [edi + 0xc], 1
je 0x405dd8
cmp ebp, dword [0x4dbeb0]
jne 0x405d8f
cmp byte [esp + 0x1b], 0
je 0x405d8f
mov eax, dword [0x4dd66c]
movzx ecx, cl
shl ecx, 9
add ecx, dword [esp + 0x34]
jmp 0x405d9f
mov esi, dword [ebp + 0x20]
mov eax, esi
test eax, eax
je 0x405d70
nop dword [eax]
cmp byte [eax + 0x20], 0
jne 0x405d30
mov eax, dword [eax + 0xc]
test eax, eax
jne 0x405d20
jmp 0x405d70
cmp byte [esi + 0x20], 0
je 0x405d61
test cl, cl
je 0x405d40
cmp byte [esi + 0x21], 0
je 0x405d61
mov ecx, dword [esi + 8]
test ecx, ecx
je 0x405ca5
mov edx, dword [ebp + 0x1c]
call fcn.00409e70
test eax, eax
jne 0x405ca5
mov cl, byte [0x4dbea0]
mov esi, dword [esi + 0xc]
test esi, esi
jne 0x405d30
mov edx, dword [esp + 0x40]
mov ch, byte [esp + 0x23]
movzx eax, word [0x4dbffc]
inc edx
mov dword [esp + 0x40], edx
cmp edx, eax
jl 0x405c60
mov ebp, dword [esp + 0x1c]
mov dl, 1
jmp 0x405cbc
movzx ecx, cl
movzx eax, bl
shl ecx, 8
add ecx, eax
mov eax, dword [0x4dd668]
movzx eax, word [eax + ecx*2]
movzx esi, ax
mov dword [esp + 0x2c], esi
mov dword [esp + 0x30], esi
test ax, ax
jns 0x405db9
mov word [edi + 4], ax
jmp 0x405de6
and eax, 0x7fff
cmp ax, word [0x4dbffc]
jae 0x405ddc
mov ecx, eax
mov eax, dword [0x4dd670]
mov ax, word [eax + ecx*2]
mov word [edi + 4], ax
jmp 0x405ddc
mov esi, dword [esp + 0x2c]
mov eax, 0x7fff
cmp si, ax
jne 0x405e41
test dl, dl
je 0x405dfa
mov eax, dword [esp + 0x3c]
mov ecx, 0x23
or byte [edi + 0xc], 8
mov word [eax], cx
cmp byte [edi + 8], 0
jne 0x405e2f
test byte [edi + 0xc], 1
jne 0x405e2f
cmp byte [esp + 0x22], 0
jne 0x405e2f
test dl, dl
jne 0x405e2f
push 0
push SysReAllocString
push 0x7fff
push dword [esp + 0x20]
mov byte [edi + 0x11], 1
push 0
push ecx
mov ecx, ebp
jmp 0x406db6
push 0x7fff
push dword [esp + 0x18]
mov ecx, ebp
push 0
jmp 0x405980
mov edx, dword [esp + 0x138]
cmp byte [edi + 0xa], 0
mov byte [esp + 0x23], 0
je 0x405ec0
test dl, dl
je 0x405ec0
mov ah, byte [esp + 0x12]
cmp dword [0x4dbfcc], edi
jne 0x405e71
test ah, ah
je 0x405ec0
mov dword [0x4dbfcc], 0
cmp byte [edi + 0xb], 0
jne 0x405ebb
mov al, byte [edi + 0xc]
test al, 8
je 0x405e87
xor cl, cl
and al, 0xf7
mov byte [edi + 0xc], al
jmp 0x405e89
mov cl, 1
test ah, ah
je 0x405eaa
test cl, cl
je 0x405eaa
push 0
push SysReAllocString
push 0x7fff
push dword [esp + 0x20]
push edx
push ecx
mov ecx, ebp
jmp 0x406db6
push 0x7fff
push dword [esp + 0x18]
mov ecx, ebp
push edx
jmp 0x405980
mov byte [esp + 0x23], 1
cmp byte [edi + 9], 0
je 0x406038
test dl, dl
je 0x406038
mov eax, dword [0x4dbfcc]
xor ecx, ecx
cmp eax, edi
cmove eax, ecx
mov dword [0x4dbfcc], eax
cmp byte [edi + 0xe], cl
je 0x405f02
push 0xffc3d44d
push ecx
push ecx
mov byte [edi + 0xe], cl
mov dl, 0x12
push ecx
mov ecx, 1
call fcn.004103a0
add esp, 0x10
cmp byte [edi + 0xf], 0
je 0x405f26
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 0x10
mov byte [edi + 0xf], 0
mov ecx, 1
call fcn.004103a0
add esp, 0x10
mov edx, dword [esp + 0x2c]
mov esi, 0x7fff
cmp dx, si
jne 0x405f57
mov al, byte [edi + 0xc]
test al, 8
je 0x405f57
and al, 0xf7
mov byte [edi + 0xc], al
push 0x7fff
push dword [esp + 0x18]
mov ecx, ebp
push dword [esp + 0x140]
jmp 0x405980
mov cl, byte [esp + 0x22]
mov al, byte [edi + 0x12]
test cl, cl
je 0x405fe4
cmp al, 2
jne 0x405fbc
mov esi, dword [esp + 0x24]
mov dl, bl
push 0xffc3d44e
push 0
push 0
push esi
mov ecx, 1
call fcn.004103a0
push 0xffc3d44d
push 0
push 0
push esi
mov dl, bl
mov ecx, 2
call fcn.004103a0
add esp, 0x20
push 0
push SysReAllocString
push 0x7fff
push dword [esp + 0x20]
push dword [esp + 0x148]
push ecx
mov ecx, ebp
jmp 0x406db6
cmp al, 1
je 0x405f40
cmp byte [edi + 0xa], 0
jne 0x406014
cmp byte [edi + 8], 0
jne 0x405f40
test byte [edi + 0xc], 1
jne 0x405f40
test cl, cl
jne 0x405f40
jmp 0x405f9d
test al, al
je 0x405fc0
cmp dx, si
jne 0x405fc0
cmp byte [edi + 8], 0
jne 0x405f40
test byte [edi + 0xc], 1
je 0x405f9d
push 0x7fff
push dword [esp + 0x18]
mov ecx, ebp
push dword [esp + 0x140]
jmp 0x405980
cmp byte [esp + 0x13], 0
jne 0x40603c
cmp byte [edi + 0xb], 0
jne 0x40603c
push 0x7fff
push dword [esp + 0x18]
mov ecx, ebp
push dword [esp + 0x140]
jmp 0x405980
mov edx, dword [esp + 0x2c]
cmp dword [0x4dbfcc], 0
mov byte [esp + 0x12], 0
je 0x40646d
mov ecx, dword [esp + 0x138]
test cl, cl
je 0x406063
cmp byte [edi + 0xb], 0
je 0x40646d
mov ebp, 0x7fff
cmp dx, bp
jne 0x406730
movzx esi, word [edi + 6]
mov eax, 0x7fff
xor ebp, ebp
cmp si, ax
je 0x40625f
mov eax, dword [0x4dbfec]
movzx ecx, si
mov edx, dword [eax + ecx*4]
mov al, byte [edx + 0x11]
test al, al
jne 0x4060d5
cmp word [edx + 0xa], 0
je 0x40610f
movzx esi, word [edx + 0xc]
movzx eax, word [edx + 0xa]
lea ecx, [eax + eax*4]
mov eax, dword [0x4dd678]
lea eax, [eax + ecx*4]
cmp byte [eax + 0xd], 0
je 0x4060fd
cmp byte [edx + 0x16], 0
je 0x4060ee
cmp byte [esp + 0x138], 0
jne 0x40610d
mov ax, word [edx + 4]
mov word [edi + 4], ax
test ebp, ebp
jne 0x406117
jmp 0x4060fd
movzx esi, word [edx + 0xc]
test al, al
je 0x4060a2
mov ecx, dword [0x4dd674]
movzx eax, al
lea eax, [eax + eax*4]
lea eax, [ecx + eax*4]
jmp 0x4060b1
cmp byte [esp + 0x138], 0
jne 0x4060fd
test ebp, ebp
cmove ebp, edx
mov eax, 0x7fff
cmp si, ax
jne 0x406085
jmp 0x40610f
mov ebp, edx
test ebp, ebp
je 0x406254
movzx ecx, byte [ebp + 0x11]
cmp ecx, 0x12
ja case.0x406127.1
movzx eax, byte [ecx + 0x406de8]
jmp dword [eax*4 + 0x406dd4]
mov ecx, dword [0x4dd674]
mov eax, 0xc80
mov edx, 0xc94
cmp byte [ecx + 0xca1], 0
cmovne eax, edx
add eax, ecx
jmp 0x4061a5
mov ecx, dword [0x4dd674]
mov eax, 0xca8
mov edx, 0xcbc
cmp byte [ecx + 0xcc9], 0
cmovne eax, edx
add eax, ecx
jmp 0x4061a5
mov ecx, dword [0x4dd674]
mov eax, 0xcd0
mov edx, 0xce4
cmp byte [ecx + 0xcf1], 0
cmovne eax, edx
add eax, ecx
jmp 0x4061a5
movzx eax, word [ebp + 0xa]
lea ecx, [eax + eax*4]
mov eax, dword [0x4dd678]
lea eax, [eax + ecx*4]
jmp 0x4061a5
lea eax, [ecx + ecx*4]
mov ecx, dword [0x4dd674]
lea eax, [ecx + eax*4]
mov dword [0x4dbfcc], eax
movzx eax, word [ebp + 6]
test ax, ax
je 0x4061ca
mov edx, eax
mov eax, dword [0x4dbfcc]
mov dword [esp + 0x30], edx
movzx esi, dx
mov byte [eax + 0x12], 2
jmp 0x406258
movzx eax, word [ebp + 4]
lea ecx, [esp + 0x30]
mov ebp, dword [esp + 0x3c]
mov dl, byte [esp + 0x138]
mov dword [esp + 0x30], eax
lea eax, [esp + 0x12]
push ebp
push eax
lea eax, [edi + 0xc]
push eax
call fcn.0040a7e0
mov edx, eax
add esp, 0xc
test edx, edx
je 0x406227
mov esi, dword [esp + 0x13c]
lea ecx, [esi + 0x3c2c17]
cmp ecx, 0x66
ja 0x40623c
movzx ecx, byte [edx + 0x1c]
mov eax, 0xffc3d44d
sub eax, esi
cmp eax, ecx
jg 0x40623c
test ebp, ebp
je 0x406227
mov eax, 0x69
mov word [ebp], ax
push 0x7fff
push dword [esp + 0x18]
push dword [esp + 0x140]
jmp 0x40597c
xor eax, eax
mov dword [esp + 0x38], edx
mov eax, dword [0x4dbfcc]
mov edx, dword [esp + 0x30]
movzx esi, dx
mov byte [eax + 0x12], 2
jmp 0x406258
mov edx, dword [esp + 0x2c]
mov ecx, dword [esp + 0x138]
mov eax, 0x7ffe
cmp si, ax
je 0x406277
mov eax, 0x7ffd
cmp si, ax
jne 0x40646d
test cl, cl
jne 0x40627f
mov byte [edi + 0x10], 1
test byte [0x4dbebd], 0xc
jne 0x4062a6
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 0x12
xor ecx, ecx
call fcn.004103a0
mov ecx, dword [esp + 0x148]
add esp, 0x10
cmp bl, 0xa2
je 0x4062b0
cmp bl, 0xa3
jne 0x4062d3
mov ebp, dword [esp + 0x24]
test cl, cl
jne 0x4062d7
push 0xffc3d44d
push 0
push 0
push ebp
mov dl, bl
mov ecx, 1
call fcn.004103a0
add esp, 0x10
jmp 0x4062d7
mov ebp, dword [esp + 0x24]
mov eax, dword [0x4dbfcc]
mov byte [eax + 0xe], 1
mov eax, 0x7ffd
cmp si, ax
jne 0x406318
test byte [0x4dbebd], 0x30
jne 0x40630a
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 0x10
xor ecx, ecx
call fcn.004103a0
add esp, 0x10
mov eax, dword [0x4dbfcc]
mov byte [eax + 0xf], 1
jmp 0x406395
mov eax, 0x7ffe
cmp si, ax
jne 0x406395
cmp bl, 0xa0
je 0x40632c
cmp bl, 0xa1
jne 0x40634f
cmp byte [esp + 0x138], 0
jne 0x40634f
push 0xffc3d44d
push 0
push 0
push ebp
mov dl, bl
mov ecx, 1
call fcn.004103a0
add esp, 0x10
test byte [0x4dbebd], 0x10
je 0x406372
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 0xa0
mov ecx, 1
call fcn.004103a0
add esp, 0x10
test byte [0x4dbebd], 0x20
je 0x406395
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 0xa1
mov ecx, 1
call fcn.004103a0
add esp, 0x10
test byte [0x4dbebd], 1
je 0x4063b8
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 0xa2
mov ecx, 1
call fcn.004103a0
add esp, 0x10
test byte [0x4dbebd], 2
je 0x4063db
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 0xa3
mov ecx, 1
call fcn.004103a0
add esp, 0x10
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 9
mov ecx, 2
call fcn.004103a0
mov eax, 0x7ffd
add esp, 0x10
cmp si, ax
jne 0x40643c
mov eax, dword [0x4dbfcc]
cmp byte [eax + 0xf], 0
je 0x40643c
cmp bl, 0x60
jb 0x406414
cmp bl, 0x69
jbe 0x406419
cmp bl, 0x6e
jne 0x40643c
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 0x10
mov ecx, 1
call fcn.004103a0
mov eax, dword [0x4dbfcc]
add esp, 0x10
mov byte [eax + 0xf], 0
mov eax, dword [esp + 0x3c]
mov ecx, 0x68
mov word [eax], cx
mov eax, dword [esp + 0x138]
test al, al
jne 0x406457
mov byte [edi + 0x11], 1
push 0
push SysReAllocString
push 0x7fff
push dword [esp + 0x20]
push eax
jmp 0x406db1
mov eax, 0x7fff
cmp dx, ax
jne 0x406729
mov al, byte [edi + 8]
mov dl, byte [0x4dbebc]
test al, al
je 0x40648c
not al
and dl, al
mov eax, dword [esp + 0x1c]
mov dh, byte [esp + 0x1b]
cmp eax, dword [0x4dbeb0]
jne 0x4064b4
test dh, dh
je 0x4064b4
mov eax, dword [0x4dd66c]
movzx ecx, dl
shl ecx, 9
add ecx, dword [esp + 0x34]
movzx ebp, bl
jmp 0x4064c4
mov eax, dword [0x4dd668]
movzx ecx, dl
movzx ebp, bl
shl ecx, 8
add ecx, ebp
movzx eax, word [eax + ecx*2]
movzx ecx, ax
movzx esi, ax
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x30], ecx
mov ecx, esi
cmp ax, word [esp + 0x4c]
jne 0x406598
cmp byte [0x4dd666], 0
je 0x406598
cmp bl, 9
je 0x406598
mov eax, dword [esp + 0x1c]
and dl, 0xf3
cmp eax, dword [0x4dbeb0]
jne 0x40651d
test dh, dh
je 0x40651d
mov eax, dword [0x4dd66c]
movzx ecx, dl
shl ecx, 9
add ecx, dword [esp + 0x34]
jmp 0x40652a
mov eax, dword [0x4dd668]
movzx ecx, dl
shl ecx, 8
add ecx, ebp
movzx eax, word [eax + ecx*2]
mov esi, 0x7ff9
movzx edx, ax
movzx ecx, ax
and eax, 0x7fff
mov dword [esp + 0x2c], edx
mov dword [esp + 0x30], edx
lea ebp, [esi + 6]
cmp ax, si
jbe 0x406553
cmp ax, bp
jb 0x4065a1
mov ecx, dword [esp + 0x138]
test cl, cl
je 0x4065c2
cmp byte [edi + 8], 0
jne 0x405a75
test byte [edi + 0xc], 1
jne 0x405a75
cmp byte [edi + 9], 0
je 0x405a75
cmp byte [esp + 0x22], 0
jne 0x405a75
push 0
push SysReAllocString
push 0x7fff
jmp 0x406dac
mov edx, dword [esp + 0x2c]
mov ebp, 0x7fff
movzx eax, cx
mov ecx, dword [esp + 0x138]
test ax, ax
jns 0x406604
test cl, cl
jne 0x4066f0
cmp word [edi + 4], bp
jne 0x4065c2
mov word [edi + 4], dx
cmp word [edi + 4], bp
lea ecx, [edi + 4]
je 0x4065f4
push 0
lea eax, [esp + 0x16]
mov dl, 1
push eax
lea eax, [edi + 0xc]
push eax
call fcn.0040a7e0
mov cl, byte [esp + 0x1e]
add esp, 0xc
test cl, cl
sete al
mov byte [edi + 0x11], al
test cl, cl
je 0x40689c
push 0x7fff
push dword [esp + 0x18]
push 0
jmp 0x40597c
cmp ax, bp
je 0x40655a
and eax, 0x7fff
test cl, cl
je 0x4066fe
cmp ax, word [0x4dbffc]
jae 0x4066e5
mov esi, eax
mov eax, dword [0x4dd670]
cmp word [eax + esi*2], bp
je 0x4066e5
cmp byte [esp + 0x23], 0
jne 0x40666c
mov eax, dword [esp + 0x3c]
mov dl, cl
push eax
lea eax, [esp + 0x16]
push eax
lea eax, [edi + 0xc]
push eax
lea ecx, [esp + 0x3c]
call fcn.0040a7e0
mov edx, eax
add esp, 0xc
test edx, edx
jne 0x40667b
mov ecx, dword [esp + 0x138]
mov dword [esp + 0x38], eax
mov eax, dword [0x4dd670]
movzx edx, word [eax + esi*2]
mov dword [esp + 0x30], edx
jmp 0x4066f4
mov ebp, dword [esp + 0x13c]
lea eax, [ebp + 0x3c2c17]
cmp eax, 0x66
ja 0x4066cd
movzx ecx, byte [edx + 0x1c]
mov eax, 0xffc3d44d
sub eax, ebp
cmp eax, ecx
jg 0x4066cd
mov eax, dword [esp + 0x3c]
test eax, eax
je 0x4066ac
mov ecx, 0x69
mov word [eax], cx
mov ecx, dword [esp + 0x138]
xor eax, eax
mov dword [esp + 0x38], eax
mov ebp, 0x7fff
mov eax, dword [0x4dd670]
movzx edx, word [eax + esi*2]
mov dword [esp + 0x30], edx
jmp 0x4066f4
mov ecx, dword [esp + 0x138]
xor eax, eax
mov dword [esp + 0x38], edx
mov ebp, 0x7fff
mov edx, dword [esp + 0x30]
jmp 0x4066f4
cmp byte [esp + 0x23], 0
jne 0x40655e
mov edx, dword [esp + 0x2c]
cmp dx, bp
jne 0x406730
jmp 0x40655a
mov edx, dword [esp + 0x2c]
cmp ax, word [0x4dbffc]
jae 0x4066f4
cmp word [edi + 4], bp
jne 0x4066f4
mov ecx, eax
mov eax, dword [0x4dd670]
mov ax, word [eax + ecx*2]
mov ecx, dword [esp + 0x138]
mov word [edi + 4], ax
jmp 0x4066f4
mov ecx, dword [esp + 0x138]
mov al, byte [edi + 0xc]
lea esi, [edi + 0xc]
test al, 8
je 0x406747
test cl, cl
je 0x406747
and al, 0xf7
mov byte [esp + 0x12], 1
mov byte [esi], al
mov ebp, dword [esp + 0x38]
mov eax, edx
and eax, 0x7fff
cmp ax, word [0x4dbffc]
jae 0x4067c3
test ebp, ebp
jne 0x4067c3
push dword [esp + 0x3c]
lea eax, [esp + 0x16]
mov dl, cl
push eax
push esi
lea ecx, [esp + 0x3c]
call fcn.0040a7e0
mov edx, eax
add esp, 0xc
test edx, edx
je 0x40683a
mov ebp, dword [esp + 0x13c]
lea ecx, [ebp + 0x3c2c17]
cmp ecx, 0x66
ja 0x4067bb
movzx ecx, byte [edx + 0x1c]
mov eax, 0xffc3d44d
sub eax, ebp
cmp eax, ecx
jg 0x4067bb
mov eax, dword [esp + 0x3c]
test eax, eax
je 0x40683e
mov ecx, 0x69
mov word [eax], cx
jmp 0x40683e
xor ebp, ebp
mov ebp, edx
mov edx, dword [esp + 0x30]
and edx, 0x7fff
test byte [0x4dbebd], 0xcc
mov dword [esp + 0x2c], edx
je 0x406909
cmp byte [esp + 0x12], 0
jne 0x406909
cmp byte [0x4dd665], 0
jne 0x4067fe
mov eax, dword [esp + 0x1c]
cmp eax, dword [0x4dbeac]
jne 0x406909
test byte [0x4dbebd], 0xc0
je 0x4068b3
cmp dx, word [0x4dbffc]
jae 0x4068b3
mov eax, dword [0x4dbfec]
movzx ecx, dx
mov eax, dword [eax + ecx*4]
mov al, byte [eax + 0xf]
and al, 0xc0
je 0x4068b3
mov byte [0x4dd664], 1
jmp 0x406909
mov eax, dword [esp + 0x3c]
cmp word [eax], 0x69
je 0x406227
mov eax, dword [esp + 0x138]
test al, al
je 0x406862
cmp byte [edi + 0x11], 0
je 0x405972
jmp 0x406457
lea ecx, [edi + 4]
mov eax, 0x7fff
cmp word [ecx], ax
je 0x4065f4
push 0
lea eax, [esp + 0x16]
mov byte [esp + 0x16], 0
push eax
push esi
mov dl, 1
call fcn.0040a7e0
add esp, 0xc
cmp byte [esp + 0x12], 0
jne 0x4065f4
and byte [esi], 0xf7
mov byte [edi + 0x11], 1
push 0
push SysReAllocString
push 0x7fff
push dword [esp + 0x20]
push 0
jmp 0x406db1
cmp byte [0x4dd664], 0
jne 0x406909
mov al, byte [0x4dbebd]
test al, 0xc
je 0x406909
test al, 3
jne 0x406909
cmp dx, word [0x4dbffc]
jae 0x406909
mov eax, dword [0x4dbfec]
movzx ecx, dx
mov eax, dword [eax + ecx*4]
mov al, byte [eax + 0xf]
and al, 0xc
je 0x406909
cmp dword [0x4dbeb0], 0
je 0x4068f6
mov byte [0x4dd664], 1
jmp 0x406909
mov edx, 0xffc3d44d
mov ecx, 2
call fcn.004108c0
mov edx, dword [esp + 0x2c]
movzx ecx, dx
lea eax, [ecx - 0x7ffa]
cmp eax, 4
ja case.default.0x40691b
jmp dword [eax*4 + 0x406dfc]
cmp byte [0x4dd666], 0
je 0x406227
xor al, al
test byte [0x4dbebd], 4
je 0x406941
mov edx, 0xa4
jmp 0x406953
test byte [0x4dbebd], 8
movzx edx, al
mov eax, 0xa5
cmovne edx, eax
cmp byte [0x4dd666], 0
mov dword [esp + 0x40], edx
je 0x4069e2
mov ebp, dword [esp + 0x2c]
mov eax, 0x7ffb
cmp bp, ax
je 0x406b6d
test dl, dl
movzx eax, dl
push 0xffc3d44d
mov ecx, 0x12
cmovne ecx, eax
push 0
push 0
mov dl, cl
mov ecx, 1
push 0
call fcn.004103a0
add esp, 0x10
cmp byte [edi + 8], 0
je 0x4069d1
cmp bl, 0x5b
je 0x4069d1
cmp bl, 0x5c
je 0x4069d1
cmp byte [esp + 0x138], 0
jne 0x4069d1
push 0xffc3d44d
push 0
push 0
push 0
mov dl, bl
mov ecx, 1
call fcn.004103a0
add esp, 0x10
mov byte [0x4dd666], 0
mov edx, 0x7fff
jmp 0x406c87
cmp bl, 0xa4
je 0x4069f1
mov byte [esp + 0x23], 0
cmp bl, 0xa5
jne 0x4069f6
mov byte [esp + 0x23], 1
cmp bl, 0xa0
je 0x406a04
cmp bl, 0xa1
je 0x406a04
xor cl, cl
jmp 0x406a06
mov cl, 1
mov byte [esp + 0x1b], cl
cmp bl, 0xa2
je 0x406a19
mov byte [esp + 0x13], 0
cmp bl, 0xa3
jne 0x406a1e
mov byte [esp + 0x13], 1
xor dl, dl
test byte [0x4dbebd], 0x10
mov dword [esp + 0x38], edx
je 0x406a31
mov dl, 0xa0
jmp 0x406a54
test byte [0x4dbebd], 0x20
mov eax, dword [esp + 0x138]
je 0x406a45
mov dl, 0xa1
jmp 0x406a5b
test al, al
jne 0x406a5f
test cl, cl
movzx edx, dl
movzx eax, bl
cmovne edx, eax
mov eax, dword [esp + 0x138]
mov dword [esp + 0x38], edx
xor cl, cl
test byte [0x4dbebd], 1
mov dword [esp + 0x34], ecx
je 0x406a75
mov byte [esp + 0x34], 0xa2
jmp 0x406a9b
test byte [0x4dbebd], 2
je 0x406a85
mov byte [esp + 0x34], 0xa3
jmp 0x406a9b
test al, al
jne 0x406a9b
cmp byte [esp + 0x13], 0
movzx ecx, cl
movzx eax, bl
cmovne ecx, eax
mov dword [esp + 0x34], ecx
mov byte [esp + 0x13], 0
test dl, dl
je 0x406ac1
push 0xffc3d44d
push 0
push 0
push 0
mov ecx, 1
call fcn.004103a0
add esp, 0x10
mov byte [esp + 0x13], 1
mov eax, dword [esp + 0x34]
test al, al
je 0x406ae3
push 0xffc3d44d
push 0
push 0
push 0
mov dl, al
mov ecx, 1
call fcn.004103a0
add esp, 0x10
cmp byte [esp + 0x23], 0
je 0x406af8
cmp byte [esp + 0x138], 0
jne 0x406b00
mov al, bl
jmp 0x406afc
mov eax, dword [esp + 0x40]
test al, al
jne 0x406b17
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 0x12
xor ecx, ecx
call fcn.004103a0
add esp, 0x10
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 9
mov ecx, 2
call fcn.004103a0
add esp, 0x10
cmp byte [esp + 0x13], 0
je 0x406b58
cmp byte [esp + 0x1b], 0
jne 0x406b58
mov dl, byte [esp + 0x38]
xor ecx, ecx
push 0xffc3d44d
push 0
push 0
push 0
call fcn.004103a0
add esp, 0x10
mov byte [0x4dd666], 1
mov edx, 0x7fff
jmp 0x406c87
mov ebp, dword [esp + 0x2c]
cmp byte [0x4dd666], 0
je 0x406227
mov eax, dword [esp + 0x138]
test al, al
jne 0x406bba
cmp bl, 0xa2
je 0x406b99
cmp bl, 0xa3
je 0x406b99
cmp bl, 0xa0
je 0x406b99
cmp bl, 0xa1
jne 0x406bba
push 0xffc3d44d
push 0
push 0
push 0
mov dl, bl
mov ecx, 1
call fcn.004103a0
mov eax, dword [esp + 0x148]
add esp, 0x10
test byte [0x4dbebd], 0xc
je 0x406bd1
test al, al
je 0x406be8
cmp bl, 0xa4
je 0x406bd1
cmp bl, 0xa5
jne 0x406be8
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 0x12
xor ecx, ecx
call fcn.004103a0
add esp, 0x10
mov eax, 0x7ffd
cmp bp, ax
jne 0x406c47
test byte [0x4dbebd], 0x30
jne 0x406c47
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 0x10
xor ecx, ecx
call fcn.004103a0
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 9
mov ecx, 2
call fcn.004103a0
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 0x10
mov ecx, 1
call fcn.004103a0
add esp, 0x30
mov edx, 0x7fff
jmp 0x406c87
push 0xffc3d44d
push 0
push 0
push 0
mov dl, 9
mov ecx, 2
call fcn.004103a0
add esp, 0x10
mov edx, 0x7fff
jmp 0x406c87
mov eax, dword [ebp + 8]
mov edx, ecx
mov dword [esp + 0x44], edx
test eax, eax
je 0x406c87
cmp byte [eax], 5
jne 0x406c87
movzx eax, word [ebp + 0x18]
shl eax, 0x10
or edx, eax
mov dword [esp + 0x44], edx
mov eax, dword [esp + 0x3c]
mov ecx, 0x68
mov word [eax], cx
mov ecx, dword [esp + 0x138]
test cl, cl
je 0x406d3f
cmp byte [esp + 0x22], 0
je 0x406cfe
cmp byte [edi + 9], 0
je 0x406cfe
mov ebp, dword [esp + 0x24]
mov dl, bl
push 0xffc3d44e
push 0
push 0
push ebp
mov ecx, 1
call fcn.004103a0
push 0xffc3d44d
push 0
push 0
push ebp
mov dl, bl
mov ecx, 2
call fcn.004103a0
mov eax, dword [esp + 0x64]
add esp, 0x20
push 0
push SysReAllocString
push eax
push dword [esp + 0x20]
push dword [esp + 0x148]
jmp 0x406db1
cmp byte [edi + 8], 0
je 0x406d17
cmp byte [edi + 0x11], 0
je 0x406d60
push 0
push SysReAllocString
push edx
jmp 0x406dac
cmp byte [esp + 0x12], 0
je 0x406da0
mov eax, dword [esp + 0x1c]
push edx
push dword [esp + 0x18]
push ecx
push dword [esp + 0x30]
mov ecx, eax
push ebx
push dword [esp + 0x140]
jmp 0x4056f6
mov eax, dword [0x4dbfcc]
mov byte [edi + 0x10], 1
test eax, eax
je 0x406d56
cmp byte [eax + 8], 0
je 0x406d56
mov byte [eax + 0x12], 2
cmp byte [esp + 0x12], 0
je 0x406d6b
or byte [esi], 8
push edx
push dword [esp + 0x18]
push ecx
jmp 0x40597c
cmp bl, 0xa4
je 0x406d75
cmp bl, 0xa5
jne 0x406d98
push 0xffc3d450
push 0
push 0
push dword [esp + 0x30]
mov dl, bl
mov ecx, 1
call fcn.004103a0
mov ecx, dword [esp + 0x148]
add esp, 0x10
test cl, cl
jne 0x406da0
mov byte [edi + 0x11], 1
mov eax, dword [esp + 0x44]
push 0
push SysReAllocString
push eax
push dword [esp + 0x20]
push ecx
push ecx
mov ecx, dword [esp + 0x34]
push ebx
mov edx, dword [esp + 0x148]
call fcn.00406e10
add esp, 0x1c
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x114
ret