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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x638
mov eax, dword [0x4ca008]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov eax, ecx
lea ecx, [ebp - 0x20c]
push 0x104
push ecx
push eax
mov dword [ebp - 0x624], eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecA]
mov ebx, dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x310]
push str._sdllRESOURCE.dll
push eax
call ebx
add esp, 0xc
lea eax, [ebp - 0x310]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
test eax, eax
je 0x45cb61
push eax
lea edx, [ebp - 0x108]
mov ecx, 0x4cd124
call fcn.0045c810
add esp, 4
test eax, eax
je 0x45cb61
xor edx, edx
lea ecx, [ebp - 0x100]
call fcn.004642c0
xor edx, edx
mov dword [ebp - 0x630], eax
lea ecx, [ebp - 0x108]
mov byte [ebp - 0x100], 0
call fcn.004642c0
mov dword [ebp - 0x62c], eax
lea eax, [ebp - 0x20c]
push 0x4cd124
push eax
lea eax, [ebp - 0x310]
push str._s_s
push eax
call ebx
add esp, 0x10
lea eax, [ebp - 0x310]
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
je 0x45cb61
push 0
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
push 0
push ebx
call dword [sym.imp.PAL.dll_PalMemoryAlloc]
mov esi, eax
add esp, 8
test esi, esi
je 0x45cb5a
push 0
lea eax, [ebp - 0x634]
push eax
push ebx
push esi
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x45cb74
push esi
call dword [sym.imp.PAL.dll_PalMemoryFree]
add esp, 4
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00467358
mov esp, ebp
pop ebp
ret
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor edx, edx
xor eax, eax
xor ecx, ecx
mov dword [ebp - 0x628], edx
mov dword [ebp - 0x620], eax
test ebx, ebx
je 0x45cbb6
test cl, 3
jne 0x45cb9f
xor eax, dword [ecx + esi]
mov dword [ebp - 0x620], eax
movzx eax, byte [ecx + esi]
inc ecx
add edx, eax
mov eax, dword [ebp - 0x620]
cmp ecx, ebx
jne 0x45cb91
mov dword [ebp - 0x628], edx
push esi
call dword [sym.imp.PAL.dll_PalMemoryFree]
add esp, 4
lea eax, [ebp - 0x518]
push 0x104
push eax
push dword [ebp - 0x624]
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [ebp - 0x518]
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecA]
lea eax, [ebp - 0x518]
push eax
lea eax, [ebp - 0x61c]
push str._sdllRESOURCE.dll
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
lea eax, [ebp - 0x61c]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
test eax, eax
je 0x45cb61
push eax
lea edx, [ebp - 0x414]
mov ecx, str.RESOURCE.dll
call fcn.0045c810
add esp, 4
test eax, eax
je 0x45cb61
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
lea eax, [ebp - 0x61c]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
je 0x45cb61
push 0
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
push 0
push ebx
mov dword [ebp - 0x624], ebx
call dword [sym.imp.PAL.dll_PalMemoryAlloc]
mov esi, eax
add esp, 8
test esi, esi
je 0x45cca0
push 0
lea eax, [ebp - 0x638]
push eax
push ebx
push esi
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x45ccbb
mov eax, dword [sym.imp.PAL.dll_PalMemoryFree]
push esi
call eax
add esp, 4
mov eax, dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call eax
pop edi
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00467358
mov esp, ebp
pop ebp
ret
mov eax, dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call eax
mov edx, dword [ebp - 0x624]
xor ecx, ecx
xor ebx, ebx
xor edi, edi
test edx, edx
je 0x45ccfb
cmp dword [ebp - 0x410], ecx
jne 0x45cce2
mov eax, 0xc
jmp 0x45ccf5
test cl, 3
jne 0x45ccea
xor edi, dword [ecx + esi]
movzx eax, byte [ecx + esi]
add ebx, eax
mov eax, 1
add ecx, eax
cmp edx, ecx
ja 0x45ccd3
mov eax, dword [sym.imp.PAL.dll_PalMemoryFree]
push esi
call eax
add esp, 4
cmp dword [ebp - 0x40c], ebx
jne 0x45cb61
cmp dword [ebp - 0x408], edi
jne 0x45cb61
mov eax, dword [ebp - 0x62c]
mov dword [0x4cce10], 1
cmp eax, dword [ebp - 0x628]
jne 0x45cb61
mov eax, dword [ebp - 0x630]
cmp eax, dword [ebp - 0x620]
jne 0x45cb61
mov ecx, dword [ebp - 4]
mov eax, 1
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00467358
mov esp, ebp
pop ebp
ret