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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x7a8f36
mov eax, dword fs:[0]
push eax
sub esp, 0x1ec
mov eax, dword [0x8cf144]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x1f8], ecx
call fcn.00402330
mov eax, dword [0x8d1678]
test eax, eax
jne 0x5241b7
push 0x3c0
call fcn.006e611b
add esp, 4
mov dword [ebp - 0x1e8], eax
mov dword [ebp - 4], 0
test eax, eax
je 0x5241a9
mov ecx, eax
call fcn.00501cb0
jmp 0x5241ab
xor eax, eax
mov dword [ebp - 4], 0xffffffff
mov dword [0x8d1678], eax
lea ecx, [ebp - 0x1e4]
push ecx
mov ecx, eax
call fcn.00502aa0
xor edi, edi
mov dword [ebp - 4], 1
push edi
push 0x80
push 4
push edi
xor esi, esi
lea eax, [ebp - 0x1e4]
cmp dword [ebp - 0x1d0], 8
push 1
cmovae eax, dword [ebp - 0x1e4]
push SysReAllocString
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x524250
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
lea eax, [esi + 1]
push eax
call fcn.006e619d
mov edi, eax
add esp, 4
test edi, edi
je 0x524249
call fcn.00402330
lea eax, [esi + 1]
push eax
push 0
push edi
call fcn.007512b0
add esp, 0xc
call fcn.00402330
push 0
lea eax, [ebp - 0x1e8]
push eax
push esi
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call fcn.00402330
cmp esi, 0x100000
jg 0x524365
mov dword [ebp - 0x1f4], 0
mov dword [ebp - 0x1f0], 0
mov dword [ebp - 0x1ec], 0
mov ecx, 0x68
mov byte [ebp - 4], 2
mov esi, str.R1CKyMoD3G0pTaWuCWpkghHIyxIf0hbtkTuTXz7RUUZpcuUMc53nctTkjglTlUOJyxGoIi54y2xpFqf0W5Mh1qo1TVG0cV9Q6dekwVQRDrYB6UNJWp21QLHQybHPRyMHcugU3Exbi2uB1vqNTxkOk2Y7vlGJMe1RterskuS1TtbiM2itZyc5Tganc4jk2NwjPfyPh9lPDnomse2GIiI7KUkTDrR15HkCjTP84q929B35fxi5vBZQ3mGjRMs3TXRi2O7uHgsrZZSS9UwbUvVVvhxEzc8NV3WOO5qIWpawF0acdotMJRYpMiApV8ogR4XbzixQa5LbvUxiRVeZERgf6wwRf1uWD5bTNhfXf6h67XttRbjd7gfoXgQV8KEqptfbHNeSXhw0prIwZ4kCqfzAZC6lvbfJJ3UY
mov dword [ebp - 0x1b8], 0xf
lea edi, [ebp - 0x1b4]
mov dword [ebp - 0x1bc], 0
rep movsd dword es:[edi], dword [esi]
mov byte [ebp - 0x1cc], 0
movsb byte es:[edi], byte [esi]
cmp byte [ebp - 0x1b4], 0
jne 0x5242be
xor ecx, ecx
jmp 0x5242d0
lea ecx, [ebp - 0x1b4]
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x5242c7
sub ecx, edx
push ecx
lea eax, [ebp - 0x1b4]
push eax
lea ecx, [ebp - 0x1cc]
call fcn.00407c40
lea eax, [ebp - 0x1cc]
mov byte [ebp - 4], 3
push eax
lea ecx, [ebp - 0x1f4]
call fcn.00407ea0
mov eax, dword [ebp - 0x1b8]
cmp eax, 0x10
jb 0x524317
inc eax
lea ecx, [ebp - 0x1cc]
push eax
push dword [ebp - 0x1cc]
call fcn.00407d40
mov esi, dword [ebp - 0x1f4]
test esi, esi
je 0x524383
push dword [ebp - 0x1e8]
lea eax, [ebp - 0x1f4]
push eax
push dword [ebp - 0x1f0]
push esi
call fcn.004058d0
mov ecx, dword [ebp - 0x1ec]
mov eax, 0x2aaaaaab
sub ecx, esi
add esp, 0x10
imul ecx
lea ecx, [ebp - 0x1f4]
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
push eax
push esi
call fcn.00407da0
jmp 0x524383
call fcn.006f2812
mov ecx, dword [ebp - 0x1f8]
cmp dword [ecx + 0x28], 8
lea eax, [ecx + 0x14]
jb 0x52437b
mov eax, dword [eax]
push esi
push edi
push eax
call fcn.00525b20
mov eax, dword [ebp - 0x1d0]
cmp eax, 8
jb 0x5243a1
inc eax
lea ecx, [ebp - 0x1e4]
push eax
push dword [ebp - 0x1e4]
call fcn.00402920
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.006e615c
mov esp, ebp
pop ebp
ret