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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x638
mov eax, dword [0x4cf008]
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 0x462211
push eax
lea edx, [ebp - 0x108]
mov ecx, 0x4d21f4
call fcn.00461ec0
add esp, 4
test eax, eax
je 0x462211
xor edx, edx
lea ecx, [ebp - 0x100]
call fcn.00469ae0
xor edx, edx
mov dword [ebp - 0x630], eax
lea ecx, [ebp - 0x108]
mov byte [ebp - 0x100], 0
call fcn.00469ae0
mov dword [ebp - 0x62c], eax
lea eax, [ebp - 0x20c]
push 0x4d21f4
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 0x462211
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 0x46220a
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 0x462224
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.0046ccad
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 0x462266
test cl, 3
jne 0x46224f
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 0x462241
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 0x462211
push eax
lea edx, [ebp - 0x414]
mov ecx, str.RESOURCE.dll
call fcn.00461ec0
add esp, 4
test eax, eax
je 0x462211
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 0x462211
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 0x462350
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 0x46236b
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.0046ccad
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 0x4623ab
cmp dword [ebp - 0x410], ecx
jne 0x462392
mov eax, 0xc
jmp 0x4623a5
test cl, 3
jne 0x46239a
xor edi, dword [ecx + esi]
movzx eax, byte [ecx + esi]
add ebx, eax
mov eax, 1
add ecx, eax
cmp edx, ecx
ja 0x462383
mov eax, dword [sym.imp.PAL.dll_PalMemoryFree]
push esi
call eax
add esp, 4
cmp dword [ebp - 0x40c], ebx
jne 0x462211
cmp dword [ebp - 0x408], edi
jne 0x462211
mov eax, dword [ebp - 0x62c]
mov dword [0x4d1ee0], 1
cmp eax, dword [ebp - 0x628]
jne 0x462211
mov eax, dword [ebp - 0x630]
cmp eax, dword [ebp - 0x620]
jne 0x462211
mov ecx, dword [ebp - 4]
mov eax, 1
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0046ccad
mov esp, ebp
pop ebp
ret