Function at 0x407730
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x408bf8
mov eax, dword fs:[0]
push eax
sub esp, 0x3c
mov eax, dword [0x40d01c]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x48], ecx
mov ecx, dword [ebp - 0x48]
call fcn.00406ce0
mov ecx, dword [ebp - 0x48]
add ecx, 4
call fcn.004033a0
mov eax, dword [ebp + 8]
push eax
mov ecx, dword [ebp - 0x48]
add ecx, 0x20
call fcn.00403190
push 0x40aa0c
mov ecx, dword [ebp - 0x48]
add ecx, 0x20
call fcn.004030d0
push eax
call dword [sym.imp.MSVCR90.dll_fopen]
add esp, 8
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
je 0x4079f1
mov dword [ebp - 0x18], 0
push 2
push 0
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.MSVCR90.dll_fseek]
add esp, 0xc
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.MSVCR90.dll_ftell]
add esp, 4
mov dword [ebp - 0x18], eax
push 0
push 0
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.MSVCR90.dll_fseek]
add esp, 0xc
cmp dword [ebp - 0x18], 0
jne 0x4077f4
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.MSVCR90.dll_fclose]
add esp, 4
xor al, al
jmp 0x407a03
lea ecx, [ebp - 0x24]
call fcn.00402fc0
mov dword [ebp - 4], 0
mov edx, dword [ebp - 0x18]
push edx
lea ecx, [ebp - 0x24]
call fcn.004089c0
mov eax, dword [ebp - 0x18]
add eax, 1
push eax
call sub.MSVCR90.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
mov dword [ebp - 0x28], eax
mov ecx, dword [ebp - 0x28]
mov dword [ebp - 0x20], ecx
mov edx, dword [ebp - 0x20]
mov byte [edx], 0
mov eax, dword [ebp - 0x10]
push eax
push 1
mov ecx, dword [ebp - 0x18]
push ecx
mov edx, dword [ebp - 0x20]
push edx
call dword [sym.imp.MSVCR90.dll_fread]
add esp, 0x10
cmp eax, 1
je 0x407881
push 0
push 0
push 0
push 2
mov ecx, dword [ebp - 0x48]
call fcn.00405240
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.MSVCR90.dll_fclose]
add esp, 4
mov byte [ebp - 0x29], 0
mov dword [ebp - 4], 0xffffffff
lea eax, [ebp - 0x24]
call fcn.004010b0
mov al, byte [ebp - 0x29]
jmp 0x407a03
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.MSVCR90.dll_fclose]
add esp, 4
mov edx, dword [ebp - 0x20]
mov dword [ebp - 0x1c], edx
mov eax, dword [ebp - 0x20]
mov dword [ebp - 0x14], eax
mov ecx, dword [ebp - 0x20]
add ecx, dword [ebp - 0x18]
mov byte [ecx], 0
mov edx, dword [ebp - 0x14]
movsx eax, byte [edx]
test eax, eax
je 0x407951
mov ecx, dword [ebp - 0x14]
movsx edx, byte [ecx]
cmp edx, 0xa
jne 0x4078e3
mov eax, dword [ebp - 0x14]
sub eax, dword [ebp - 0x1c]
add eax, 1
push eax
mov ecx, dword [ebp - 0x1c]
push ecx
lea ecx, [ebp - 0x24]
call fcn.00408a70
mov edx, dword [ebp - 0x14]
add edx, 1
mov dword [ebp - 0x14], edx
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x1c], eax
jmp 0x40794c
mov ecx, dword [ebp - 0x14]
movsx edx, byte [ecx]
cmp edx, 0xd
jne 0x407943
mov eax, dword [ebp - 0x14]
sub eax, dword [ebp - 0x1c]
test eax, eax
jle 0x40790b
mov ecx, dword [ebp - 0x14]
sub ecx, dword [ebp - 0x1c]
push ecx
mov edx, dword [ebp - 0x1c]
push edx
lea ecx, [ebp - 0x24]
call fcn.00408a70
push 0xa
lea ecx, [ebp - 0x24]
call fcn.00403220
mov eax, dword [ebp - 0x14]
movsx ecx, byte [eax + 1]
cmp ecx, 0xa
jne 0x407932
mov edx, dword [ebp - 0x14]
add edx, 2
mov dword [ebp - 0x14], edx
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x1c], eax
jmp 0x407941
mov ecx, dword [ebp - 0x14]
add ecx, 1
mov dword [ebp - 0x14], ecx
mov edx, dword [ebp - 0x14]
mov dword [ebp - 0x1c], edx
jmp 0x40794c
mov eax, dword [ebp - 0x14]
add eax, 1
mov dword [ebp - 0x14], eax
jmp 0x4078a3
mov ecx, dword [ebp - 0x14]
sub ecx, dword [ebp - 0x1c]
je 0x40796c
mov edx, dword [ebp - 0x14]
sub edx, dword [ebp - 0x1c]
push edx
mov eax, dword [ebp - 0x1c]
push eax
lea ecx, [ebp - 0x24]
call fcn.00408a70
mov ecx, dword [ebp - 0x20]
mov dword [ebp - 0x30], ecx
mov edx, dword [ebp - 0x30]
push edx
call sub.MSVCR90.dll_void___cdecl_operator_delete_void__
add esp, 4
mov dword [ebp - 0x20], 0
mov eax, dword [ebp + 0xc]
push eax
push 0
lea ecx, [ebp - 0x24]
call fcn.004030d0
push eax
mov ecx, dword [ebp - 0x48]
mov edx, dword [ecx]
mov ecx, dword [ebp - 0x48]
mov eax, dword [edx + 8]
call eax
mov ecx, dword [ebp - 0x48]
call fcn.004039e0
movzx ecx, al
test ecx, ecx
je 0x4079ca
mov byte [ebp - 0x31], 0
mov dword [ebp - 4], 0xffffffff
lea eax, [ebp - 0x24]
call fcn.004010b0
mov al, byte [ebp - 0x31]
jmp 0x407a03
mov byte [ebp - 0x32], 1
mov dword [ebp - 4], 0xffffffff
lea eax, [ebp - 0x24]
call fcn.004010b0
mov al, byte [ebp - 0x32]
jmp 0x407a03
push 0
push 0
push 0
push 2
mov ecx, dword [ebp - 0x48]
call fcn.00405240
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov esp, ebp
pop ebp
ret 8