Function at 0x403fe0
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffec
cmp dword [0x46d61c], 0
push ebx
push esi
push edi
jne 0x403ff7
call fcn.00403e24
cmp dword [ebp + 8], 0
jne 0x404004
xor eax, eax
jmp 0x40459c
mov edx, dword [ebp + 8]
mov dword [ebp - 8], edx
push 0x40
mov ecx, dword [ebp - 8]
push ecx
call sub.KERNEL32.DLL_IsBadReadPtr
dec eax
je 0x404022
mov eax, dword [ebp - 8]
cmp word [eax], 0x5a4d
je 0x404029
xor eax, eax
jmp 0x40459c
mov edx, dword [ebp - 8]
mov ebx, dword [edx + 0x3c]
add ebx, dword [ebp - 8]
push 0xf8
push ebx
call sub.KERNEL32.DLL_IsBadReadPtr
dec eax
je 0x404048
cmp dword [ebx], 0x4550
je 0x40404f
xor eax, eax
jmp 0x40459c
cmp word [ebx + 0x14], 0xe0
jne 0x40405f
cmp word [ebx + 0x18], 0x10b
je 0x404069
mov eax, 4
jmp 0x40459c
cmp word [ebx + 6], 1
jae 0x404077
xor eax, eax
jmp 0x40459c
mov edx, dword [ebp - 8]
mov ebx, dword [edx + 0x3c]
add ebx, dword [ebp - 8]
mov eax, dword [ebp - 8]
mov dword [ebp - 4], eax
mov edx, dword [ebx + 0x80]
mov dword [ebp - 0xc], edx
cmp dword [ebp - 0xc], 0
je 0x4040a0
mov ecx, dword [ebp - 0xc]
add ecx, dword [ebp - 8]
mov dword [ebp - 0xc], ecx
jmp 0x4040aa
mov eax, 8
jmp 0x40459c
mov edx, dword [ebp - 0xc]
cmp dword [edx + 4], 0
jne 0x4040c0
mov ecx, dword [ebp - 0xc]
cmp dword [ecx + 0xc], 0
je 0x404597
mov eax, dword [ebp - 0xc]
mov ebx, dword [eax + 0xc]
add ebx, dword [ebp - 4]
xor eax, eax
mov dword [ebp - 0x10], eax
push ebx
call sub.KERNEL32.DLL_lstrlenA
mov esi, eax
mov edi, ebx
push esi
push str.Kernel32.dll
push edi
call fcn.00405d00
add esp, 0xc
test eax, eax
jne 0x4040f2
mov dword [ebp - 0x10], 1
push ebx
call sub.KERNEL32.DLL_lstrlenA
mov esi, eax
mov edi, ebx
push esi
push str.User32.dll
push edi
call fcn.00405d00
add esp, 0xc
test eax, eax
jne 0x404123
mov dword [ebp - 0x10], 2
jmp 0x404123
mov eax, dword [ebp - 0xc]
mov edx, dword [eax + 0x10]
add edx, dword [ebp - 8]
mov dword [ebp - 0x14], edx
mov ecx, dword [ebp - 0xc]
mov ebx, dword [ecx + 0x10]
add ebx, dword [ebp - 8]
jmp 0x404581
mov edx, 0x80000000
test eax, edx
jne 0x404572
jmp 0x4043a4
cmp dword [ebp - 0x10], 1
jne 0x404572
mov edx, dword [ebx]
cmp edx, dword [0x46d610]
jne 0x4043c0
mov ecx, dword [0x46d150]
mov dword [ebx], ecx
mov eax, dword [ebx]
cmp eax, dword [0x46d614]
jne 0x4043d2
mov edx, dword [0x46d154]
mov dword [ebx], edx
mov ecx, dword [ebx]
cmp ecx, dword [0x46d5b8]
jne 0x4043e3
mov eax, dword [0x46d148]
mov dword [ebx], eax
mov edx, dword [ebx]
cmp edx, dword [0x46d5bc]
jne 0x4043f5
mov ecx, dword [0x46d14c]
mov dword [ebx], ecx
mov eax, dword [ebx]
cmp eax, dword [0x46d5c0]
jne 0x404407
mov edx, dword [0x46d15c]
mov dword [ebx], edx
mov ecx, dword [ebx]
cmp ecx, dword [0x46d5ec]
jne 0x404418
mov eax, dword [0x46d170]
mov dword [ebx], eax
mov edx, dword [ebx]
cmp edx, dword [0x46d5f0]
jne 0x40442a
mov ecx, dword [0x46d16c]
mov dword [ebx], ecx
mov eax, dword [ebx]
cmp eax, dword [0x46d608]
jne 0x40443c
mov edx, dword [0x46d1a0]
mov dword [ebx], edx
mov ecx, dword [ebx]
cmp ecx, dword [0x46d60c]
jne 0x40444d
mov eax, dword [0x46d1a4]
mov dword [ebx], eax
mov edx, dword [ebx]
cmp edx, dword [0x46d604]
jne 0x40445f
mov ecx, dword [0x46d184]
mov dword [ebx], ecx
cmp byte [ebp + 0xc], 1
jae 0x404572
mov eax, dword [ebx]
cmp eax, dword [0x46d5c4]
jne 0x40447b
mov edx, dword [0x46d160]
mov dword [ebx], edx
mov ecx, dword [ebx]
cmp ecx, dword [0x46d5c8]
jne 0x40448c
mov eax, dword [0x46d168]
mov dword [ebx], eax
mov edx, dword [ebx]
cmp edx, dword [0x46d5cc]
jne 0x40449e
mov ecx, dword [0x46d164]
mov dword [ebx], ecx
mov eax, dword [ebx]
cmp eax, dword [0x46d5d0]
jne 0x4044b0
mov edx, dword [0x46d12c]
mov dword [ebx], edx
mov ecx, dword [ebx]
cmp ecx, dword [0x46d5d4]
jne 0x4044c1
mov eax, dword [0x46d144]
mov dword [ebx], eax
mov edx, dword [ebx]
cmp edx, dword [0x46d5d8]
jne 0x4044d3
mov ecx, dword [0x46d140]
mov dword [ebx], ecx
mov eax, dword [ebx]
cmp eax, dword [0x46d5dc]
jne 0x4044e5
mov edx, dword [0x46d130]
mov dword [ebx], edx
mov ecx, dword [ebx]
cmp ecx, dword [0x46d5e0]
jne 0x4044f6
mov eax, dword [0x46d134]
mov dword [ebx], eax
mov edx, dword [ebx]
cmp edx, dword [0x46d5e4]
jne 0x404508
mov ecx, dword [0x46d13c]
mov dword [ebx], ecx
mov eax, dword [ebx]
cmp eax, dword [0x46d5e8]
jne 0x40451a
mov edx, dword [0x46d138]
mov dword [ebx], edx
mov ecx, dword [ebx]
cmp ecx, dword [0x46d5f4]
jne 0x40452b
mov eax, dword [0x46d174]
mov dword [ebx], eax
mov edx, dword [ebx]
cmp edx, dword [0x46d5f8]
jne 0x40453d
mov ecx, dword [0x46d178]
mov dword [ebx], ecx
mov eax, dword [ebx]
cmp eax, dword [0x46d5fc]
jne 0x40454f
mov edx, dword [0x46d17c]
mov dword [ebx], edx
mov ecx, dword [ebx]
cmp ecx, dword [0x46d600]
jne 0x404560
mov eax, dword [0x46d180]
mov dword [ebx], eax
mov edx, dword [ebx]
cmp edx, dword [0x46d618]
jne 0x404572
mov ecx, dword [0x46d188]
mov dword [ebx], ecx
test ebx, ebx
jne 0x40457a
xor eax, eax
jmp 0x40459c
add ebx, 4
add dword [ebp - 0x14], 4
mov edx, dword [ebp - 0x14]
mov eax, dword [edx]
test eax, eax
jne 0x40413d
add dword [ebp - 0xc], 0x14
jmp 0x4040aa
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret