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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x84
mov dword [ebp - 8], 0x4d9b6c
push 0
push 0
mov eax, dword [ebp - 8]
push dword [eax + 0x34]
call dword [sym.imp.kernel32.dll_LoadLibraryExW]
mov dword [ebp - 0x4c], eax
mov eax, dword [ebp - 8]
push dword [eax + 0x24]
push 0x40
call dword [sym.imp.kernel32.dll_LocalAlloc]
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 8]
push dword [eax + 0x24]
push dword [ebp - 0x14]
call fcn.004d30c6
pop ecx
pop ecx
push 0x104
push dword [ebp - 0x14]
push 0
call dword [sym.imp.kernel32.dll_GetModuleFileNameW]
mov eax, dword [ebp - 8]
mov eax, dword [eax + 0x38]
mov dword [ebp - 0x44], eax
and dword [ebp - 0x1c], 0
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x14]
movzx eax, word [ecx + eax*2]
test eax, eax
je 0x4d31ad
mov eax, dword [ebp - 0x1c]
inc eax
mov dword [ebp - 0x1c], eax
jmp 0x4d3196
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
mov ecx, dword [ebp - 0x14]
movzx eax, word [ecx + eax*2 - 2]
cmp eax, 0x5c
je 0x4d31d8
xor eax, eax
mov ecx, dword [ebp - 0x10]
mov edx, dword [ebp - 0x14]
mov word [edx + ecx*2], ax
mov eax, dword [ebp - 0x10]
dec eax
mov dword [ebp - 0x10], eax
jmp 0x4d31b3
and dword [ebp - 0x20], 0
mov eax, dword [ebp - 0x44]
add eax, dword [ebp - 0x20]
movsx eax, byte [eax]
test eax, eax
je 0x4d320d
mov eax, dword [ebp - 0x44]
add eax, dword [ebp - 0x20]
movsx ax, byte [eax]
mov ecx, dword [ebp - 0x10]
mov edx, dword [ebp - 0x14]
mov word [edx + ecx*2], ax
mov eax, dword [ebp - 0x10]
inc eax
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x20]
inc eax
mov dword [ebp - 0x20], eax
jmp 0x4d31dc
push 0
push 0x80
push 3
push 0
push 1
push 1
push dword [ebp - 0x14]
call dword [sym.imp.kernel32.dll_CreateFileW]
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0xffffffff
jne 0x4d3233
jmp 0x4d344f
push 0
push dword [ebp - 0x30]
call dword [sym.imp.kernel32.dll_GetFileSize]
mov dword [ebp - 0x5c], eax
push 4
push 0x1000
mov eax, dword [ebp - 8]
push dword [eax + 0x30]
push 0
call dword [sym.imp.kernel32.dll_VirtualAlloc]
mov dword [ebp - 4], eax
and dword [ebp - 0x48], 0
push 0
lea eax, [ebp - 0x48]
push eax
push dword [ebp - 0x5c]
push dword [ebp - 4]
push dword [ebp - 0x30]
call dword [sym.imp.kernel32.dll_ReadFile]
test eax, eax
jne 0x4d327b
jmp 0x4d344f
mov eax, dword [ebp - 4]
add eax, dword [ebp - 0x48]
mov dword [ebp - 0x40], eax
mov eax, dword [ebp - 8]
mov eax, dword [eax + 0x44]
add eax, dword [ebp - 4]
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0xc]
mov eax, dword [eax]
mov dword [ebp - 0x60], eax
mov eax, dword [ebp - 0xc]
add eax, 4
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0xc]
mov eax, dword [eax]
mov dword [ebp - 0x64], eax
mov eax, dword [ebp - 0xc]
add eax, 4
mov dword [ebp - 0xc], eax
and dword [ebp - 0x34], 0
jmp 0x4d32ce
mov eax, dword [ebp - 0x34]
inc eax
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 0xc]
add eax, 4
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x34]
cmp eax, dword [ebp - 0x60]
jae 0x4d32e5
mov eax, dword [ebp - 0xc]
mov eax, dword [eax]
add eax, dword [ebp - 0x64]
mov ecx, dword [ebp - 0xc]
mov dword [ecx], eax
jmp 0x4d32be
mov eax, dword [ebp - 8]
mov eax, dword [eax + 4]
add eax, dword [ebp - 4]
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
inc eax
push eax
push dword [ebp - 0x4c]
call dword [sym.imp.kernel32.dll_GetProcAddress]
mov dword [ebp - 0x50], eax
cmp dword [ebp - 0x50], 0
jne 0x4d330d
jmp 0x4d344f
mov eax, dword [ebp - 4]
movsx eax, byte [eax]
add eax, dword [ebp - 4]
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
inc eax
push eax
push dword [ebp - 0x4c]
call dword [sym.imp.kernel32.dll_GetProcAddress]
mov dword [ebp - 0x3c], eax
cmp dword [ebp - 0x3c], 0
jne 0x4d3335
jmp 0x4d344f
mov eax, dword [ebp - 4]
movsx eax, byte [eax]
add eax, dword [ebp - 4]
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
inc eax
push eax
call dword [ebp - 0x50]
mov dword [ebp - 0x24], eax
cmp dword [ebp - 0x24], 0
jne 0x4d3357
jmp 0x4d344f
mov eax, dword [ebp - 4]
movsx eax, byte [eax]
add eax, dword [ebp - 4]
mov dword [ebp - 4], eax
mov eax, dword [ebp - 8]
mov eax, dword [eax + 0xc]
add eax, dword [ebp - 4]
mov dword [ebp - 0x58], eax
mov eax, dword [ebp - 4]
mov dword [ebp - 0x54], eax
mov eax, dword [ebp - 0x54]
mov eax, dword [eax + 4]
mov dword [ebp - 0x6c], eax
mov eax, dword [ebp - 0x54]
mov eax, dword [eax + 8]
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x58]
add eax, dword [ebp - 0x28]
mov dword [ebp - 0x70], eax
mov eax, dword [ebp - 0x24]
mov ecx, dword [ebp - 0x24]
add ecx, dword [eax + 0x3c]
mov dword [ebp - 0x68], ecx
mov eax, dword [ebp - 0x68]
mov ecx, dword [ebp - 0x24]
add ecx, dword [eax + 0x2c]
mov dword [ebp - 0x2c], ecx
and dword [ebp - 0x38], 0
lea eax, [ebp - 0x38]
push eax
mov eax, dword [ebp - 8]
push dword [eax + 0x40]
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
call dword [ebp - 0x3c]
push dword [ebp - 0x28]
push dword [ebp - 0x58]
push dword [ebp - 0x2c]
call fcn.004d30f8
add esp, 0xc
lea eax, [ebp - 0x38]
push eax
push dword [ebp - 0x38]
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
call dword [ebp - 0x3c]
mov eax, dword [ebp - 0x2c]
add eax, dword [ebp - 0x6c]
mov dword [ebp - 0x74], eax
and dword [ebp - 0x18], 0
mov eax, dword [ebp - 8]
mov eax, dword [eax + 0x3c]
mov ecx, dword [ebp - 0x18]
movsx eax, byte [eax + ecx]
test eax, eax
je 0x4d341f
mov eax, dword [ebp - 8]
mov eax, dword [eax + 0x3c]
mov ecx, dword [ebp - 0x18]
movsx ax, byte [eax + ecx]
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x40]
mov word [edx + ecx*2], ax
mov eax, dword [ebp - 0x18]
inc eax
mov dword [ebp - 0x18], eax
jmp 0x4d33ed
xor eax, eax
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x40]
mov word [edx + ecx*2], ax
mov eax, dword [ebp - 0x40]
mov dword [ebp - 0x80], eax
mov eax, dword [ebp - 0x70]
mov dword [ebp - 0x84], eax
mov byte [ebp - 0x7c], 1
mov eax, dword [ebp - 0x74]
mov dword [ebp - 0x78], eax
lea eax, [ebp - 0x84]
push eax
call dword [ebp - 0x78]
pop ecx
leave
ret