Function at 0x41028b
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x13c
cmp dword [ebp + 0x10], 0
push ebx
push esi
push edi
jge 0x4102a5
push 5
call fcn.00408da9
pop ecx
mov eax, dword [ebp + 0x24]
lea ecx, [ebp - 0xc0]
xor ebx, ebx
mov byte [eax], bl
call fcn.00406afe
mov esi, dword [ebp + 8]
push 2
pop edi
push 0x80
push 3
push esi
lea ecx, [ebp - 0xc0]
call fcn.004436ec
push eax
call fcn.00435954
pop ecx
test al, al
jne 0x410335
push dword [ebp + 0x10]
lea ecx, [ebp - 0xbc]
push dword [ebp + 0xc]
call fcn.004441cd
test al, al
je 0x410335
lea ecx, [ebp - 0xc0]
call fcn.0043d613
mov eax, dword [0x4ad830]
and eax, 0x40000
or eax, ebx
je 0x410388
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push esi
call fcn.0043ef54
add esp, 0xc
test al, al
jne 0x410388
test edi, edi
jne 0x41037f
call fcn.0044974c
push esi
push dword [ebp + 0x18]
call fcn.0040d73c
pop ecx
pop ecx
jmp 0x410512
call sub.KERNEL32.dll_GetLastError
mov dword [ebp - 0x20], eax
cmp edi, 2
jne 0x410373
cmp eax, 3
jne 0x41034e
push esi
call fcn.0043dc0e
pop ecx
mov eax, dword [0x4ad830]
and eax, 0x80000
or eax, ebx
je 0x410377
lea ecx, [ebp - 0xc0]
call fcn.0043d613
push ebx
push 7
push esi
call fcn.0043edfe
add esp, 0xc
test edi, edi
je 0x4103ec
push 0x32
call fcn.0044976c
pop ecx
sub edi, 1
jns 0x4102bd
mov edi, dword [ebp + 0x14]
cmp dword [edi + 4], ebx
je 0x4103c3
cmp dword [edi + 0xc], ebx
jl 0x4103c3
push 0x80
push 0x301
push esi
lea ecx, [ebp - 0xc0]
call fcn.004436ec
push edi
lea ecx, [ebp - 0xc0]
call fcn.0043da4f
push edi
lea ecx, [ebp - 0xc0]
call fcn.0043daf8
lea ecx, [ebp - 0xc0]
call fcn.0043d613
cmp dword [ebp + 0x1c], 0xffffffff
je 0x4103e5
push 0x1127
push dword [ebp + 0x1c]
push esi
call fcn.0043ee86
add esp, 0xc
mov bl, 1
jmp 0x410512
lea ecx, [ebp - 0x2c]
call fcn.0042717c
lea ecx, [ebp - 0x10]
call fcn.0042717c
push closesocket
push esi
lea ecx, [ebp - 0x10]
call fcn.0042cf82
push ebx
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0x10]
push eax
call fcn.00441f02
add esp, 0xc
lea ecx, [ebp - 0x10]
call fcn.00424b62
lea ecx, [ebp - 0x38]
call fcn.0042717c
cmp dword [ebp - 0x2c], ebx
lea eax, [ebp - 0x10]
mov edi, dword [0x4a61b4]
mov esi, 0x47e734
cmovne esi, dword [ebp - 0x2c]
push 0x1f
push eax
call fcn.0040785b
push ebx
push edi
push esi
cmp dword [eax], ebx
mov ecx, 0x47e734
push 0x480068
cmovne ecx, dword [eax]
lea eax, [ebp - 0x38]
push ecx
push dword [0x4a61b4]
push eax
call fcn.0042d164
add esp, 0x24
lea ecx, [ebp - 0x10]
call fcn.00424b62
cmp byte [ebp + 0x20], bl
jne 0x41048a
mov eax, dword [0x4ad830]
and eax, 0x800
or eax, ebx
mov al, bl
je 0x41048c
mov al, 1
mov esi, dword [ebp - 0x20]
xor ecx, ecx
movzx eax, al
cmp esi, 0x7b
push ebx
push dword [ebp + 8]
cmove eax, ecx
mov dword [ebp - 0x20], eax
call fcn.00440e57
mov byte [ebp - 1], al
lea eax, [ebp - 1]
push eax
call fcn.0043e6b7
add esp, 0xc
test al, al
jne 0x410524
movsx eax, byte [ebp - 1]
push eax
lea eax, [ebp - 0x38]
push 0x48006c
push eax
call fcn.00426bc4
add esp, 0xc
lea ecx, [ebp - 0x10]
call fcn.0042717c
push ebx
push 0x47f86c
push ebx
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x38]
push eax
call fcn.0044a36c
mov ecx, dword [ebp + 0x18]
lea eax, [ebp - 0x10]
add esp, 0x14
push eax
call fcn.00422b93
lea ecx, [ebp - 0x10]
call fcn.00424b62
lea ecx, [ebp - 0x38]
call fcn.00424b62
lea ecx, [ebp - 0x2c]
call fcn.00424b62
lea ecx, [ebp - 0xc0]
call fcn.00407145
pop edi
pop esi
mov al, bl
pop ebx
leave
ret
lea eax, [ebp - 0x10]
push esi
push eax
call fcn.00449650
pop ecx
pop ecx
cmp dword [ebp - 0xc], ebx
jle 0x410547
push dword [0x4a61b8]
lea eax, [ebp - 0x10]
push eax
lea ecx, [ebp - 0x38]
call fcn.004230c7
lea ecx, [ebp - 0x10]
call fcn.00424b62
mov byte [ebp - 2], 1
cmp byte [ebp - 0x20], bl
je 0x4104cf
push dword [ebp + 8]
lea eax, [ebp - 0x10]
push eax
call fcn.00440cf1
mov esi, 0x47e730
push ebx
mov ecx, esi
cmp dword [eax], ebx
push ebx
cmovne ecx, dword [eax]
lea eax, [ebp - 0x1c]
push ecx
push eax
call fcn.0043f2c3
add esp, 0x18
lea ecx, [ebp - 0x10]
call fcn.00424b62
cmp dword [ebp - 0x18], ebx
jle 0x41072a
push dword [ebp + 0x10]
cmp dword [ebp - 0x1c], ebx
mov eax, esi
push dword [ebp + 0xc]
cmovne eax, dword [ebp - 0x1c]
push eax
call fcn.0043f248
push eax
call fcn.00435954
add esp, 0x10
test al, al
jne 0x41072a
cmp dword [ebp - 0x1c], ebx
mov eax, esi
push ebx
cmovne eax, dword [ebp - 0x1c]
push eax
call fcn.00451448
mov edi, dword [ebp + 0x14]
pop ecx
pop ecx
cmp dword [edi + 4], ebx
je 0x410626
cmp dword [edi + 0xc], ebx
jl 0x410626
lea ecx, [ebp - 0x13c]
call fcn.00406afe
cmp dword [ebp - 0x1c], ebx
lea ecx, [ebp - 0x13c]
push 0x80
mov eax, esi
cmovne eax, dword [ebp - 0x1c]
push 0x301
push eax
call fcn.004436ec
push edi
lea ecx, [ebp - 0x13c]
call fcn.0043da4f
push edi
lea ecx, [ebp - 0x13c]
call fcn.0043daf8
lea ecx, [ebp - 0x13c]
call fcn.00407145
lea ecx, [ebp - 0x10]
call fcn.0042717c
push ebx
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x1c]
push eax
call fcn.00441f02
cmp dword [ebp - 0x1c], ebx
mov eax, esi
cmovne eax, dword [ebp - 0x1c]
push eax
lea eax, [ebp - 0x44]
push eax
call fcn.00441282
add esp, 0x14
lea ecx, [ebp - 0x1c]
push eax
call fcn.004074e1
lea ecx, [ebp - 0x44]
call fcn.00424b62
call fcn.0044974c
cmp dword [ebp - 0x1c], ebx
push 8
cmovne esi, dword [ebp - 0x1c]
sub esp, 0xc
mov ecx, esp
push dword [ebp + 8]
call fcn.00406f92
push esi
call fcn.0043ffb8
add esp, 0x14
test al, al
jne 0x4106e0
lea eax, [ebp - 0x44]
push eax
call fcn.0044972e
mov esi, 0x47e734
mov edx, esi
mov ecx, esi
cmp dword [eax], ebx
cmovne edx, dword [eax]
mov eax, esi
cmp dword [ebp - 0x10], ebx
push edx
cmovne ecx, dword [ebp - 0x10]
cmp dword [ebp - 0x2c], ebx
push ecx
cmovne eax, dword [ebp - 0x2c]
push eax
lea eax, [ebp - 0x38]
push 0x480160
push eax
call fcn.00426bc4
add esp, 0x18
lea ecx, [ebp - 0x44]
call fcn.00424b62
cmp dword [ebp - 0x10], ebx
push ebx
cmovne esi, dword [ebp - 0x10]
push esi
call fcn.0043fbd9
pop ecx
pop ecx
jmp 0x410725
or dword [0x4ad830], 0x4000
mov ecx, 0x47e734
mov eax, dword [0x4ad834]
cmp dword [ebp - 0x10], ebx
mov dword [0x4ad834], eax
mov eax, ecx
cmovne eax, dword [ebp - 0x10]
cmp dword [ebp - 0x2c], ebx
push eax
cmovne ecx, dword [ebp - 0x2c]
lea eax, [ebp - 0x38]
push ecx
push 0x4801f8
push eax
mov byte [ebp - 2], bl
call fcn.00426bc4
mov eax, dword [ebp + 0x24]
add esp, 0x10
mov byte [eax], 1
lea ecx, [ebp - 0x10]
jmp 0x41075c
lea eax, [ebp - 0x44]
push eax
call fcn.0044972e
mov edx, 0x47e734
mov ecx, edx
cmp dword [eax], ebx
cmovne ecx, dword [eax]
lea eax, [ebp - 0x38]
cmp dword [ebp - 0x2c], ebx
push ecx
cmovne edx, dword [ebp - 0x2c]
push edx
push 0x4800a8
push eax
call fcn.00426bc4
add esp, 0x14
lea ecx, [ebp - 0x44]
call fcn.00424b62
lea ecx, [ebp - 0x1c]
call fcn.00424b62
cmp byte [ebp - 2], bl
jne 0x4104cf
lea eax, [ebp - 0x38]
push eax
call fcn.0040d621
pop ecx
jmp 0x410502