Function at 0x429751
Capabilities:
Access peb ldr_data
Create thread
Parse pe header

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
push ebx
push esi
push edi
push 0x8003
call dword [sym.imp.KERNEL32.dll_SetErrorMode]
mov edi, dword [ebp + 8]
mov eax, 0x5a4d
cmp word [edi], ax
je 0x429787
mov dword [ebp + 8], str.Wrong_PE_file
push 0x44d6fc
lea eax, [ebp + 8]
push eax
call fcn.004122ab
mov eax, dword [edi + 0x3c]
lea ebx, [eax + edi]
cmp dword [ebx], 0x4550
je 0x4297a6
mov dword [ebp - 0x10], str.Wrong_PE_signature
push 0x44d6fc
lea eax, [ebp - 0x10]
jmp 0x429781
mov eax, 0x10b
cmp word [ebx + 0x18], ax
je 0x4297c2
mov dword [ebp - 0xc], str.Not_normal_PE_format
push 0x44d6fc
lea eax, [ebp - 0xc]
jmp 0x429781
movzx eax, word [ebx + 6]
mov esi, dword [ebx + 0x34]
and dword [ebp - 8], 0
mov dword [ebp - 0x1c], esi
test eax, eax
jle 0x4297ef
lea ecx, [ebx + 0x100]
mov edx, eax
mov eax, dword [ecx + 4]
add eax, dword [ecx]
cmp dword [ebp - 8], eax
jae 0x4297e9
mov dword [ebp - 8], eax
add ecx, 0x28
dec edx
jne 0x4297dc
cmp dword [ebx + 0xa4], 0
push 0x40
push 0x3000
push dword [ebp - 8]
je 0x429827
push 0
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov esi, eax
mov dword [ebp - 4], esi
test esi, esi
jne 0x429849
mov dword [ebp - 4], str.error_allocating_virtual_memory
push 0x44d6fc
lea eax, [ebp - 4]
jmp 0x429781
push esi
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
test eax, eax
jne 0x429846
mov dword [ebp - 0x14], str.error_allocating_virtual_memory
push 0x44d6fc
lea eax, [ebp - 0x14]
jmp 0x429781
mov dword [ebp - 4], esi
movzx eax, word [ebx + 6]
mov ecx, dword [edi + 0x3c]
imul eax, eax, 0x28
lea eax, [eax + ecx + 0xf8]
push eax
push edi
push esi
call fcn.00413300
xor edi, edi
xor eax, eax
add esp, 0xc
mov dword [ebp - 0xc], edi
cmp ax, word [ebx + 6]
jae 0x4298a0
lea edi, [ebx + 0x10c]
mov eax, dword [edi]
add eax, dword [ebp + 8]
push dword [edi - 4]
push eax
mov eax, dword [edi - 8]
add eax, esi
push eax
call fcn.00413300
movzx eax, word [ebx + 6]
add esp, 0xc
inc dword [ebp - 0xc]
add edi, 0x28
cmp dword [ebp - 0xc], eax
jl 0x429878
xor edi, edi
cmp dword [ebx + 0x84], edi
je 0x429974
push edi
push edi
push 0x40000
call dword [sym.imp.KERNEL32.dll_HeapCreate]
mov dword [ebp - 0x18], eax
cmp eax, edi
jne 0x4298d4
mov dword [ebp - 0x18], str.error_creating_executable_heap
push 0x44d6fc
lea eax, [ebp - 0x18]
jmp 0x429781
mov edi, dword [ebx + 0x80]
add edi, esi
jmp 0x429969
mov eax, dword [edi + 0xc]
add eax, esi
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov dword [ebp - 0xc], eax
mov eax, dword [edi + 0x10]
add eax, esi
mov esi, dword [edi]
add esi, dword [ebp - 4]
mov dword [ebp + 8], eax
jmp 0x42995d
jns 0x429908
and eax, 0xffff
jmp 0x429910
mov ecx, dword [ebp - 4]
add eax, ecx
add eax, 2
push eax
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0xc
push 0
push dword [ebp - 0x18]
mov dword [ebp - 0x10], eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
test eax, eax
je 0x429a08
mov ecx, dword [ebp - 0x10]
mov edx, 0xdeadbeaf
xor ecx, edx
mov dword [eax + 1], ecx
mov ecx, dword [ebp + 8]
mov byte [eax], 0xb8
mov byte [eax + 5], 0x35
mov dword [eax + 6], edx
mov byte [eax + 0xa], 0xff
mov byte [eax + 0xb], 0xe0
add esi, 4
add dword [ebp + 8], 4
mov dword [ecx], eax
mov eax, dword [esi]
test eax, eax
jne 0x4298ff
mov esi, dword [ebp - 4]
add edi, 0x14
cmp dword [edi], 0
jne 0x4298e1
xor edi, edi
mov ecx, dword [ebx + 0xa4]
mov eax, esi
sub eax, dword [ebp - 0x1c]
mov dword [ebp - 0x18], eax
cmp ecx, edi
je 0x4299e8
cmp eax, edi
je 0x4299e8
mov eax, dword [ebx + 0xa0]
add eax, esi
add ecx, eax
mov dword [ebp - 0x14], ecx
cmp eax, ecx
jae 0x4299e8
mov ecx, dword [eax]
mov dword [ebp - 0x1c], ecx
mov ecx, dword [eax + 4]
shr ecx, 1
sub ecx, 4
add eax, 8
mov dword [ebp + 8], edi
cmp ecx, edi
jbe 0x4299e3
movzx edi, byte [eax + 1]
movzx edx, word [eax]
shr edi, 4
and edx, 0xfff
test edi, edi
je 0x4299d7
cmp edi, 3
jne 0x429a1c
mov edi, dword [ebp - 0x1c]
add edx, edi
mov edi, dword [ebp - 0x18]
add edx, esi
add dword [edx], edi
inc dword [ebp + 8]
inc eax
inc eax
cmp dword [ebp + 8], ecx
jb 0x4299b2
xor edi, edi
cmp eax, dword [ebp - 0x14]
jb 0x42999b
mov eax, dword fs:[0x30]
mov ecx, dword [eax + 8]
mov eax, dword fs:[0x30]
mov dword [eax + 8], esi
mov eax, dword fs:[0x30]
mov eax, dword [eax + 0xc]
mov eax, dword [eax + 0xc]
jmp 0x429a40
mov dword [ebp - 0x1c], str.error_allocating_executable_memory
push 0x44d6fc
lea eax, [ebp - 0x1c]
jmp 0x429781
mov dword [ebp - 0x20], str.unknown_relocation
push 0x44d6fc
lea eax, [ebp - 0x20]
jmp 0x429781
cmp dword [eax + 0x18], ecx
jne 0x429a3e
mov edx, dword [ebp - 8]
mov dword [eax + 0x18], esi
mov dword [eax + 0x20], edx
mov eax, dword [eax]
cmp dword [eax + 0x18], edi
jne 0x429a30
mov eax, dword [ebx + 0x28]
push edi
push edi
add eax, esi
push eax
push 0x429737
push edi
push edi
call dword [sym.imp.KERNEL32.dll_CreateThread]
test eax, eax
jne 0x429a72
mov dword [ebp - 0x24], str.cant_create_thread
push 0x44d6fc
lea eax, [ebp - 0x24]
jmp 0x429781
push edi
call dword [sym.imp.KERNEL32.dll_ExitThread]