Function at 0x40b58d
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x572479
mov eax, dword fs:[0]
push eax
sub esp, 0x6c
push ebx
push esi
mov eax, dword [0x67d978]
xor eax, esp
push eax
lea eax, [esp + 0x78]
mov dword fs:[0], eax
lea eax, [esp + 0x2c]
push eax
push edi
call fcn.0040ca85
and dword [esp + 0x80], 0
push eax
call fcn.004151cf
mov ebx, eax
pop ecx
mov dword [esp + 0x28], ebx
or dword [esp + 0x80], 0xffffffff
lea ecx, [esp + 0x2c]
call fcn.00415838
mov eax, dword [ebx]
push 0x25
mov ecx, ebx
call dword [eax + 0x28]
or dword [esp + 0x18], 0xffffffff
movzx esi, ax
mov al, byte [edi + 0x50]
mov byte [esp + 0x24], al
push dword [esp + 0x24]
mov byte [esp + 0x11], 1
push ebx
push esi
push dword [ebp + 8]
call fcn.0040ccac
add esp, 0x10
push eax
mov ecx, edi
call fcn.0040cb8a
mov ecx, dword [ebp + 8]
xor eax, eax
mov dword [esp + 0x1c], eax
mov dword [esp + 0x14], eax
mov dword [esp + 0x38], eax
mov dword [esp + 0x3c], eax
mov byte [esp + 0xe], al
mov dword [esp + 0x10], eax
movzx eax, si
mov dword [esp + 0x24], eax
push 1
lea eax, [esp + 0x28]
push eax
xor eax, eax
call fcn.0040b38c
mov ebx, eax
cmp ebx, 0xffffffff
je 0x40b81b
movzx eax, si
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x10]
test eax, eax
jne 0x40b670
lea esi, [edi + 0x34]
jmp 0x40b67e
dec eax
push eax
mov esi, edi
call fcn.0040c0a6
mov esi, eax
add esi, 0x20
mov ecx, dword [ebp + 8]
lea eax, [ebx + 1]
push eax
mov dword [esp + 0x24], eax
call fcn.0040ff53
mov ecx, dword [ebp + 8]
push ebx
mov dword [esp + 0x34], eax
call fcn.0040ff53
mov ecx, dword [esp + 0x30]
mov cx, word [ecx]
cmp cx, word [eax]
jne 0x40b6c6
push dword [esp + 0x20]
push dword [esp + 0x18]
push dword [ebp + 8]
push esi
call fcn.0040cdc5
add esp, 0x10
inc ebx
inc ebx
mov dword [esp + 0x14], ebx
jmp 0x40b7f7
cmp ebx, dword [esp + 0x14]
je 0x40b6e1
push ebx
push dword [esp + 0x18]
push dword [ebp + 8]
push esi
call fcn.0040cdc5
add esp, 0x10
mov dword [esp + 0x14], ebx
push dword [esp + 0x20]
mov ecx, dword [ebp + 8]
lea eax, [esp + 0x44]
push eax
call fcn.004130be
lea esi, [esp + 0x4c]
call fcn.0040bfac
mov ecx, dword [eax]
mov dword [esp + 0x38], ecx
mov eax, dword [eax + 4]
mov dword [esp + 0x3c], eax
mov al, byte [edi + 0x50]
mov byte [esp + 0x34], al
push dword [esp + 0x34]
mov esi, edi
push dword [esp + 0x24]
push dword [esp + 0x30]
push dword [esp + 0x1c]
call fcn.0040c0a6
mov ecx, dword [ebp + 8]
push eax
lea eax, [esp + 0x60]
push eax
call fcn.0040ac39
push eax
lea eax, [esp + 0x4c]
push eax
call fcn.0040ce40
mov ecx, dword [ebp + 8]
mov byte [esp + 0x27], al
add esp, 0x18
lea eax, [esp + 0x58]
push eax
call fcn.004130be
push eax
lea ecx, [esp + 0x3c]
call fcn.00412129
cmp byte [esp + 0xf], 0
mov ebx, eax
je 0x40b7f7
push dword [esp + 0x10]
mov dword [esp + 0x18], ebx
call fcn.0040c0a6
mov ecx, dword [eax + 0x60]
test cl, 1
je 0x40b7a7
mov edx, dword [eax + 0x48]
test dl, 0x40
je 0x40b78c
and ecx, 0xfffffffe
jmp 0x40b7a4
and edx, 0xffffff3f
and ecx, 0xfffffffd
or edx, 0x100
mov word [eax + 0x44], 0x30
mov dword [eax + 0x48], edx
mov dword [eax + 0x60], ecx
mov ecx, dword [eax + 0x60]
test cl, 2
je 0x40b7bb
test byte [eax + 0x48], 0x20
je 0x40b7bb
and ecx, 0xfffffffd
mov dword [eax + 0x60], ecx
push dword [esp + 0x10]
mov esi, edi
call fcn.0040c0a6
mov eax, dword [eax]
cmp eax, 0xfffffffd
je 0x40b7f7
cmp eax, 0xffffffff
jne 0x40b7d9
mov byte [esp + 0xd], 0
jmp 0x40b7ef
cmp eax, 0xfffffffe
jne 0x40b7e5
mov byte [esp + 0xe], 1
jmp 0x40b7ef
cmp eax, dword [esp + 0x18]
jle 0x40b7ef
mov dword [esp + 0x18], eax
inc dword [esp + 0x1c]
inc dword [esp + 0x10]
mov ecx, dword [ebp + 8]
push 1
lea eax, [esp + 0x28]
push eax
mov eax, ebx
call fcn.0040b38c
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x40b663
mov eax, dword [esp + 0x10]
test eax, eax
jne 0x40b820
lea eax, [edi + 0x34]
jmp 0x40b82c
dec eax
push eax
mov esi, edi
call fcn.0040c0a6
add eax, 0x20
mov ecx, dword [ebp + 8]
push dword [ecx + 0x14]
push dword [esp + 0x18]
push ecx
push eax
call fcn.0040cdc5
add esp, 0x10
cmp byte [esp + 0xd], 0
jne 0x40b8ac
xor ebx, ebx
cmp dword [esp + 0x18], ebx
jl 0x40b875
test byte [edi + 0x50], 1
je 0x40b875
push ebx
push dword [esp + 0x1c]
lea eax, [esp + 0x68]
push eax
call fcn.004120b2
mov dword [esp + 0x80], 1
push eax
call fcn.004120f1
cmp dword [esp + 0x1c], ebx
mov dword [esp + 0x14], ebx
jle 0x40b8a9
push dword [esp + 0x14]
mov esi, edi
call fcn.0040c0a6
cmp dword [eax], 0xffffffff
jne 0x40b89b
push dword [esp + 0x14]
call fcn.0040c0a6
mov dword [eax], ebx
inc ebx
inc dword [esp + 0x14]
mov eax, dword [esp + 0x14]
cmp eax, dword [esp + 0x1c]
jl 0x40b87f
dec ebx
jmp 0x40b8b0
mov ebx, dword [esp + 0x18]
mov ecx, dword [esp + 0x28]
mov eax, dword [ecx]
push 0x20
call dword [eax + 0x28]
sub esp, 0x64
movzx eax, ax
mov ecx, esp
mov dword [esp + 0x98], esp
push eax
push ecx
call fcn.0040c0f4
mov dword [esp + 0xe4], 2
or dword [esp + 0xe4], 0xffffffff
mov ecx, dword [esp + 0x80]
mov edx, edi
call fcn.0040c008
cmp byte [esp + 0xe], 0
je 0x40b8fd
or dword [edi + 0x24], 4
inc ebx
cmp byte [esp + 0xd], 0
mov dword [edi + 0x2c], ebx
je 0x40b90e
or dword [edi + 0x24], 1
jmp 0x40b912
and dword [edi + 0x24], 0xfffffffe
mov eax, edi
mov ecx, dword [esp + 0x78]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4