Function at 0x409070
Capabilities:
Read file on windows

Disassembly:
push 0xffffffffffffffff
push 0x40a02c
mov eax, dword fs:[0]
push eax
sub esp, 0x450
mov eax, dword [0x41013c]
xor eax, esp
mov dword [esp + 0x44c], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x41013c]
xor eax, esp
push eax
lea eax, [esp + 0x464]
mov dword fs:[0], eax
mov dx, word [0x410180]
cmp dx, 0x834
mov eax, dword [esp + 0x474]
mov ebp, dword [esp + 0x478]
ja 0x4091a5
jne 0x4090db
cmp word [0x410182], 1
ja 0x4091a5
test eax, eax
mov esi, dword [ecx]
je 0x4091a5
mov ecx, eax
lea edi, [ecx + 1]
lea ebx, [ebx]
mov dl, byte [ecx]
add ecx, 1
test dl, dl
jne 0x4090f0
sub ecx, edi
cmp ecx, 4
jbe 0x4091a5
or ebx, 0xffffffff
cmp dword [esi + 4], ebx
jne 0x409202
cmp dword [esi], 0
jne 0x4091a5
cmp byte [eax], 0x2e
jne 0x409121
add eax, 1
mov cl, byte [eax]
cmp cl, 0x5c
je 0x40912d
cmp cl, 0x2f
jne 0x409130
add eax, 1
cmp dword [esi + 0x20], 0x10
jb 0x40913b
mov esi, dword [esi + 0xc]
jmp 0x40913e
add esi, 0xc
push eax
push esi
lea eax, [esp + 0x268]
push str._s_s
push eax
call dword [sym.imp.MSVCR80.dll_sprintf]
lea ecx, [esp + 0x270]
push 0x40e98c
push ecx
call dword [sym.imp.MSVCR80.dll_fopen]
mov esi, eax
add esp, 0x18
test esi, esi
je 0x4091a5
mov ebx, dword [sym.imp.MSVCR80.dll_fseek]
push 2
push 0
push esi
call ebx
add esp, 0xc
test eax, eax
push esi
jne 0x40919c
call dword [sym.imp.MSVCR80.dll_ftell]
add esp, 4
mov edi, eax
push edi
mov ecx, ebp
call fcn.00408df0
test eax, eax
jne 0x4091d1
push esi
call dword [sym.imp.MSVCR80.dll_fclose]
add esp, 4
xor eax, eax
mov ecx, dword [esp + 0x464]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x44c]
xor ecx, esp
call fcn.00409415
add esp, 0x45c
ret 8
push 0
push 0
push esi
call ebx
add esp, 0xc
test eax, eax
push esi
jne 0x40919c
push 1
push edi
mov ecx, ebp
call fcn.00408e60
push eax
call dword [sym.imp.MSVCR80.dll_fread]
push esi
call dword [sym.imp.MSVCR80.dll_fclose]
add esp, 0x14
mov eax, 1
jmp 0x4091a7
cmp dword [esi + 0x34], 0
jbe 0x4091a5
lea edx, [esp + 0x60]
sub edx, eax
mov edi, edi
mov cl, byte [eax]
mov byte [edx + eax], cl
add eax, 1
test cl, cl
jne 0x409210
lea edx, [esp + 0x60]
push edx
mov ecx, esi
call fcn.00408ef0
lea eax, [esp + 0x60]
push eax
lea ecx, [esp + 0x28]
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_char_const__]
lea ecx, [esp + 0x24]
push ecx
lea edx, [esp + 0x20]
lea edi, [esi + 0x2c]
push edx
mov ecx, edi
mov dword [esp + 0x474], 0
call fcn.00409000
lea ecx, [esp + 0x24]
mov dword [esp + 0x46c], ebx
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
mov eax, dword [edi + 4]
lea ecx, [esp + 0x14]
push ecx
lea ecx, [esp + 0x20]
mov dword [esp + 0x1c], eax
mov dword [esp + 0x18], edi
call fcn.00408f50
test al, al
jne 0x4091a5
lea ecx, [esp + 0x1c]
call fcn.00408fd0
xor ecx, ecx
add eax, 0x1c
mov dword [esp + 0x44], ecx
mov dword [esp + 0x48], ecx
mov dword [esp + 0x4c], ecx
mov dword [esp + 0x50], ecx
mov edx, dword [eax]
push edx
mov ecx, esi
call fcn.00408ed0
push 0x20
lea eax, [esp + 0x44]
push eax
mov ecx, esi
call fcn.00408e80
test eax, eax
je 0x4091a5
cmp dword [esp + 0x54], ebx
je 0x40935a
mov ecx, dword [esp + 0x5c]
cmp ecx, dword [esi + 0x24]
jle 0x4092f9
mov edx, dword [esi + 0x28]
push edx
call sub.MSVCR80.dll_void___cdecl_operator_delete___void__
mov eax, dword [esp + 0x60]
mov dword [esi + 0x24], eax
mov ecx, dword [esp + 0x60]
push ecx
call fcn.00409410
add esp, 8
mov dword [esi + 0x28], eax
mov edx, dword [esp + 0x5c]
mov edi, dword [esi + 0x28]
push edx
push edi
mov ecx, esi
call fcn.00408e80
test eax, eax
je 0x4091a5
mov eax, dword [esp + 0x58]
push eax
mov ecx, ebp
mov dword [esp + 0x18], eax
call fcn.00408df0
mov eax, dword [esp + 0x5c]
push eax
push edi
lea ecx, [esp + 0x1c]
push ecx
mov ecx, ebp
call fcn.00408e60
push eax
call fcn.00401ce0
add esp, 0x10
test eax, eax
je 0x40934e
mov edx, dword [esp + 0x14]
cmp edx, dword [esp + 0x58]
je 0x4091fb
mov ecx, ebp
call fcn.00408dc0
jmp 0x4091a5
mov eax, dword [esp + 0x5c]
push eax
mov ecx, ebp
call fcn.00408df0
mov ecx, dword [esp + 0x5c]
push ecx
mov ecx, ebp
call fcn.00408e60
push eax
mov ecx, esi
call fcn.00408e80
test eax, eax
jne 0x4091fb
mov ecx, ebp
call fcn.00408dc0
jmp 0x4091a5