Function at 0x475df8
Capabilities:
Get file size
Read file on windows

Disassembly:
push 0x3d0
mov eax, 0x513637
call fcn.004a5358
mov eax, dword [ebp + 8]
xor ebx, ebx
mov dword [ebp - 0x3d4], eax
mov esi, ebx
mov edi, ebx
call fcn.0045abb4
push eax
lea ecx, [ebp - 0x94]
call fcn.0045800b
mov dword [ebp - 4], ebx
call fcn.0045abc0
mov ecx, eax
call fcn.0045882e
test al, al
je 0x475ee6
push dword [ebp - 0x3d4]
lea ecx, [ebp - 0x94]
call fcn.0045829a
push ebx
push 0x80
push 3
push ebx
push 1
push accept
lea ecx, [ebp - 0x94]
call fcn.00403280
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x3d0], eax
cmp eax, 0xffffffff
jne 0x475e90
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x94]
call fcn.00458132
jmp 0x476077
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
test edi, edi
je 0x475e7c
push edi
mov dword [ebp - 0x3d8], ebx
call fcn.004a4c93
pop ecx
push ebx
mov esi, eax
lea eax, [ebp - 0x3d8]
push eax
push edi
push esi
push dword [ebp - 0x3d0]
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x3d0]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x3d8], edi
je 0x476064
push esi
call fcn.004a4c9c
pop ecx
mov esi, ebx
jmp 0x475e7c
call fcn.0045abc0
push eax
lea ecx, [ebp - 0x94]
call fcn.0045827d
call fcn.0045aede
test al, al
je 0x475f0d
call fcn.0045abc6
mov dword [ebp - 0x3d0], eax
jmp 0x475f79
call fcn.0045abcc
push eax
lea ecx, [ebp - 0x19c]
call fcn.0045800b
lea ecx, [ebp - 0x19c]
mov byte [ebp - 4], 1
call fcn.00403280
push eax
call fcn.004810eb
pop ecx
push eax
lea ecx, [ebp - 0x94]
mov dword [ebp - 0x3d8], eax
call fcn.00403280
push eax
call fcn.0046adc8
mov dword [ebp - 0x3d0], eax
mov eax, dword [ebp - 0x3d8]
pop ecx
pop ecx
test eax, eax
je 0x475f65
push eax
call fcn.004a4c9c
pop ecx
lea ecx, [ebp - 0x19c]
mov byte [ebp - 4], bl
call fcn.00458132
mov eax, dword [ebp - 0x3d0]
test eax, eax
je 0x475e7c
push 0xffffffffffffffff
push dword [ebp - 0x3d4]
lea ecx, [ebp - 0x118]
mov dword [ebp - 0x3dc], ebx
call fcn.00458030
push 0x51fe80
push 0x53f780
lea ecx, [ebp - 0x118]
mov byte [ebp - 4], 2
call fcn.004589fb
lea eax, [ebp - 0x3cc]
push eax
lea eax, [ebp - 0x3dc]
push eax
push 1
lea ecx, [ebp - 0x118]
call fcn.00403280
push eax
push dword [ebp - 0x3d0]
call fcn.0046a79f
add esp, 0x14
test eax, eax
je 0x475ff1
lea ecx, [ebp - 0x118]
call fcn.00458132
jmp 0x475e7c
mov edi, dword [ebp - 0x1a0]
test edi, edi
je 0x475fe1
push edi
call fcn.004a4c93
push edi
mov esi, eax
push esi
push dword [ebp - 0x3dc]
push dword [ebp - 0x3d0]
call fcn.0046b202
add esp, 0x14
test eax, eax
je 0x476044
cmp eax, 0x600
je 0x476044
push esi
call fcn.004a4c9c
pop ecx
mov esi, ebx
call fcn.0045aede
test al, al
jne 0x475fe1
push dword [ebp - 0x3d0]
call fcn.0046a57e
pop ecx
jmp 0x475fe1
call fcn.0045aede
test al, al
jne 0x476059
push dword [ebp - 0x3d0]
call fcn.0046a57e
pop ecx
lea ecx, [ebp - 0x118]
call fcn.00458132
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x94]
call fcn.00458132
test esi, esi
jne 0x4760f2
push ebx
push 0x80
push 3
push ebx
push 1
push accept
push dword [ebp - 0x3d4]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x3d4], eax
cmp eax, 0xffffffff
je 0x4760ee
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
test edi, edi
je 0x4760ee
push edi
mov dword [ebp - 0x3d0], ebx
call fcn.004a4c93
pop ecx
push ebx
mov esi, eax
lea eax, [ebp - 0x3d0]
push eax
push edi
push esi
push dword [ebp - 0x3d4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x3d4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x3d0], edi
je 0x4760ee
push esi
call fcn.004a4c9c
pop ecx
mov esi, ebx
test esi, esi
je 0x476106
push edi
push esi
call fcn.00475d8d
push 1
push esi
mov ebx, eax
call fcn.004a4506
add esp, 0x10
mov eax, ebx
call fcn.004a5313
ret