Function at 0x412500
Capabilities:
Read file on windows

Disassembly:
push 0xffffffffffffffff
push 0x4328bc
mov eax, dword fs:[0]
push eax
sub esp, 0x5c
mov eax, dword [0x445018]
xor eax, esp
mov dword [esp + 0x58], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x445018]
xor eax, esp
push eax
lea eax, [esp + 0x70]
mov dword fs:[0], eax
mov esi, ecx
xor ebx, ebx
mov dword [esp + 0x20], esi
mov dword [esp + 0x1c], ebx
mov ebp, 1
mov dword [esp + 0x78], ebp
cmp dword [esp + 0x94], ebx
jbe 0x4126cc
mov edi, 8
cmp dword [esp + 0x98], edi
jb 0x4126c0
mov eax, dword [esp + 0x84]
cmp eax, ebx
je 0x4126cc
push ebx
push eax
call dword [sym.imp.MSVCR80.dll__waccess]
add esp, 8
cmp eax, 0xffffffff
je 0x4126cc
cmp dword [esp + 0x98], edi
mov ebx, dword [esp + 0x84]
jae 0x4125a0
lea ebx, [esp + 0x84]
push ebp
call fcn.00404e60
mov edi, eax
mov esi, dword [edi]
push 2
push 0
push esi
call dword [sym.imp.MSVCR80.dll_fseek]
push esi
call dword [sym.imp.MSVCR80.dll_ftell]
mov ecx, eax
mov eax, 0x66666667
imul ecx
sar edx, 1
mov ebx, edx
shr ebx, 0x1f
add esp, 0x14
add ebx, edx
lea eax, [esp + 0x4c]
mov dword [esp + 0x14], eax
mov ebp, ebx
mov dword [esp + 0x18], 4
mov eax, dword [edi]
push 0
push ebp
push eax
call dword [sym.imp.MSVCR80.dll_fseek]
push 8
call dword [sym.imp.MSVCR80.dll_malloc]
mov esi, eax
mov eax, dword [edi]
push eax
push 8
push 1
push esi
call dword [sym.imp.MSVCR80.dll_fread]
mov ecx, dword [esp + 0x34]
push eax
push esi
push ecx
call sub.MSVCR80.dll_memcpy
add esp, 0x2c
test esi, esi
je 0x412624
push esi
call dword [sym.imp.MSVCR80.dll_free]
add esp, 4
add dword [esp + 0x14], 8
add ebp, ebx
sub dword [esp + 0x18], 1
jne 0x4125e3
push 0x438598
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__]
mov byte [esp + 0x78], 2
mov ebx, dword [sym.imp.MSVCR80.dll_sprintf_s]
xor esi, esi
mov edi, edi
movzx edx, byte [esp + esi + 0x4c]
push edx
push str._02x
lea eax, [esp + 0x48]
push 0xa
push eax
call ebx
add esp, 0x10
lea ecx, [esp + 0x40]
push ecx
lea ecx, [esp + 0x28]
call dword [sym.imp.MSVCP80.dll_public:_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char______thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::append_char_const__]
add esi, 1
cmp esi, 0x20
jne 0x412650
mov eax, dword [edi]
push eax
call dword [sym.imp.MSVCR80.dll_fclose]
push edi
call dword [sym.imp.MSVCR80.dll_free]
mov esi, dword [esp + 0x28]
add esp, 8
lea edx, [esp + 0x24]
push edx
mov ecx, esi
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char___const__]
lea ecx, [esp + 0x24]
mov dword [esp + 0x1c], 1
mov byte [esp + 0x78], 1
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 byte [esp + 0x78], 0
jmp 0x4126e1
lea eax, [esp + 0x84]
jmp 0x412575
push 0x438598
mov ecx, esi
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__]
mov dword [esp + 0x1c], ebp
mov byte [esp + 0x78], bl
lea ecx, [esp + 0x80]
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
mov eax, esi
mov ecx, dword [esp + 0x70]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x58]
xor ecx, esp
call fcn.00431147
add esp, 0x68
ret