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

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x2e4
mov esi, dword [esp + 0x2fc]
cmp byte [esp + 0x2f8], 0
mov ebx, edx
mov ebp, ecx
je 0x4061e4
lea eax, [esi + 0x48]
lea ecx, [esp + 0x1e4]
push pe_nt_image_headers32
push eax
push ecx
call fcn.005669c0
add esp, 0xc
jmp 0x4061f0
lea ecx, [esp + 0x1e4]
call fcn.0040d97b
mov dword [esp], ebx
test bl, bl
mov ebx, dword [esi + 8]
jne 0x406224
mov ecx, ebx
mov edx, 0x57e068
lea esi, [ebx + ebx]
not ecx
shr ecx, 0x1f
call fcn.004b8a02
xor ecx, ecx
cmp esi, 4
mov edx, 0x57e078
lea ebx, [ebx + ebx - 4]
setae cl
call fcn.004b8a02
movzx esi, byte [esp + 0x2e3]
bsr ecx, esi
xor eax, eax
mov dword [esp + 0x14], esi
dec eax
not ecx
shr eax, cl
lea edx, [eax + 1]
not eax
bsf ecx, edx
and eax, edx
xor edx, edx
inc edx
test esi, esi
cmove ecx, esi
mov esi, ebx
cmove eax, edx
mov dword [esp + 0x10], edx
mov edx, 0x57e088
mov dword [esp + 0x18], ecx
shl esi, cl
xor ecx, ecx
mov edi, esi
sub edi, eax
setae cl
call fcn.004b8a02
cmp edi, 0x7ffffffe
jbe 0x40629b
and dword [ebp + 8], 0
mov dword [ebp + 0xc], edi
and dword [ebp + 0x14], 0
mov dword [ebp + 0x10], 0x7ffffffe
and dword [ebp + 0x1c], 0
mov dword [ebp + 0x18], edi
mov dword [ebp], 1
jmp 0x406ba5
mov eax, dword [esp + 0x2fc]
mov dword [esp + 0xc], ebx
xor ecx, ecx
mov ebx, dword [eax + 0x154]
add ebx, 0xffffffff
setb cl
cmp byte [esp], 0
je 0x4062c1
mov edx, 0x57e0b8
jmp 0x4062d9
mov edx, 0x57e098
call fcn.004b8a02
mov ecx, ebx
add ebx, ebx
mov edx, 0x57e0a8
not ecx
shr ecx, 0x1f
call fcn.004b8a02
lea ecx, [esp + 0x70]
mov edx, esi
call fcn.004052c2
test ebx, ebx
mov dword [esp + 0x6c], ebp
je 0x406324
cmp ebx, 0xaaaaaaa
ja 0x406bb0
imul edi, ebx, 0xc
test edi, edi
js 0x406bb0
push 4
pop ecx
mov edx, edi
call fcn.004041e4
mov ebp, eax
test eax, eax
jne 0x406327
push 4
pop ecx
mov edx, edi
call fcn.00576700
ud2
push 4
pop ebp
xor esi, esi
mov dword [esp + 8], ebp
lea edi, [esi + 1]
cmp edi, ebx
jae 0x406364
lea ecx, [esp + 0x88]
push 4
pop edx
push 0
call fcn.004050df
pop eax
mov eax, dword [esp + 0x90]
inc esi
mov dword [ebp + 8], eax
movsd xmm0, qword [esp + 0x88]
movsd qword [ebp], xmm0
add ebp, 0xc
jmp 0x40632d
test ebx, ebx
je 0x406379
mov dword [ebp], 4
and dword [ebp + 4], 0
and dword [ebp + 8], 0
jmp 0x406385
push 4
pop ecx
xor edx, edx
call fcn.00421312
mov edi, esi
mov esi, dword [esp + 0x2fc]
lea ecx, [esp + 0x44]
mov edx, dword [esi + 0x30]
push dword [esi + 0x38]
call fcn.004050df
pop eax
mov eax, dword [esi + 0x3c]
test eax, eax
mov dword [esp + 0x20], eax
je 0x4063c7
lock inc dword [eax]
jle 0x406bb7
mov esi, dword [esp + 0x2fc]
mov eax, dword [esi + 0x40]
mov ecx, dword [esi + 0x44]
mov dword [esp + 0x40], eax
mov dword [esp + 0x68], ecx
jmp 0x4063ce
mov esi, dword [esp + 0x2fc]
mov al, byte [esi + 0x160]
inc dword [esp + 0x14]
lea ebp, [esp + 0xc8]
mov byte [esp + 0x1c], al
lea eax, [esp + 0x1e4]
push pe_nt_image_headers32
push eax
push ebp
call fcn.005669c0
add esp, 0xc
mov eax, dword [esp + 0x78]
and dword [ebp + 0x10c], 0
and dword [ebp + 0x108], 0
and dword [ebp + 0x114], 0
and dword [ebp + 0x110], 0
movsd xmm0, qword [esp + 0x70]
mov ecx, dword [esp + 0x18]
mov dword [ebp - 0x38], eax
mov eax, dword [esp + 8]
movsd qword [ebp - 0x40], xmm0
movsd xmm0, qword [esp + 0x44]
mov dword [ebp - 0x34], eax
mov eax, dword [esp + 0x4c]
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x2c], edi
lea edi, [esp + 0xa0]
and dword [ebp - 0x1c], 0
mov ebx, dword [esp + 0xc]
movsd qword [edi], xmm0
mov dword [edi + 8], eax
mov eax, dword [esp + 0x20]
mov dword [edi + 0x10], eax
mov eax, dword [esp + 0x40]
mov dword [edi + 0x14], eax
mov eax, dword [esp + 0x68]
mov dword [edi + 0x18], eax
mov al, byte [esp + 0x1c]
mov byte [edi + 0x140], al
mov eax, dword [esp + 0x14]
mov dword [edi + 0x1c], ebx
mov dword [edi + 0x20], eax
mov eax, dword [esi + 0x148]
mov dword [edi + 0x24], ecx
mov dword [edi + 0x128], eax
mov eax, dword [esi + 0x14c]
mov dword [edi + 0x12c], eax
mov eax, dword [esp]
cmp al, 2
je 0x4064b8
movzx eax, al
cmp eax, 1
lea eax, [esp + 0x88]
jne 0x4064d0
xor ecx, ecx
mov edx, esi
jmp 0x4064c4
xor ecx, ecx
mov edx, esi
lea eax, [esp + 0x88]
inc ecx
push eax
call fcn.0040dbf1
pop eax
jmp 0x406b22
mov edi, dword [esi]
mov ebp, esi
mov esi, dword [esi + 8]
mov ecx, dword [esp + 0x18]
shl dword [esp + 0x10], cl
lea ecx, [esp + 0x28]
mov edx, esi
call fcn.004052c2
lea ecx, [esp + 0x34]
mov edx, esi
call fcn.004052c2
mov ecx, ebx
call fcn.00405323
mov dword [esp + 8], eax
lea eax, [esp + 4]
imul ebx, esi, 0x14
mov ecx, esi
mov dword [esp + 0x40], edx
and dword [eax], 0
add ebx, edi
call fcn.0040770a
lea eax, [esp + 0x70]
mov edx, dword [ebp + 0x158]
mov ecx, dword [ebp + 0x15c]
mov dword [eax], edi
mov dword [eax + 4], ebx
and dword [eax + 8], 0
mov ebx, eax
mov dword [eax + 0xc], esi
mov dword [esp + 0x20], edx
mov dword [esp + 0x1c], ecx
mov ecx, ebx
call fcn.00407749
test edx, edx
je 0x406980
mov edi, eax
cmp eax, 2
jae 0x406593
mov esi, dword [esp + 4]
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x30]
push 0x57e208
push edi
call fcn.00408083
pop ecx
pop edx
mov dword [eax], esi
mov esi, dword [esp + 4]
mov ecx, dword [esp + 0x34]
mov edx, dword [esp + 0x3c]
push 0x57e218
push edi
call fcn.00408083
pop ecx
pop edx
mov ecx, dword [esp + 0x10]
mov dword [eax], esi
add dword [esp + 4], ecx
jmp 0x40653d
mov eax, dword [esp + 0x20]
mov esi, edx
cmp edi, eax
jne 0x4065d4
mov ebx, dword [esp + 4]
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x30]
push 0x57e1e8
push eax
mov ebp, eax
call fcn.00408083
pop ecx
pop edx
mov dword [eax], ebx
mov ecx, dword [esp + 0x34]
mov edx, dword [esp + 0x3c]
push 0x57e1f8
push ebp
call fcn.00408083
pop ecx
pop edx
and dword [eax], 0
jmp 0x406637
mov eax, dword [esp + 0x1c]
cmp edi, eax
jne 0x40677f
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x30]
push 0x57e1b8
push eax
mov ebp, eax
call fcn.00408083
pop ecx
pop edx
and dword [eax], 0
mov ebx, dword [esp + 4]
mov ecx, dword [esp + 0x34]
mov edx, dword [esp + 0x3c]
push 0x57e1c8
push ebp
call fcn.00408083
pop ecx
pop edx
mov dword [eax], ebx
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0xc]
mov eax, dword [esp + 4]
shr eax, cl
mov ecx, dword [esp + 8]
push 0x57e1d8
push eax
call fcn.0047936b
pop ecx
pop edx
mov byte [eax], 1
cmp dword [esi + 8], 0
mov ebp, dword [esp + 0x2fc]
je 0x406665
mov esi, dword [esp + 4]
mov ecx, ebp
mov edx, edi
call fcn.00407808
mov ebx, edx
lea ecx, [esp + 0x88]
mov edx, esi
push ebx
push eax
call fcn.0040daf2
pop eax
pop ecx
mov ecx, ebp
mov edx, edi
call fcn.004077aa
xor esi, esi
mov dword [esp + 0x58], eax
mov dword [esp + 0x5c], edx
mov dword [esp], 0
lea ecx, [esp + 0x44]
lea edx, [esp + 0x58]
call fcn.004077c7
cmp byte [esp + 0x44], 0
je 0x40671b
movzx edi, byte [esp + 0x45]
mov ebp, dword [esp + 0x46]
mov ecx, dword [esp]
mov edx, esi
cmp edx, edi
jae 0x4066e1
movzx eax, dl
inc edx
test cl, cl
mov cl, 1
mov bl, byte [esp + eax + 0xc8]
je 0x4066be
cmp bh, bl
je 0x4066a5
mov esi, edx
lea ecx, [esp + 0x88]
lea edx, [esp + 4]
movzx eax, bl
push 1
push eax
call fcn.0040dbb8
mov edx, esi
mov cl, 1
add esp, 8
mov bh, bl
jmp 0x4066a5
mov bl, byte [esp + edi + 0xc8]
test cl, cl
je 0x4066f0
cmp bh, bl
je 0x40670e
mov esi, edx
lea edx, [esp + 4]
movzx eax, bl
lea ecx, [esp + 0x88]
push ebp
push eax
call fcn.0040dbb8
mov edx, esi
add esp, 8
mov bh, bl
inc edx
mov al, 1
mov esi, edx
mov dword [esp], eax
jmp 0x40667f
mov dword [esp + 0x44], esi
mov dword [esp + 0x48], 0xff
mov byte [esp + 0x4c], 0
lea ecx, [esp + 0x44]
call fcn.00477774
test eax, eax
je 0x40676e
movzx eax, dl
cmp byte [esp], 0
mov bl, byte [esp + eax + 0xc8]
mov al, 1
mov dword [esp], eax
je 0x406752
cmp bh, bl
je 0x40672c
movzx eax, bl
lea ecx, [esp + 0x88]
lea edx, [esp + 4]
push 1
push eax
call fcn.0040dbb8
pop eax
pop ecx
mov bh, bl
jmp 0x40672c
mov eax, dword [esp + 0x10]
add dword [esp + 4], eax
lea ebx, [esp + 0x70]
jmp 0x40653d
mov ebx, dword [esp + 4]
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x30]
lea eax, [ebx + ecx]
mov dword [esp + 0x64], ebx
mov dword [esp + 0x24], eax
add eax, ecx
mov ecx, dword [esp + 0x28]
mov dword [esp + 4], eax
push 0x57e188
push edi
call fcn.00408083
pop ecx
pop edx
mov dword [eax], ebx
mov ebx, dword [esp + 0x24]
mov ecx, dword [esp + 0x34]
mov edx, dword [esp + 0x3c]
push 0x57e198
push edi
call fcn.00408083
pop ecx
pop edx
mov dword [eax], ebx
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0xc]
mov eax, dword [esp + 0x24]
shr eax, cl
mov ecx, dword [esp + 8]
push 0x57e1a8
push eax
call fcn.0047936b
pop ecx
pop edx
mov byte [eax], 1
mov ebp, dword [esp + 0x2fc]
lea eax, [esp + 0x88]
cmp dword [esi + 8], 0
je 0x406852
mov eax, dword [esp + 0x64]
mov ecx, ebp
mov edx, edi
mov dword [esp], eax
call fcn.00407808
mov ebx, edx
mov edx, dword [esp]
lea ecx, [esp + 0x88]
push ebx
push eax
call fcn.0040daf2
pop eax
pop ecx
mov eax, dword [esp + 0x24]
mov ecx, ebp
mov edx, edi
mov dword [esp], eax
call fcn.00407808
mov ebx, edx
mov edx, dword [esp]
lea ecx, [esp + 0x88]
push ebx
push eax
call fcn.0040daf2
lea eax, [esp + 0x90]
add esp, 8
mov dword [esp + 0x44], esi
mov dword [esp + 0x48], ebp
mov dword [esp + 0x4c], eax
lea eax, [esp + 0x64]
mov ecx, ebp
mov edx, edi
mov dword [esp + 0x50], eax
lea eax, [esp + 0x24]
mov dword [esp + 0x54], eax
call fcn.004077aa
xor ebx, ebx
mov dword [esp + 0x80], eax
mov dword [esp + 0x84], edx
mov dword [esp], 0
lea ecx, [esp + 0x58]
lea edx, [esp + 0x80]
call fcn.004077c7
cmp byte [esp + 0x58], 0
je 0x40692c
mov edi, dword [esp + 0x5a]
movzx esi, byte [esp + 0x59]
mov ecx, dword [esp]
mov dl, byte [esp + 0x14]
mov ebp, ebx
mov ebx, ebp
cmp ebp, esi
jae 0x4068f6
movzx eax, bl
test cl, cl
lea ebp, [ebx + 1]
mov cl, 1
mov al, byte [esp + eax + 0xc8]
je 0x4068d8
cmp dl, al
je 0x4068bb
lea ecx, [esp + 0x44]
mov edx, ebx
mov byte [esp], al
movzx eax, al
push 1
push eax
call fcn.0040d9ce
mov cl, 1
add esp, 8
mov dl, byte [esp]
jmp 0x4068bb
mov al, byte [esp + esi + 0xc8]
test cl, cl
je 0x406905
cmp dl, al
je 0x40691d
mov edx, esi
mov byte [esp], al
movzx eax, al
lea ecx, [esp + 0x44]
push edi
push eax
call fcn.0040d9ce
pop eax
pop ecx
mov dl, byte [esp]
mov al, 1
mov byte [esp + 0x14], dl
inc ebx
mov dword [esp], eax
jmp 0x40688e
mov dword [esp + 0x58], ebx
mov dword [esp + 0x5c], 0xff
mov byte [esp + 0x60], 0
lea ecx, [esp + 0x58]
call fcn.00477774
test eax, eax
je 0x406776
movzx eax, dl
cmp byte [esp], 0
mov bl, byte [esp + eax + 0xc8]
mov al, 1
mov dword [esp], eax
je 0x406969
cmp byte [esp + 0x14], bl
je 0x40693d
movzx eax, bl
lea ecx, [esp + 0x44]
push 1
push eax
call fcn.0040d9ce
pop eax
pop ecx
mov byte [esp + 0x14], bl
jmp 0x40693d
mov ecx, dword [esp + 0xbc]
xor eax, eax
mov dword [esp], ecx
mov edx, dword [esp + 0xc]
cmp eax, dword [esp]
je 0x406a6b
mov esi, eax
mov ecx, dword [esp + 0x18]
lea ebp, [eax + 1]
shl esi, cl
mov ecx, dword [esp + 8]
push 0x57e118
push eax
call fcn.0047936b
pop ecx
pop edx
cmp byte [eax], 0
mov ecx, dword [esp + 0x88]
mov edx, dword [esp + 0x90]
je 0x406a16
push 0x57e158
push esi
call fcn.0046e69f
pop ecx
pop ecx
mov ecx, eax
push 0x57e168
push dword [esp + 0x14]
call fcn.00409e8a
pop ecx
pop ecx
mov esi, edx
mov edi, eax
shl esi, 2
test esi, esi
je 0x406a64
mov ecx, dword [esp + 0x34]
mov edx, dword [esp + 0x3c]
lea ebx, [edi + 4]
push 0x57e178
push dword [edi]
call fcn.00408083
pop ecx
pop edx
mov eax, dword [eax]
add esi, 0xfffffffc
mov dword [edi], eax
mov edi, ebx
jmp 0x4069ee
push 0x57e128
push esi
call fcn.0046e69f
pop ecx
pop ecx
mov ecx, eax
push 0x57e138
push dword [esp + 0x14]
call fcn.00409e8a
pop ecx
pop ecx
mov esi, edx
mov edi, eax
shl esi, 2
test esi, esi
je 0x406a64
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x30]
lea ebx, [edi + 4]
push 0x57e148
push dword [edi]
call fcn.00408083
pop ecx
pop edx
mov eax, dword [eax]
add esi, 0xfffffffc
mov dword [edi], eax
mov edi, ebx
jmp 0x406a3c
mov eax, ebp
jmp 0x40698c
mov edi, dword [esp + 0x3c]
mov esi, dword [esp + 0x34]
mov ecx, esi
mov edx, edi
push 0x57e0d8
mov ebx, dword [esp + 0x300]
push dword [ebx + 0x150]
call fcn.00408083
pop ecx
pop edx
mov eax, dword [eax]
mov ecx, esi
mov edx, edi
mov dword [esp + 0x1d0], eax
push 0x57e0e8
push dword [ebx + 0x154]
call fcn.00408083
pop ecx
pop edx
mov eax, dword [eax]
mov ebx, dword [esp + 0x28]
mov edx, dword [esp + 0x30]
mov dword [esp + 0x1d4], eax
mov ecx, ebx
push 0x57e0f8
push dword [esp + 0x24]
call fcn.00408083
pop ecx
pop edx
mov eax, dword [eax]
mov ecx, esi
mov edx, edi
mov dword [esp + 0x1d8], eax
push 0x57e108
push dword [esp + 0x20]
call fcn.00408083
pop ecx
pop edx
mov eax, dword [eax]
mov ecx, dword [esp + 8]
mov edx, dword [esp + 0x40]
mov dword [esp + 0x1dc], eax
call fcn.0044816a
mov edx, dword [esp + 0x38]
mov ecx, esi
call fcn.00421312
mov edx, dword [esp + 0x2c]
mov ecx, ebx
call fcn.00421312
lea edi, [esp + 0xa0]
lea esi, [esp + 0x88]
mov ecx, esi
call fcn.00405151
mov ecx, edi
call fcn.00405151
mov eax, dword [esi + 0x10]
mov ebp, dword [esi + 0x14]
cmp eax, ebp
jbe 0x406b8c
mov ecx, dword [esp + 0x94]
imul eax, eax, 0xc
test ebp, ebp
je 0x406b66
imul edi, ebp, 0xc
mov edx, eax
push edi
call fcn.004051a7
pop ecx
mov ebx, eax
test eax, eax
push 4
pop ecx
jne 0x406b72
jmp 0x406b85
push 4
pop ebx
mov edx, ebx
push eax
call fcn.0040423b
pop eax
mov ecx, 0x80000001
mov dword [esp + 0x94], ebx
mov dword [esp + 0x98], ebp
mov edx, edi
call fcn.0040419b
mov edi, dword [esp + 0x6c]
lea eax, [edi + 4]
push 0x15c
push esi
push eax
call fcn.005669c0
add esp, 0xc
and dword [edi], 0
add esp, 0x2e4
pop esi
pop edi
pop ebx
pop ebp
ret
call fcn.004128f0
ud2
ud2