Function at 0x408c40
Capabilities:
Access peb ldr_data
Check for peb beingdebugged flag

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x593733
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0xf0
mov eax, dword [0x5de00c]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0xd8], ecx
mov dword [ebp - 0xc4], ecx
mov edx, dword [ebx + 8]
xorps xmm0, xmm0
mov dword [ebp - 0xe8], ecx
xor eax, eax
movups xmmword [ecx], xmm0
mov dword [ecx + 0x10], 0
mov dword [ecx + 0x14], 0
mov dword [ecx + 0x10], 0
mov dword [ecx + 0x14], 7
mov dword [ebp - 0xd4], 0
mov word [ecx], ax
lea edi, [ecx + 0x18]
mov dword [ebp - 4], eax
mov dword [edi], eax
mov dword [edi + 4], eax
mov dword [edi + 8], eax
mov dword [ecx + 0x24], eax
mov dword [ecx + 0x28], eax
mov dword [ecx + 0x2c], eax
mov dword [ecx + 0x30], eax
mov dword [ecx + 0x34], eax
mov dword [ecx + 0x38], eax
mov dword [ecx + 0x3c], eax
mov dword [ecx + 0x40], eax
mov dword [ecx + 0x44], eax
mov dword [ecx + 0x48], eax
mov dword [ecx + 0x4c], eax
mov dword [ecx + 0x50], eax
mov byte [ebp - 4], 5
mov dword [ecx + 0x54], eax
mov dword [ecx + 0x58], eax
mov word [ecx + 0x5c], ax
mov word [ecx + 0x60], ax
mov dword [ecx + 0x64], eax
mov ax, word [ebx + 0xc]
mov word [ecx + 0x5e], ax
mov ecx, edx
movups xmmword [ebp - 0x2c], xmm0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0
lea esi, [ecx + 2]
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x408d30
sub ecx, esi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x2c]
call fcn.00403d10
mov byte [ebp - 4], 6
mov esi, dword [ebp - 0x1c]
cmp dword [ebp - 0x18], 8
lea ecx, [ebp - 0x2c]
push 1
cmovae ecx, dword [ebp - 0x2c]
mov edx, esi
push str.:__n__
push 0
setae byte [ebp - 0xbd]
call fcn.0040b5f0
add esp, 0xc
mov dword [ebp - 0xe0], eax
cmp eax, 0xffffffff
je 0x409315
cmp byte [ebp - 0xbd], 0
lea ecx, [ebp - 0x2c]
push 1
push 0x5aab90
mov dword [ebp - 0xdc], 0
mov edx, esi
push 0
je 0x408db2
mov ecx, dword [ebp - 0x2c]
call fcn.0040b5f0
mov ecx, dword [ebp - 0x2c]
jmp 0x408dba
call fcn.0040b5f0
lea ecx, [ebp - 0x2c]
add esp, 0xc
mov dword [ebp - 0xd0], eax
mov edx, esi
push 1
push 0x5aab94
push 0
call fcn.0040b5f0
add esp, 0xc
mov dword [ebp - 0xcc], eax
cmp eax, 0xffffffff
jne 0x408e12
cmp byte [ebp - 0xbd], 0
lea ecx, [ebp - 0x2c]
push 1
cmovne ecx, dword [ebp - 0x2c]
mov edx, esi
push 0x5aab98
push 0
call fcn.0040b5f0
add esp, 0xc
mov dword [ebp - 0xcc], eax
mov dword [ebp - 0xdc], 1
mov ecx, dword [ebp - 0xd0]
cmp ecx, 0xffffffff
je 0x409315
cmp eax, 0xffffffff
je 0x409315
cmp ecx, eax
jbe 0x408d50
mov edx, dword [ebp - 0xe0]
cmp eax, edx
jbe 0x408d50
lea ecx, [edx + 1]
mov dword [ebp - 0x34], 0
mov dword [ebp - 0xc4], ecx
xorps xmm0, xmm0
mov dword [ebp - 0x30], 0
movups xmmword [ebp - 0x44], xmm0
cmp esi, ecx
jb 0x4094af
mov ecx, eax
lea eax, [ebp - 0x2c]
sub ecx, edx
mov edx, dword [ebp - 0xc4]
dec ecx
sub esi, edx
cmp esi, ecx
cmovb ecx, esi
cmp byte [ebp - 0xbd], 0
push ecx
cmovne eax, dword [ebp - 0x2c]
lea ecx, [ebp - 0x44]
lea eax, [eax + edx*2]
push eax
call fcn.00403d10
mov eax, dword [ebp - 0xd4]
or eax, 0x20
mov dword [ebp - 0xd4], eax
mov eax, dword [ebp - 0xcc]
xorps xmm0, xmm0
mov byte [ebp - 4], 7
mov edx, dword [ebp - 0x1c]
movups xmmword [ebp - 0x8c], xmm0
lea ecx, [eax + 1]
mov dword [ebp - 0x7c], 0
mov dword [ebp - 0xcc], ecx
mov dword [ebp - 0x78], 0
cmp edx, ecx
jb 0x4094af
mov esi, dword [ebp - 0xd0]
mov ecx, esi
sub edx, dword [ebp - 0xcc]
sub ecx, eax
dec ecx
lea eax, [ebp - 0x2c]
cmp edx, ecx
cmovb ecx, edx
cmp dword [ebp - 0x18], 8
mov edx, dword [ebp - 0xcc]
cmovae eax, dword [ebp - 0x2c]
push ecx
lea ecx, [ebp - 0x8c]
lea eax, [eax + edx*2]
push eax
call fcn.00403d10
mov byte [ebp - 4], 8
xorps xmm0, xmm0
mov eax, dword [ebp - 0x1c]
mov ecx, eax
sub ecx, esi
mov dword [ebp - 0x94], 0
inc esi
mov dword [ebp - 0x90], 0
dec ecx
movups xmmword [ebp - 0xa4], xmm0
cmp eax, esi
jb 0x4094af
sub eax, esi
cmp eax, ecx
cmovb ecx, eax
cmp dword [ebp - 0x18], 8
lea eax, [ebp - 0x2c]
cmovae eax, dword [ebp - 0x2c]
push ecx
lea ecx, [ebp - 0xa4]
lea eax, [eax + esi*2]
push eax
call fcn.00403d10
mov edx, dword [ebp - 0xe0]
mov byte [ebp - 4], 9
mov esi, dword [ebp - 0x1c]
mov eax, esi
sub eax, edx
mov dword [ebp - 0xcc], eax
cmp esi, edx
jb 0x4094af
cmp dword [ebp - 0x18], 8
lea eax, [ebp - 0x2c]
cmovae eax, dword [ebp - 0x2c]
sub esi, dword [ebp - 0xcc]
lea ecx, [eax + edx*2]
mov eax, esi
sub eax, edx
lea eax, [eax*2 + 2]
push eax
mov eax, dword [ebp - 0xcc]
lea eax, [ecx + eax*2]
push eax
push ecx
call sub.VCRUNTIME140.dll_memmove
mov edx, dword [ebp - 0x34]
mov eax, SysReAllocString
sub eax, esi
mov dword [ebp - 0x1c], esi
add esp, 0xc
cmp eax, edx
jb 0x4094aa
cmp dword [ebp - 0x18], 8
lea ecx, [ebp - 0x2c]
push edx
cmovae ecx, dword [ebp - 0x2c]
lea eax, [ebp - 0x44]
cmp dword [ebp - 0x30], 8
cmovae eax, dword [ebp - 0x44]
push eax
push esi
push ecx
push ecx
push dword [ebp - 0xe8]
lea ecx, [ebp - 0xbc]
call fcn.00403e90
mov byte [ebp - 4], 0xa
lea eax, [ebp - 0xa4]
cmp dword [ebp - 0x90], 8
lea ecx, [ebp - 0xbc]
push dword [ebp - 0x94]
cmovae eax, dword [ebp - 0xa4]
push eax
call fcn.004083e0
mov esi, dword [ebp - 0xd4]
xor ecx, ecx
or esi, 0x1e
mov dword [ebp - 0xd4], esi
movups xmm0, xmmword [eax]
movq xmm1, qword [eax + 0x10]
mov dword [eax + 0x10], 0
mov dword [eax + 0x14], 7
mov word [eax], cx
mov ecx, dword [ebp - 0x18]
movq qword [ebp - 0xc8], xmm1
movq qword [ebp - 0x4c], xmm1
movups xmmword [ebp - 0x100], xmm0
movups xmmword [ebp - 0x5c], xmm0
cmp ecx, 8
jb 0x4090ac
mov edx, dword [ebp - 0x2c]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x409093
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40930f
push ecx
push edx
call fcn.0052d747
movups xmm0, xmmword [ebp - 0x100]
add esp, 8
movq xmm1, qword [ebp - 0xc8]
xor eax, eax
movq qword [ebp - 0x1c], xmm1
lea ecx, [ebp - 0x5c]
mov dword [ebp - 0x4c], 0
movups xmmword [ebp - 0x2c], xmm0
mov dword [ebp - 0x48], 7
mov word [ebp - 0x5c], ax
call fcn.00403990
lea ecx, [ebp - 0xbc]
mov byte [ebp - 4], 9
call fcn.00403990
cmp dword [ebp - 0xdc], 0
jne 0x40915b
push 0x20
call fcn.0052d778
mov edx, eax
add esp, 4
mov dword [ebp - 0xec], edx
mov byte [ebp - 4], 0xb
lea ecx, [ebp - 0x44]
cmp dword [ebp - 0x30], 8
lea eax, [ebp - 0x8c]
cmovae ecx, dword [ebp - 0x44]
cmp dword [ebp - 0x78], 8
push ecx
push dword [ebp - 0xe0]
cmovae eax, dword [ebp - 0x8c]
mov ecx, edx
push eax
call fcn.004dd5e0
mov byte [ebp - 4], 9
mov ecx, dword [edi + 4]
mov dword [ebp - 0xc4], eax
cmp ecx, dword [edi + 8]
je 0x409147
mov dword [ecx], eax
add dword [edi + 4], 4
jmp 0x4092e8
lea eax, [ebp - 0xc4]
push eax
push ecx
mov ecx, edi
call fcn.0040b6b0
jmp 0x4092e8
xor ecx, ecx
mov dword [ebp - 0xd0], ecx
cmp dword [ebp - 0x34], ecx
jbe 0x4092e8
cmp dword [ebp - 0x30], 8
setae dl
mov byte [ebp - 0xbd], dl
nop dword [eax]
xorps xmm0, xmm0
mov dword [ebp - 0x64], 0
xor eax, eax
mov dword [ebp - 0x60], 7
movups xmmword [ebp - 0x74], xmm0
mov word [ebp - 0x74], ax
mov byte [ebp - 4], 0xc
lea eax, [ebp - 0x44]
test dl, dl
push 1
cmovne eax, dword [ebp - 0x44]
movzx eax, word [eax + ecx*2]
mov dword [ebp - 0xc4], eax
lea eax, [ebp - 0xc4]
push eax
push 0
lea eax, [ebp - 0x74]
push eax
push ecx
push dword [ebp - 0xec]
lea ecx, [ebp - 0x5c]
call fcn.00403e90
or esi, 1
lea ecx, [ebp - 0x74]
mov dword [ebp - 0xd4], esi
call fcn.00403990
movups xmm0, xmmword [ebp - 0x5c]
xor eax, eax
lea ecx, [ebp - 0x5c]
mov word [ebp - 0x5c], ax
movups xmmword [ebp - 0x100], xmm0
movups xmmword [ebp - 0x74], xmm0
movq xmm0, qword [ebp - 0x4c]
movq qword [ebp - 0x64], xmm0
mov dword [ebp - 0x4c], 0
mov dword [ebp - 0x48], 7
call fcn.00403990
push 0x20
call fcn.0052d778
mov esi, eax
add esp, 4
mov dword [ebp - 0xe4], esi
mov eax, dword [ebp - 0xd0]
lea edx, [ebp - 0x74]
mov byte [ebp - 4], 0xd
lea ecx, [ebp - 0x8c]
cmp dword [ebp - 0x60], 8
cmovae edx, dword [ebp - 0x100]
cmp dword [ebp - 0x78], 8
push edx
cmovae ecx, dword [ebp - 0x8c]
add eax, dword [ebp - 0xe0]
push eax
push ecx
mov ecx, esi
call fcn.004dd5e0
mov byte [ebp - 4], 0xc
mov ecx, eax
mov eax, dword [edi + 4]
mov dword [ebp - 0xc4], ecx
cmp eax, dword [edi + 8]
je 0x40927d
mov dword [eax], ecx
add dword [edi + 4], 4
jmp 0x40928c
lea ecx, [ebp - 0xc4]
push ecx
push eax
mov ecx, edi
call fcn.0040b6b0
mov byte [ebp - 4], 9
mov edx, dword [ebp - 0x60]
cmp edx, 8
jb 0x4092c6
mov eax, dword [ebp - 0x74]
lea edx, [edx*2 + 2]
mov ecx, eax
cmp edx, 0x1000
jb 0x4092bc
mov eax, dword [ecx - 4]
add edx, 0x23
sub ecx, eax
add ecx, 0xfffffffc
cmp ecx, 0x1f
ja 0x40930f
push edx
push eax
call fcn.0052d747
add esp, 8
mov ecx, dword [ebp - 0xd0]
mov esi, dword [ebp - 0xd4]
inc ecx
mov dl, byte [ebp - 0xbd]
mov dword [ebp - 0xd0], ecx
cmp ecx, dword [ebp - 0x34]
jb 0x409180
lea ecx, [ebp - 0xa4]
call fcn.00403990
lea ecx, [ebp - 0x8c]
call fcn.00403990
lea ecx, [ebp - 0x44]
mov byte [ebp - 4], 6
call fcn.00403990
jmp 0x408d4d
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
mov esi, dword [ebp - 0xd8]
lea eax, [ebp - 0x2c]
push eax
mov ecx, esi
call fcn.00409840
test byte [esi + 0x64], 4
je 0x4093df
mov eax, dword [esi + 0x34]
lea edi, [esi + 0x30]
sub eax, dword [edi]
xor esi, esi
sar eax, 2
mov dword [ebp - 0xc4], eax
test eax, eax
je 0x409384
nop word [eax + eax]
mov eax, dword [edi]
lea ecx, [esi*4]
mov eax, dword [eax + ecx]
test eax, eax
je 0x40937b
push 0xc
push eax
call fcn.0052d747
mov eax, dword [edi]
lea ecx, [esi*4]
add esp, 8
mov dword [eax + ecx], 0
inc esi
cmp esi, dword [ebp - 0xc4]
jb 0x409350
mov esi, dword [ebp - 0x1c]
test esi, esi
je 0x40939a
mov eax, dword [ebx + 0x10]
xor edx, edx
div esi
mov dword [ebp - 0xdc], eax
jmp 0x4093a4
mov dword [ebp - 0xdc], 0
push 0xc
call fcn.0052d778
mov ecx, dword [ebp - 0xdc]
mov dword [ebp - 0xe4], eax
mov dword [eax], ecx
mov dword [eax + 8], esi
add esp, 4
mov dword [eax + 4], 0
mov ecx, dword [edi + 4]
mov dword [ebp - 0xc4], eax
cmp ecx, dword [edi + 8]
je 0x40944f
mov dword [ecx], eax
add dword [edi + 4], 4
jmp 0x40945e
cmp dword [ebx + 0x14], 0
je 0x409464
mov eax, dword [esi + 0x34]
lea edi, [esi + 0x30]
sub eax, dword [edi]
xor esi, esi
sar eax, 2
mov dword [ebp - 0xc4], eax
test eax, eax
je 0x409434
mov eax, dword [edi]
lea ecx, [esi*4]
mov eax, dword [eax + ecx]
test eax, eax
je 0x40942b
push 0xc
push eax
call fcn.0052d747
mov eax, dword [edi]
lea ecx, [esi*4]
add esp, 8
mov dword [eax + ecx], 0
inc esi
cmp esi, dword [ebp - 0xc4]
jb 0x409400
mov esi, dword [ebp - 0x1c]
push 0xc
call fcn.0052d778
mov dword [ebp - 0xe4], eax
mov dword [eax], 0
jmp 0x4093b9
lea eax, [ebp - 0xc4]
push eax
push ecx
mov ecx, edi
call fcn.0040b6b0
mov esi, dword [ebp - 0xd8]
lea eax, [ebp - 0x2c]
cmp esi, eax
je 0x409480
cmp dword [ebp - 0x18], 8
mov ecx, eax
push dword [ebp - 0x1c]
cmovae ecx, dword [ebp - 0x2c]
push ecx
mov ecx, esi
call fcn.004039f0
lea ecx, [ebp - 0x2c]
call fcn.00403990
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0052d3c5
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret 0x10
call fcn.00402990
call fcn.00405980
int3