Function at 0x4240c0
Capabilities:
Check if file exists
Get file attributes
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x490b12
mov eax, dword fs:[0]
push eax
mov eax, 0x1074
call fcn.00463a90
mov eax, dword [0x4b9430]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
mov esi, edx
push esi
mov dword [ebp - 0x101c], eax
mov dword [ebp - 0x1018], ecx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x4242b3
mov edi, ebx
push 0
and edi, 0x10
mov eax, edi
shl eax, 0x15
push eax
push 3
push 0
push 1
push accept
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x1034], eax
cmp eax, 0xffffffff
je 0x4242b3
mov ecx, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, eax
lea esi, [ebp - 0x1040]
call fcn.004252d0
mov eax, dword [ebp - 0x1034]
lea edx, [ebp - 0x1080]
push edx
push 0
push 0
push eax
mov dword [ebp - 4], 0
call dword [sym.imp.KERNEL32.dll_GetFileTime]
lea ecx, [ebp - 0x1078]
push ecx
lea edx, [ebp - 0x1080]
push edx
call dword [sym.imp.KERNEL32.dll_FileTimeToLocalFileTime]
lea eax, [ebp - 0x102c]
push eax
lea ecx, [ebp - 0x1030]
push ecx
lea edx, [ebp - 0x1078]
push edx
call dword [sym.imp.KERNEL32.dll_FileTimeToDosDateTime]
movzx ecx, word [ebp - 0x1030]
movzx edx, word [ebp - 0x102c]
xor eax, eax
shl ecx, 0x10
mov dword [ebp - 0x1058], eax
mov dword [ebp - 0x1070], eax
mov dword [ebp - 0x106c], eax
mov dword [ebp - 0x1068], eax
mov dword [ebp - 0x1064], eax
mov dword [ebp - 0x1060], eax
mov dword [ebp - 0x105c], eax
mov dword [ebp - 0x1054], eax
or ecx, edx
or eax, ebx
cmp byte [ebp + 0xc], 0
mov dword [ebp - 0x1058], ecx
mov dword [ebp - 0x1050], eax
je 0x4242dc
mov ecx, dword [ebp - 0x1018]
lea eax, [ebp - 0x1018]
push eax
call fcn.00424e80
lea ecx, [ebp - 0x1018]
push ecx
lea edx, [ebp - 0x1014]
push edx
mov ebx, 0xfde9
mov byte [ebp - 4], 1
call fcn.00425460
add esp, 8
mov byte [ebp - 4], 3
mov eax, dword [ebp - 0x1018]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x424258
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [ebp - 0x1014]
mov ebx, dword [ebp - 0x101c]
push 0x800
push ecx
lea edx, [ebp - 0x1070]
mov ecx, ebx
call fcn.00425bb0
add esp, 8
or ecx, 0xffffffff
mov byte [ebp - 4], 0
test eax, eax
mov eax, dword [ebp - 0x1014]
je 0x4242ba
add eax, 0xfffffff0
lea edx, [eax + 0xc]
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x4242a4
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea ecx, [ebp - 0x1040]
push ecx
call fcn.00425300
add esp, 4
xor eax, eax
jmp 0x4244c1
add eax, 0xfffffff0
lea edx, [eax + 0xc]
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x424381
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
jmp 0x424381
lea ecx, [ebp - 0x1018]
push ecx
mov ecx, dword [ebp - 0x1018]
call fcn.00424e80
lea edx, [ebp - 0x1018]
push edx
lea eax, [ebp - 0x1014]
push eax
xor ebx, ebx
mov byte [ebp - 4], 4
call fcn.00425460
add esp, 8
mov byte [ebp - 4], 6
mov eax, dword [ebp - 0x1018]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x424330
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [ebp - 0x1014]
xor ebx, ebx
push ebx
push ecx
mov ecx, dword [ebp - 0x101c]
lea edx, [ebp - 0x1070]
call fcn.00425bb0
add esp, 8
or ecx, 0xffffffff
mov byte [ebp - 4], bl
test eax, eax
mov eax, dword [ebp - 0x1014]
jne 0x42428b
add eax, 0xfffffff0
lea edx, [eax + 0xc]
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x42437b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ebx, dword [ebp - 0x101c]
mov ecx, ebx
lea esi, [ebp - 0x104c]
call fcn.004252e0
mov byte [ebp - 4], 7
test edi, edi
je 0x4243ad
mov ecx, esi
push ecx
call fcn.00425360
add esp, 4
lea edx, [ebp - 0x1040]
push edx
jmp 0x4244b4
mov edi, dword [ebp - 0x1034]
xor eax, eax
mov dword [ebp - 0x1028], eax
mov dword [ebp - 0x1024], eax
lea eax, [ebp - 0x1028]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
jne 0x4243f8
lea ecx, [ebp - 0x104c]
push ecx
call fcn.00425360
lea edx, [ebp - 0x1040]
add esp, 4
push edx
call fcn.00425300
add esp, 4
xor eax, eax
jmp 0x4244c1
mov ecx, dword [ebp - 0x1024]
test ecx, ecx
jl 0x42449e
mov eax, dword [ebp - 0x1028]
jg 0x424416
test eax, eax
je 0x42449e
mov esi, dword [sym.imp.KERNEL32.dll_ReadFile]
lea esp, [esp]
test ecx, ecx
jl 0x424432
jg 0x42442d
cmp eax, 0x1000
jbe 0x424432
mov eax, 0x1000
push 0
lea ecx, [ebp - 0x1014]
push ecx
push eax
lea edx, [ebp - 0x1010]
push edx
push edi
mov dword [ebp - 0x1014], 0
call esi
test eax, eax
je 0x4243d3
mov eax, dword [ebp - 0x1014]
push eax
lea eax, [ebp - 0x1010]
mov ecx, ebx
call fcn.00426120
add esp, 4
test eax, eax
js 0x4244dd
mov eax, dword [ebp - 0x1028]
sub eax, dword [ebp - 0x1014]
mov ecx, dword [ebp - 0x1024]
sbb ecx, 0
mov dword [ebp - 0x1028], eax
mov dword [ebp - 0x1024], ecx
test ecx, ecx
jg 0x42442d
jl 0x42449e
test eax, eax
jne 0x424420
lea edx, [ebp - 0x104c]
push edx
call fcn.00425360
add esp, 4
lea eax, [ebp - 0x1040]
push eax
call fcn.00425300
mov eax, 1
add esp, 4
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0045d3b4
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x104c]
push eax
call fcn.00425360
lea ecx, [ebp - 0x1040]
add esp, 4
push ecx
call fcn.00425300
add esp, 4
xor eax, eax
jmp 0x4244c1