Function at 0x1004dc00
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10121bd0
mov eax, dword fs:[0]
push eax
sub esp, 0x58
mov eax, dword [0x1016e750]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x58], edx
mov ebx, ecx
mov eax, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
mov esi, dword [ebp + 0x14]
mov dword [ebp - 0x60], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x64], eax
mov eax, dword [ebp + 0x18]
mov dword [ebp - 0x5c], eax
xor eax, eax
push 0x3e
push eax
mov word [ebp - 0x54], ax
lea eax, [ebp - 0x52]
push eax
call fcn.101078f0
add esp, 0xc
lea eax, [ebp - 0x54]
push 0
push 0x40
push eax
push dword [ebp - 0x58]
push ebx
call dword [sym.imp.KERNEL32.dll_ReadProcessMemory]
test eax, eax
jne 0x1004dcce
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp - 0x58]
lea eax, [ebp - 0x5c]
push ebx
push str._GetProcessPeHeaders:_out._Failed_reading_IMAGE_DOS_HEADER__hProcess_x__ImageBase_x__LE_d
push eax
call fcn.10044f30
add esp, 0x14
mov dword [ebp - 4], 0
mov ecx, str.ProcessHelper
mov edx, dword [ebp - 0x5c]
call fcn.10043b30
mov dword [ebp - 4], 0xffffffff
mov edx, dword [ebp - 0x5c]
add edx, 0xfffffff0
or ecx, 0xffffffff
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x1004dcc7
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
xor eax, eax
jmp 0x1004ddcf
mov eax, 0x5a4d
cmp word [ebp - 0x54], ax
je 0x1004dd0a
lea eax, [ebp - 0x58]
push str._GetProcessPeHeaders:_out._Failed:_this_is_not_an_MZ_file_
push eax
call fcn.10044f30
add esp, 8
mov dword [ebp - 4], 1
mov ecx, str.ProcessHelper
mov edx, dword [ebp - 0x58]
call fcn.10043b30
mov dword [ebp - 4], 0xffffffff
mov edx, dword [ebp - 0x58]
jmp 0x1004dcad
mov eax, dword [ebp - 0x18]
mov ecx, dword [ebp - 0x58]
push 0
push 0xf8
mov dword [esi], eax
add eax, ecx
push edi
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadProcessMemory]
test eax, eax
jne 0x1004dd4f
call dword [sym.imp.KERNEL32.dll_GetLastError]
push ecx
mov ecx, esp
push eax
push str._GetProcessPeHeaders:_out._Failed_reading_IMAGE_NT_HEADERS32__LE_d
push ecx
call fcn.10044f30
add esp, 0xc
call fcn.1004d450
add esp, 4
xor eax, eax
jmp 0x1004ddcf
cmp dword [edi], 0x4550
je 0x1004dd74
push ecx
mov eax, esp
push str._GetProcessPeHeaders:_out._Failed:_this_is_not_a_PE_file_
push eax
call fcn.10044f30
add esp, 8
call fcn.1004d450
add esp, 4
xor eax, eax
jmp 0x1004ddcf
mov eax, dword [esi]
add eax, dword [ebp - 0x58]
push 0
push 0x108
push dword [ebp - 0x64]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadProcessMemory]
test eax, eax
jne 0x1004dda0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push ecx
mov ecx, esp
push eax
push str._GetProcessPeHeaders:_out._Failed_reading_IMAGE_NT_HEADERS64__LE_d
jmp 0x1004dd37
xor eax, eax
mov ecx, 0x20b
cmp word [edi + 0x18], cx
mov ecx, dword [ebp - 0x60]
sete al
test eax, eax
mov dword [ecx], eax
mov ecx, dword [ebp - 0x5c]
mov eax, dword [esi]
je 0x1004ddc3
add eax, 0x108
jmp 0x1004ddc8
add eax, 0xf8
mov dword [ecx], eax
mov eax, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.10103392
mov esp, ebp
pop ebp
ret