Function at 0x405bc0
Capabilities:
Check if file exists

Disassembly:
push 0xffffffffffffffff
push 0x41fcb2
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x12c
mov eax, dword [0x429990]
push ebx
push ebp
push esi
push edi
mov dword [esp + 0x138], eax
push 0x104
lea eax, [esp + 0x38]
push eax
xor ebx, ebx
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea ecx, [esp + 0x34]
push ecx
lea ecx, [esp + 0x1c]
call fcn.00401210
mov dword [esp + 0x144], ebx
call fcn.0041681c
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
add eax, 0x10
mov dword [esp + 0x20], eax
mov byte [esp + 0x144], 1
mov eax, dword [esp + 0x18]
push 0x5c
push eax
call fcn.0040a4de
add esp, 8
cmp eax, ebx
jne 0x405c46
or eax, 0xffffffff
jmp 0x405c4a
sub eax, dword [esp + 0x18]
inc eax
push eax
lea ecx, [esp + 0x14]
push ecx
lea ecx, [esp + 0x20]
call fcn.00402780
push eax
mov ecx, 0x43a1fc
mov byte [esp + 0x148], 2
call fcn.00401430
mov byte [esp + 0x144], 1
mov eax, dword [esp + 0x10]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x405c93
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov dword [esp + 0x10], ebx
mov dword [esp + 0x1c], ebx
jmp 0x405ca0
mov eax, dword [esp + 0x14c]
mov ebp, dword [eax + 4]
test ebp, ebp
je 0x405f84
mov eax, dword [eax + 8]
mov ecx, dword [esp + 0x10]
sub eax, ebp
sar eax, 4
cmp ecx, eax
jae 0x405f84
mov esi, dword [ebx + ebp]
mov ecx, dword [esi - 0x10]
mov eax, dword [ecx]
sub esi, 0x10
call dword [eax + 0x10]
mov edx, dword [esi + 0xc]
test edx, edx
lea ecx, [esi + 0xc]
jl 0x405cef
cmp eax, dword [esi]
jne 0x405cef
mov eax, esi
mov edx, 1
lock xadd dword [ecx], edx
jmp 0x405d21
mov ecx, dword [esi + 4]
mov edx, dword [eax]
push 1
push ecx
mov ecx, eax
call dword [edx]
test eax, eax
je 0x405f7f
mov edx, dword [esi + 4]
mov dword [eax + 4], edx
mov ecx, dword [esi + 4]
inc ecx
mov edx, ecx
shr ecx, 2
add esi, 0x10
lea edi, [eax + 0x10]
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
add eax, 0x10
mov dword [esp + 0x24], eax
mov byte [esp + 0x144], 3
mov esi, dword [ebx + ebp + 4]
mov ecx, dword [esi - 0x10]
mov eax, dword [ecx]
sub esi, 0x10
call dword [eax + 0x10]
mov ecx, dword [esi + 0xc]
test ecx, ecx
lea edx, [esi + 0xc]
jl 0x405d5a
cmp eax, dword [esi]
jne 0x405d5a
mov eax, esi
mov ecx, 1
lock xadd dword [edx], ecx
jmp 0x405d8c
mov ecx, dword [esi + 4]
mov edx, dword [eax]
push 1
push ecx
mov ecx, eax
call dword [edx]
test eax, eax
je 0x405f7f
mov edx, dword [esi + 4]
mov dword [eax + 4], edx
mov ecx, dword [esi + 4]
inc ecx
mov edx, ecx
shr ecx, 2
add esi, 0x10
lea edi, [eax + 0x10]
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ebx, [eax + 0x10]
mov eax, dword [esp + 0x1c]
mov ecx, dword [eax + ebp + 8]
mov edx, dword [eax + ebp + 0xc]
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x30], edx
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x18]
push 0x43a1fc
push ecx
mov byte [esp + 0x150], 4
call fcn.00406650
mov byte [esp + 0x150], 5
mov edx, dword [esp + 0x30]
push 0x424430
push edx
call fcn.0040a767
add esp, 0x14
test eax, eax
je 0x405df1
push 1
push 0x424430
lea ecx, [esp + 0x1c]
call fcn.00402a90
mov eax, dword [ebx - 0xc]
push eax
push ebx
lea ecx, [esp + 0x1c]
call fcn.00402a90
mov ebp, dword [esp + 0x14]
push ebp
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x405f02
mov eax, dword [ebx - 0xc]
test eax, eax
mov dword [esp + 0x2c], 0
jl 0x405ea8
push 0x424488
push ebx
call fcn.0040a33a
add esp, 8
test eax, eax
je 0x405ea8
sub eax, ebx
cmp eax, 0xffffffff
je 0x405ea8
push 0x4245dc
push ebp
or edi, 0xffffffff
call fcn.0040a86d
mov esi, eax
add esp, 8
test esi, esi
je 0x405ea4
push 2
push 0
push esi
call fcn.0040b08e
push esi
call fcn.0040afbe
push 0
push 0
push esi
mov edi, eax
call fcn.0040b08e
push edi
call fcn.00417949
push esi
push edi
mov ebp, eax
push 1
push ebp
call fcn.0040ad76
mov edx, edi
mov ecx, ebp
or eax, 0xffffffff
call fcn.00408950
push esi
mov edi, eax
call fcn.0040aa1f
push ebp
call fcn.0041794e
mov ebp, dword [esp + 0x4c]
add esp, 0x38
mov dword [esp + 0x2c], edi
mov edi, dword [esp + 0x150]
mov edx, dword [edi + 4]
test edx, edx
jne 0x405eba
xor ecx, ecx
jmp 0x405ec2
mov ecx, dword [edi + 8]
sub ecx, edx
sar ecx, 4
test edx, edx
je 0x405ef2
mov eax, dword [edi + 0xc]
sub eax, edx
sar eax, 4
cmp ecx, eax
jae 0x405ef2
mov eax, dword [esp + 0x20]
mov esi, dword [edi + 8]
push eax
lea ecx, [esp + 0x28]
push ecx
push 1
push esi
call fcn.00407060
add esp, 0x10
add esi, 0x10
mov dword [edi + 8], esi
jmp 0x405f02
mov eax, dword [edi + 8]
push 1
push eax
push edi
lea ecx, [esp + 0x30]
call fcn.00406ab0
lea eax, [ebp - 0x10]
mov byte [esp + 0x144], 4
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x405f24
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
lea eax, [ebx - 0x10]
mov byte [esp + 0x144], 1
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x405f46
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x405f64
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov ecx, dword [esp + 0x10]
mov eax, dword [esp + 0x1c]
inc ecx
add eax, 0x10
mov dword [esp + 0x10], ecx
mov dword [esp + 0x1c], eax
mov ebx, eax
jmp 0x405ca0
call fcn.00401960
mov byte [esp + 0x144], 0
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x405faa
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov dword [esp + 0x144], 0xffffffff
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x405fd3
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov ecx, dword [esp + 0x13c]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
mov ecx, dword [esp + 0x12c]
pop ebx
call fcn.0040b693
add esp, 0x138
ret 8