Function at 0x4654f8
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call
Parse pe header

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffeb0
push ebx
push esi
push edi
mov byte [ebp - 2], cl
mov byte [ebp - 1], dl
mov ebx, eax
xor eax, eax
mov dword [ebp - 0xc], eax
xor eax, eax
mov dword [ebp - 8], eax
xor edx, edx
push ebp
push 0x465775
push dword fs:[edx]
mov dword fs:[edx], esp
lea eax, [ebp - 0x58]
mov ecx, 0x40
mov edx, ebx
call fcn.00408540
cmp word [ebp - 0x58], 0x5a4d
je 0x465557
mov eax, 0x497fa8
mov edx, 0x4657a8
call fcn.004056b8
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x465794
mov eax, dword [ebp - 0x1c]
cdq
push edx
push eax
mov eax, ebx
call fcn.00464d28
mov edx, eax
lea eax, [ebp - 0x150]
mov ecx, 0xf8
call fcn.00408540
cmp dword [ebp - 0x150], 0x4550
je 0x46559e
mov eax, 0x497fa8
mov edx, 0x4657e0
call fcn.004056b8
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x465794
push 0x40
push 0x2000
mov eax, dword [ebp - 0x100]
push eax
mov eax, dword [ebp - 0x11c]
push eax
call sub.KERNEL32.DLL_VirtualAlloc
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
jne 0x4655d9
push 0x40
push 0x2000
mov eax, dword [ebp - 0x100]
push eax
push 0
call sub.KERNEL32.DLL_VirtualAlloc
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
jne 0x4655fb
mov eax, 0x497fa8
mov edx, 0x46581c
call fcn.004056b8
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x465794
push 0x11
push 0
call sub.KERNEL32.DLL_GetProcessHeap
push eax
call sub.KERNEL32.DLL_HeapAlloc_1
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0xc]
mov edx, dword [ebp - 0x10]
mov dword [eax + 4], edx
mov eax, dword [ebp - 0xc]
xor edx, edx
mov dword [eax + 0xc], edx
mov eax, dword [ebp - 0xc]
xor edx, edx
mov dword [eax + 8], edx
mov eax, dword [ebp - 0xc]
mov byte [eax + 0x10], 0
push 0x40
push 0x1000
mov eax, dword [ebp - 0x100]
push eax
mov eax, dword [ebp - 0x10]
push eax
call sub.KERNEL32.DLL_VirtualAlloc
push 0x40
push 0x1000
mov eax, dword [ebp - 0xfc]
push eax
mov eax, dword [ebp - 0x10]
push eax
call sub.KERNEL32.DLL_VirtualAlloc
mov dword [ebp - 0x14], eax
mov ecx, dword [ebp - 0x1c]
add ecx, dword [ebp - 0xfc]
mov edx, ebx
mov eax, dword [ebp - 0x14]
call fcn.00408540
mov eax, dword [ebp - 0x14]
xor edx, edx
push edx
push eax
mov eax, dword [ebp - 0x1c]
cdq
add eax, dword [esp]
adc edx, dword [esp + 4]
add esp, 8
mov ecx, eax
mov eax, dword [ebp - 0xc]
mov dword [eax], ecx
mov eax, dword [ebp - 0x10]
mov dword [ecx + 0x34], eax
mov ecx, dword [ebp - 0xc]
lea edx, [ebp - 0x150]
mov eax, ebx
call fcn.00464e40
mov eax, dword [ebp - 0x10]
xor edx, edx
push edx
push eax
mov eax, dword [ebp - 0x11c]
xor edx, edx
sub dword [esp], eax
sbb dword [esp + 4], edx
pop eax
pop edx
test eax, eax
je 0x4656c9
push eax
mov eax, dword [ebp - 0xc]
push eax
call fcn.00464f4c
mov eax, dword [ebp - 0xc]
push eax
call fcn.00465048
test al, al
jne 0x4656ea
mov eax, 0x497fa8
mov edx, 0x46584c
call fcn.00405948
call fcn.0040ec34
mov al, byte [ebp - 1]
push eax
mov eax, dword [ebp - 0xc]
push eax
call fcn.004653c0
mov eax, dword [ebp - 0xc]
mov eax, dword [eax]
mov ecx, dword [eax + 0x28]
test ecx, ecx
je 0x46576b
mov eax, dword [ebp - 0x10]
xor edx, edx
push edx
push eax
mov eax, ecx
xor edx, edx
add eax, dword [esp]
adc edx, dword [esp + 4]
add esp, 8
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
jne 0x465735
mov eax, 0x497fa8
mov edx, 0x465884
call fcn.004056b8
call fcn.0040ec34
cmp byte [ebp - 2], 0
je 0x465764
push 0
push 1
mov eax, dword [ebp - 0x10]
push eax
call dword [ebp - 0x18]
cmp eax, 1
sbb eax, eax
inc eax
test al, al
jne 0x465764
mov eax, 0x497fa8
mov edx, 0x4658b8
call fcn.004056b8
call fcn.0040ec34
mov eax, dword [ebp - 0xc]
mov byte [eax + 0x10], 1
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x46578e
mov eax, dword [ebp - 0xc]
mov dword [ebp - 8], eax
mov eax, dword [ebp - 8]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8