Function at 0x40eea0
Capabilities:
Allocate or change rwx memory
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
push esi
sub esp, 0xa8
mov eax, dword [0x52f080]
xor eax, ebp
mov dword [ebp - 8], eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov dword [ebp - 0x60], eax
lea eax, [ebp - 0x14]
xor ecx, ecx
mov dword [esp], eax
mov dword [esp + 4], 0
mov dword [esp + 8], 0xc
call fcn.0041fb40
lea eax, str.ntdll.dll
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
sub esp, 4
mov dword [ebp - 0x64], eax
mov ecx, dword [ebp - 0x64]
mov edx, dword [ebp - 0x60]
lea eax, [ebp - 0x14]
mov dword [esp], edx
mov dword [esp + 4], ecx
mov dword [esp + 8], eax
mov dword [esp + 0xc], 0xc
call sub.KERNEL32.dll_K32GetModuleInformation
sub esp, 0x10
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x68], eax
lea eax, str.c:windows_system32_ntdll.dll
xor ecx, ecx
mov dword [esp], eax
mov dword [esp + 4], 0x80000000
mov dword [esp + 8], 1
mov dword [esp + 0xc], 0
mov dword [esp + 0x10], 3
mov dword [esp + 0x14], 0
mov dword [esp + 0x18], 0
call dword [sym.imp.KERNEL32.dll_CreateFileA]
sub esp, 0x1c
mov dword [ebp - 0x6c], eax
mov eax, dword [ebp - 0x6c]
xor ecx, ecx
mov dword [esp], eax
mov dword [esp + 4], 0
mov dword [esp + 8], 0x1000002
mov dword [esp + 0xc], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0x14], 0
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
sub esp, 0x18
mov dword [ebp - 0x70], eax
mov eax, dword [ebp - 0x70]
xor ecx, ecx
mov dword [esp], eax
mov dword [esp + 4], 4
mov dword [esp + 8], 0
mov dword [esp + 0xc], 0
mov dword [esp + 0x10], 0
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
sub esp, 0x14
mov dword [ebp - 0x5c], eax
mov dword [ebp - 0x8c], 0xc868c48d
mov eax, dword [ebp - 0x8c]
mov dword [ebp - 0x90], eax
sub eax, 0x9a55dffc
je 0x40f456
jmp 0x40eff6
mov eax, dword [ebp - 0x90]
sub eax, 0xa08c9205
je 0x40f1e0
jmp 0x40f00c
mov eax, dword [ebp - 0x90]
sub eax, 0xc0d48cdb
je 0x40f40d
jmp 0x40f022
mov eax, dword [ebp - 0x90]
sub eax, 0xc868c48d
je 0x40f171
jmp 0x40f038
mov eax, dword [ebp - 0x90]
sub eax, 0xe019c429
je 0x40f4a0
jmp 0x40f04e
mov eax, dword [ebp - 0x90]
sub eax, 0xe47c0d3f
je 0x40f482
jmp 0x40f064
mov eax, dword [ebp - 0x90]
sub eax, 0xeb85ac86
je 0x40f1c1
jmp 0x40f07a
mov eax, dword [ebp - 0x90]
sub eax, 0xfa9b7c39
je 0x40f355
jmp 0x40f090
mov eax, dword [ebp - 0x90]
sub eax, 0x1c6b583d
je 0x40f21b
jmp 0x40f0a6
mov eax, dword [ebp - 0x90]
sub eax, 0x203cf401
je 0x40f41c
jmp 0x40f0bc
mov eax, dword [ebp - 0x90]
sub eax, 0x33b48f30
je 0x40f433
jmp 0x40f0d2
mov eax, dword [ebp - 0x90]
sub eax, 0x3583d1eb
je 0x40f1f8
jmp 0x40f0e8
mov eax, dword [ebp - 0x90]
sub eax, 0x402e5b98
je 0x40f3bb
jmp 0x40f0fe
mov eax, dword [ebp - 0x90]
sub eax, 0x58e4d458
je 0x40f293
jmp 0x40f114
mov eax, dword [ebp - 0x90]
sub eax, 0x5d3c5bdf
je 0x40f1a6
jmp 0x40f12a
mov eax, dword [ebp - 0x90]
sub eax, 0x5dc0d520
je 0x40f25a
jmp 0x40f140
mov eax, dword [ebp - 0x90]
sub eax, 0x6da4747a
je 0x40f46d
jmp 0x40f156
mov eax, dword [ebp - 0x90]
sub eax, 0x7e386df1
je 0x40f2c3
jmp 0x40f16c
jmp 0x40f4e0
mov eax, dword [ebp - 0x5c]
mov dword [ebp - 0x74], eax
mov eax, dword [ebp - 0x68]
mov dword [ebp - 0x78], eax
mov eax, dword [ebp - 0x68]
mov ecx, dword [ebp - 0x78]
mov edx, dword [ecx + 0x3c]
xor ecx, ecx
sub ecx, eax
xor eax, eax
sub eax, edx
add ecx, eax
xor eax, eax
sub eax, ecx
mov dword [ebp - 0x58], eax
mov dword [ebp - 0x8c], 0x5d3c5bdf
jmp 0x40f4e0
mov eax, dword [ebp - 0x58]
mov dword [ebp - 0x7c], eax
mov word [ebp - 0x7e], 0
mov dword [ebp - 0x8c], 0xeb85ac86
jmp 0x40f4e0
movzx eax, word [ebp - 0x7e]
mov dword [ebp - 0x54], eax
mov eax, dword [ebp - 0x7c]
add eax, 4
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x8c], 0xa08c9205
jmp 0x40f4e0
mov eax, dword [ebp - 0x50]
add eax, 2
mov dword [ebp - 0x4c], eax
mov dword [ebp - 0x8c], 0x3583d1eb
jmp 0x40f4e0
mov eax, dword [ebp - 0x4c]
movzx esi, word [eax]
mov edx, dword [ebp - 0x54]
mov eax, 0x6da4747a
mov ecx, 0x1c6b583d
cmp edx, esi
cmovl eax, ecx
mov dword [ebp - 0x8c], eax
jmp 0x40f4e0
mov eax, dword [ebp - 0x7c]
add eax, 0x1ae0a04
add eax, 0x18
sub eax, 0x1ae0a04
mov ecx, dword [ebp - 0x7c]
movzx edx, word [ecx + 0x14]
xor ecx, ecx
sub ecx, eax
xor eax, eax
sub eax, edx
add ecx, eax
xor eax, eax
sub eax, ecx
mov dword [ebp - 0x48], eax
mov ax, word [ebp - 0x7e]
mov word [ebp - 0x42], ax
mov dword [ebp - 0x8c], 0x5dc0d520
jmp 0x40f4e0
mov ax, word [ebp - 0x42]
movzx eax, ax
imul edx, eax, 0x28
mov eax, dword [ebp - 0x48]
xor ecx, ecx
sub ecx, eax
xor eax, eax
sub eax, edx
add ecx, eax
xor eax, eax
sub eax, ecx
mov dword [ebp - 0x84], eax
mov eax, dword [ebp - 0x84]
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x8c], 0x58e4d458
jmp 0x40f4e0
mov ecx, dword [ebp - 0x40]
mov eax, esp
mov dword [eax], ecx
mov dword [eax + 4], 0x42ecb1
call fcn.00423440
mov edx, eax
mov eax, 0x7e386df1
mov ecx, 0xc0d48cdb
cmp edx, 0
cmovne eax, ecx
mov dword [ebp - 0x8c], eax
jmp 0x40f4e0
mov dword [ebp - 0x18], 0
mov eax, dword [ebp - 0x84]
mov ecx, dword [eax + 8]
mov edx, dword [ebp - 0x68]
mov eax, dword [ebp - 0x84]
mov esi, dword [eax + 0xc]
xor eax, eax
sub eax, edx
xor edx, edx
sub edx, esi
add eax, edx
xor edx, edx
sub edx, eax
lea eax, [ebp - 0x18]
mov dword [esp], edx
mov dword [esp + 4], ecx
mov dword [esp + 8], 0x40
mov dword [esp + 0xc], eax
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
sub esp, 0x10
cmp eax, 0
setne al
and al, 1
mov byte [ebp - 0x85], al
mov eax, dword [ebp - 0x68]
mov ecx, dword [ebp - 0x84]
mov edx, dword [ecx + 0xc]
xor ecx, ecx
sub ecx, eax
xor eax, eax
sub eax, edx
add ecx, eax
xor eax, eax
sub eax, ecx
mov dword [ebp - 0x3c], eax
mov eax, dword [ebp - 0x74]
mov dword [ebp - 0x38], eax
mov eax, dword [ebp - 0x84]
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x8c], 0xfa9b7c39
jmp 0x40f4e0
mov eax, dword [ebp - 0x34]
mov eax, dword [eax + 0xc]
mov ecx, dword [ebp - 0x38]
add ecx, 0x45e6f653
add ecx, eax
sub ecx, 0x45e6f653
mov eax, dword [ebp - 0x84]
mov eax, dword [eax + 8]
mov edx, dword [ebp - 0x3c]
mov dword [esp], edx
mov dword [esp + 4], ecx
mov dword [esp + 8], eax
call fcn.0041fca0
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x30], eax
mov eax, dword [ebp - 0x84]
mov eax, dword [eax + 8]
mov dword [ebp - 0x2c], eax
mov eax, dword [ebp - 0x68]
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x84]
mov eax, dword [eax + 0xc]
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x8c], 0x402e5b98
jmp 0x40f4e0
mov esi, dword [ebp - 0x28]
mov eax, dword [ebp - 0x24]
sub esi, 0x68edf0f
add esi, eax
add esi, 0x68edf0f
mov ecx, dword [ebp - 0x30]
mov edx, dword [ebp - 0x2c]
lea eax, [ebp - 0x18]
mov dword [esp], esi
mov dword [esp + 4], edx
mov dword [esp + 8], ecx
mov dword [esp + 0xc], eax
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
sub esp, 0x10
cmp eax, 0
setne al
and al, 1
mov byte [ebp - 0x85], al
mov dword [ebp - 0x8c], 0xc0d48cdb
jmp 0x40f4e0
mov dword [ebp - 0x8c], 0x203cf401
jmp 0x40f4e0
mov ax, word [ebp - 0x7e]
mov word [ebp - 0x20], ax
mov dword [ebp - 0x8c], 0x33b48f30
jmp 0x40f4e0
mov ax, word [ebp - 0x20]
add ax, 0x9dd5
add ax, 1
sub ax, 0x9dd5
mov word [ebp - 0x1e], ax
mov dword [ebp - 0x8c], 0x9a55dffc
jmp 0x40f4e0
mov ax, word [ebp - 0x1e]
mov word [ebp - 0x7e], ax
mov dword [ebp - 0x8c], 0xeb85ac86
jmp 0x40f4e0
mov eax, dword [ebp - 0x60]
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x8c], 0xe47c0d3f
jmp 0x40f4e0
mov eax, dword [ebp - 0x1c]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esp, 4
mov dword [ebp - 0x8c], 0xe019c429
jmp 0x40f4e0
mov eax, dword [ebp - 0x6c]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esp, 4
mov eax, dword [ebp - 0x70]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esp, 4
mov eax, dword [ebp - 0x64]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
sub esp, 4
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0041ee50
add esp, 0xa8
pop esi
pop ebp
ret
jmp 0x40efda