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

Disassembly:
push 0xffffffffffffffff
mov eax, dword fs:[0]
push 0x46da70
push eax
mov eax, 0x1298
mov dword fs:[0], esp
call fcn.0043f620
push ebx
push ebp
push esi
mov ebp, ecx
push edi
mov dword [esp + 0x30], ebp
call fcn.00468777
mov ecx, dword [eax + 4]
call fcn.00457f84
mov ecx, dword [ebp + 4]
or eax, 0xffffffff
cmp ecx, eax
mov dword [esp + 0x12b0], 0
je 0x401c5d
mov ebx, dword [esp + 0x12b8]
test ebx, ebx
je 0x401c5d
mov ecx, dword [esp + 0x12bc]
test ecx, ecx
je 0x401c5d
mov ecx, dword [esp + 0x12c0]
test ecx, ecx
je 0x401c5d
mov ecx, 0x213
mov esi, ebx
lea edi, [esp + 0xa5c]
lea eax, [esp + 0xa5c]
push str.BP_R1.0.0
push eax
rep movsd dword es:[edi], dword [esi]
call fcn.0043f59c
mov ecx, dword [ebx + 0x434]
mov edx, dword [ebp + 4]
add esp, 8
inc ecx
mov dword [esp + 0xe90], ecx
lea ecx, [esp + 0x38]
push edx
mov dword [esp + 0xe98], 0x84c
call fcn.00458ed9
lea eax, [esp + 0xa5c]
push 0x84c
push eax
lea ecx, [esp + 0x40]
mov byte [esp + 0x12b8], 1
call fcn.004591ac
mov esi, dword [esp + 0xe90]
lea ecx, [esp + 0xa90]
push ecx
lea ecx, [esp + 0x20]
call fcn.0045854a
mov ecx, 0x285
xor eax, eax
lea edi, [esp + 0x48]
mov byte [esp + 0x12b0], 2
rep stosd dword es:[edi], eax
mov eax, esi
shl eax, 7
add eax, esi
lea edx, [eax + eax*4]
xor eax, eax
dec esi
mov dword [esp + 0x14], eax
cmp esi, eax
lea ebx, [edx*4 + 0x84c]
mov dword [esp + 0x24], eax
mov dword [esp + 0x18], esi
jle 0x401835
mov eax, dword [esp + 0x12c0]
lea ebp, [eax + 0x610]
mov ecx, 0x285
xor eax, eax
lea edi, [esp + 0x48]
lea esi, [ebp - 0x610]
rep stosd dword es:[edi], eax
lea edi, [ebp - 0x40c]
mov dword [esp + 0x48], 0xa14
push edi
call fcn.0043f601
add esp, 4
test eax, eax
je 0x4017c6
push 0
push 0x80
push 3
push 0
push 1
push SysReAllocString
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x401911
push 0
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push edi
mov dword [ebp - 0xc], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, 0x285
lea edi, [esp + 0x48]
mov dword [ebp], ebx
rep movsd dword es:[edi], dword [esi]
lea ecx, [esp + 0x24c]
push ecx
lea ecx, [esp + 0x14]
call fcn.0045854a
push 0x5c
lea ecx, [esp + 0x14]
mov byte [esp + 0x12b4], 4
call fcn.004512ef
mov edx, dword [esp + 0x10]
mov ecx, dword [edx - 8]
sub ecx, eax
lea eax, [esp + 0x2c]
dec ecx
push ecx
push eax
lea ecx, [esp + 0x18]
call fcn.004511fb
push eax
lea ecx, [esp + 0x14]
mov byte [esp + 0x12b4], 5
call fcn.0045861d
lea ecx, [esp + 0x2c]
mov byte [esp + 0x12b0], 4
call fcn.004584d6
mov ecx, 0x80
xor eax, eax
lea edi, [esp + 0x24c]
lea edx, [esp + 0x24c]
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0x10]
push ecx
push edx
call fcn.0043f59c
add esp, 8
lea ecx, [esp + 0x10]
mov byte [esp + 0x12b0], 2
call fcn.004584d6
jmp 0x4017df
mov ecx, 0x285
lea edi, [esp + 0x48]
mov dword [ebp - 0xc], 0
mov dword [ebp], 0
rep movsd dword es:[edi], dword [esi]
lea eax, [esp + 0x48]
push 0xa14
push eax
lea ecx, [esp + 0x40]
call fcn.004591ac
mov edx, dword [esp + 0x14]
lea ecx, [esp + 0x48]
push 0xa14
push ecx
push edx
call fcn.00406d00
mov edi, dword [ebp - 0xc]
mov ecx, dword [esp + 0x24]
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x30]
add esp, 0xc
add ebx, edi
inc eax
add ebp, 0xa14
cmp eax, ecx
mov dword [esp + 0x24], eax
jl 0x4016b7
mov ebp, dword [esp + 0x30]
mov esi, ecx
xor eax, eax
mov dword [esp + 0x28], eax
mov dword [esp + 0x34], eax
mov ecx, 0x285
xor eax, eax
lea edi, [esp + 0x48]
rep stosd dword es:[edi], eax
mov eax, dword [0x4ad780]
mov dword [esp + 0x48], 0xa14
mov dword [esp + 0x20], eax
mov ecx, dword [esp + 0x1c]
lea edx, [esp + 0x20]
push ecx
push str._s.xml
push edx
mov byte [esp + 0x12bc], 6
call fcn.00451685
mov eax, dword [esp + 0x2c]
lea ecx, [esp + 0x258]
push eax
push ecx
call fcn.0043f59c
mov ecx, dword [esp + 0x12e0]
add esp, 0x14
lea edx, [esp + 0x34]
lea eax, [esp + 0x28]
push edx
mov edx, dword [esp + 0x12cc]
push eax
mov eax, dword [esp + 0x12cc]
push ecx
mov ecx, dword [esp + 0x28]
push edx
mov edx, dword [esp + 0x12cc]
push eax
push ecx
push edx
mov ecx, ebp
call fcn.00402b00
test eax, eax
jne 0x40195a
mov eax, dword [0x4ad780]
mov dword [esp + 0x10], eax
lea ecx, [esp + 0x10]
push str.Set_xml_configure_file_failed_n
push ecx
mov byte [esp + 0x12b8], 7
call fcn.00451685
mov edx, dword [esp + 0x18]
add esp, 8
push 0
push 0
push edx
call fcn.0045f42f
lea ecx, [esp + 0x10]
mov byte [esp + 0x12b0], 6
call fcn.004584d6
jmp 0x401c1d
mov eax, dword [0x4ad780]
mov dword [esp + 0x14], eax
add esi, 0x204
lea ecx, [esp + 0x14]
push esi
push str.Can_not_open_file___s__n
push ecx
mov byte [esp + 0x12bc], 3
call fcn.00451685
mov edx, dword [esp + 0x20]
add esp, 0xc
push 0
push 0
push edx
call fcn.0045f42f
mov byte [esp + 0x12b0], 2
lea ecx, [esp + 0x14]
jmp 0x401c29
mov eax, dword [esp + 0x34]
lea ecx, [esp + 0x48]
push 0xa14
push ecx
lea ecx, [esp + 0x40]
mov dword [esp + 0x654], eax
mov dword [esp + 0x660], ebx
mov dword [esp + 0x658], 2
call fcn.004591ac
mov eax, dword [esp + 0x14]
lea edx, [esp + 0x48]
push 0xa14
push edx
push eax
call fcn.00406d00
add esp, 0xc
mov dword [esp + 0x14], eax
test esi, esi
mov dword [esp + 0x30], 0
jle 0x401ab9
mov ecx, dword [esp + 0x12c0]
lea edi, [ecx + 0x204]
mov dword [esp + 0x2c], edi
push edi
call fcn.0043f601
add esp, 4
test eax, eax
je 0x401a9e
push 0
push 0x80
push 3
push 0
push 1
push SysReAllocString
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [esp + 0x10], eax
je 0x401bc7
push 0xa00000
call fcn.00458a48
mov ebx, dword [edi + 0x400]
add esp, 4
test ebx, ebx
mov ebp, eax
mov esi, 0xa00000
mov dword [esp + 0x24], 0
jbe 0x401a86
mov ecx, 0x280000
xor eax, eax
mov edi, ebp
cmp ebx, 0xa00000
rep stosd dword es:[edi], eax
jae 0x401a38
mov esi, ebx
mov edi, dword [esp + 0x10]
lea edx, [esp + 0x24]
push 0
push edx
push esi
push ebp
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x401c0d
cmp dword [esp + 0x24], esi
jne 0x401c0d
push esi
push ebp
lea ecx, [esp + 0x40]
sub ebx, esi
call fcn.004591ac
mov eax, dword [esp + 0x14]
push esi
push ebp
push eax
call fcn.00406d00
add esp, 0xc
mov dword [esp + 0x14], eax
test ebx, ebx
ja 0x401a23
mov edi, dword [esp + 0x2c]
push ebp
call fcn.00458a71
mov ecx, dword [esp + 0x14]
add esp, 4
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, dword [esp + 0x18]
mov eax, dword [esp + 0x30]
add edi, 0xa14
inc eax
mov dword [esp + 0x2c], edi
cmp eax, esi
mov dword [esp + 0x30], eax
jl 0x4019c6
mov edx, dword [esp + 0x34]
mov eax, dword [esp + 0x28]
push edx
push eax
lea ecx, [esp + 0x40]
call fcn.004591ac
mov ecx, dword [esp + 0x34]
mov edx, dword [esp + 0x28]
mov eax, dword [esp + 0x14]
push ecx
push edx
push eax
call fcn.00406d00
mov esi, eax
mov eax, dword [esp + 0x34]
add esp, 0xc
test eax, eax
je 0x401afe
push eax
call fcn.00458a71
add esp, 4
mov dword [esp + 0x28], 0
lea ecx, [esp + 0x38]
call fcn.0045924f
mov edx, dword [esp + 0x38]
push 2
push 0
lea ecx, [esp + 0x40]
call dword [edx + 0x28]
mov dword [esp + 0xa8c], eax
lea eax, [esp + 0xa5c]
push 0x848
push eax
push 0
call fcn.00406d00
mov edx, dword [esp + 0x44]
add esp, 0xc
lea ecx, [esp + 0x38]
mov word [esp + 0x12a4], ax
push 0
push 0
mov word [esp + 0x12ae], si
call dword [edx + 0x28]
lea eax, [esp + 0xa5c]
push 0x84c
push eax
lea ecx, [esp + 0x40]
call fcn.004591ac
lea ecx, [esp + 0x38]
call fcn.0045924f
lea ecx, [esp + 0x20]
mov byte [esp + 0x12b0], 2
call fcn.004584d6
lea ecx, [esp + 0x1c]
mov byte [esp + 0x12b0], 1
call fcn.004584d6
lea ecx, [esp + 0x38]
mov byte [esp + 0x12b0], 0
call fcn.00458f98
mov dword [esp + 0x12b0], 0xffffffff
call fcn.00468777
mov ecx, dword [eax + 4]
call fcn.00457f99
mov eax, 1
jmp 0x401c73
mov edx, dword [0x4ad780]
mov dword [esp + 0x18], edx
push edi
lea eax, [esp + 0x1c]
push str.Can_not_open_file___s__n
push eax
mov byte [esp + 0x12bc], 8
call fcn.00451685
mov ecx, dword [esp + 0x24]
add esp, 0xc
push 0
push 0
push ecx
call fcn.0045f42f
lea ecx, [esp + 0x18]
mov byte [esp + 0x12b0], 6
call fcn.004584d6
jmp 0x401c1d
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebp
call fcn.00458a71
add esp, 4
mov byte [esp + 0x12b0], 2
lea ecx, [esp + 0x20]
call fcn.004584d6
lea ecx, [esp + 0x1c]
mov byte [esp + 0x12b0], 1
call fcn.004584d6
lea ecx, [esp + 0x38]
mov byte [esp + 0x12b0], 0
call fcn.00458f98
mov dword [esp + 0x12b0], 0xffffffff
jmp 0x401c64
mov dword [esp + 0x12b0], eax
call fcn.00468777
mov ecx, dword [eax + 4]
call fcn.00457f99
xor eax, eax
mov ecx, dword [esp + 0x12a8]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x12a4
ret 0x1c