Function at 0x40dfa0
Capabilities:
Parse pe header
Read file on windows

Disassembly:
mov edi, edi
push ebp
lea ebp, [esp - 0x110]
sub esp, 0x190
mov eax, dword [0x44f9f8]
xor eax, ebp
mov dword [ebp + 0x10c], eax
push ebx
push esi
mov esi, dword [ebp + 0x118]
push edi
xor ebx, ebx
push 0x40
lea eax, [ebp + 0xcc]
push ebx
push eax
mov dword [ebp - 0x64], ebx
mov dword [ebp - 0x5c], ebx
mov dword [ebp - 0x78], ebx
mov dword [ebp - 0x74], ebx
call fcn.00408720
push pe_nt_image_headers32
lea eax, [ebp - 0x2c]
push ebx
push eax
call fcn.00408720
xor eax, eax
add esp, 0x18
lea edi, [ebp - 0x54]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
push 8
pop ecx
xor eax, eax
lea edi, [ebp - 0x4c]
rep stosd dword es:[edi], eax
push ebx
lea eax, [ebp - 0x64]
push eax
mov dword [ebp - 0x70], ebx
mov dword [ebp - 0x6c], ebx
xor edi, edi
call fcn.004304c2
mov ebx, eax
test ebx, ebx
jns 0x40e030
push 0x43c9be
push ebx
call fcn.00431454
pop ecx
pop ecx
jmp 0x40e439
push 0
push 0x8000080
push 3
push 0
push 1
push SysReAllocString
push dword [ebp - 0x64]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x58], eax
cmp eax, 0xffffffff
jne 0x40e095
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x40e067
and eax, 0xffff
or eax, 0x80070000
mov ebx, eax
test ebx, ebx
js 0x40e072
mov ebx, 0x80004005
push ebx
push 0x44
push 0x43c986
call fcn.00431468
push dword [ebp - 0x64]
push 0x43c95a
push ebx
call fcn.00431454
add esp, 0xc
jmp 0x40e439
mov ebx, dword [sym.imp.KERNEL32.dll_ReadFile]
push 0
lea eax, [ebp - 0x5c]
push eax
push 0x40
lea eax, [ebp + 0xcc]
push eax
push dword [ebp - 0x58]
call ebx
test eax, eax
jne 0x40e0f1
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x40e0c7
and eax, 0xffff
or eax, 0x80070000
mov ebx, eax
test ebx, ebx
js 0x40e0d2
mov ebx, 0x80004005
push ebx
push 0x49
push 0x43c986
call fcn.00431468
push 0x43c93e
push ebx
call fcn.00431454
pop ecx
pop ecx
jmp 0x40e430
cmp dword [ebp - 0x5c], 0x40
jb 0x40e105
mov eax, 0x5a4d
cmp ax, word [ebp + 0xcc]
je 0x40e121
mov esi, 0x8007000d
push esi
push 0x4e
push 0x43c986
mov ebx, esi
call fcn.00431468
push 0x43c90c
push esi
jmp 0x40e0e5
mov eax, dword [ebp + 0x108]
push 0
cdq
push 0
push edx
push eax
push dword [ebp - 0x58]
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
jne 0x40e171
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x40e14f
and eax, 0xffff
or eax, 0x80070000
mov ebx, eax
test ebx, ebx
js 0x40e15a
mov ebx, 0x80004005
push ebx
push 0x59
push 0x43c986
call fcn.00431468
push 0x43c8ee
jmp 0x40e0e4
push 0
lea eax, [ebp - 0x5c]
push eax
push 0x18
lea eax, [ebp - 0x2c]
push eax
push dword [ebp - 0x58]
call ebx
test eax, eax
jne 0x40e1bc
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x40e19a
and eax, 0xffff
or eax, 0x80070000
mov ebx, eax
test ebx, ebx
js 0x40e1a5
mov ebx, 0x80004005
push ebx
push 0x5f
push 0x43c986
call fcn.00431468
push 0x43c8d4
jmp 0x40e0e4
cmp dword [ebp - 0x5c], 0x18
jb 0x40e1cb
cmp dword [ebp - 0x2c], 0x4550
je 0x40e1e9
mov esi, 0x8007000d
push esi
push 0x64
push 0x43c986
mov ebx, esi
call fcn.00431468
push 0x43c8a4
jmp 0x40e11e
mov eax, dword [ebp + 0x108]
lea ecx, [eax + 0x58]
mov dword [ebp - 0x7c], ecx
xor ecx, ecx
push ecx
push ecx
add eax, 0x98
push ecx
push eax
push dword [ebp - 0x58]
mov dword [ebp - 0x80], eax
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
jne 0x40e246
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x40e224
and eax, 0xffff
or eax, 0x80070000
mov ebx, eax
test ebx, ebx
js 0x40e22f
mov ebx, 0x80004005
push ebx
push 0x6f
push 0x43c986
call fcn.00431468
push 0x43c884
jmp 0x40e0e4
push 0
lea eax, [ebp - 0x5c]
push eax
push 4
lea eax, [ebp - 0x70]
push eax
push dword [ebp - 0x58]
call ebx
test eax, eax
jne 0x40e291
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x40e26f
and eax, 0xffff
or eax, 0x80070000
mov ebx, eax
test ebx, ebx
js 0x40e27a
mov ebx, 0x80004005
push ebx
push 0x74
push 0x43c986
call fcn.00431468
push 0x43c862
jmp 0x5640e0e4
push ebp
pop ecx
dec ecx
mov eax, dword [esi + 0x20]
add eax, edi
mov edi, dword [esi + 0x1c]
add edi, dword [ebp + 8]
sbb al, 3
jge 0x40e445
mov dword [ebp - 0x14], eax
mov eax, dword [ebp + 0xc]
shr eax, 0x10
test ax, ax
je 0x40e4c1
adc byte [esi - 0x7b], ah
sal byte [esi + esi*2 - 0x7d], 0x65
cld
add byte [ebx - 0xfba76f9], cl
and dword [ebp - 4], 0
mov eax, dword [edi]
mov dword [ebp - 0x10], eax
call fcn.0040e31f
stosd dword es:[edi], eax
dec esi
stosb byte es:[edi], al
movsb byte es:[edi], byte [esi]
cmp dword [ebp - 0x10], 0
je 0x40e4a6
mov eax, dword [ebp - 0x14]
and dword [ebp - 0x10], 0
mov dword [ebp - 0xc], eax
mov dword [ebp - 8], ebx
mov eax, dword [ebp - 8]
movzx eax, word [eax]
cmp eax, dword [ebp - 4]
jne 0x40e492
mov eax, dword [ebp - 0xc]
push dword [ebp + 0xc]
mov eax, dword [eax]
add eax, dword [ebp + 8]
push eax
call fcn.0040e2b5
pop ecx
test eax, eax
pop ecx
je 0x40e4b9
mov eax, dword [esi + 0x18]
inc dword [ebp - 0x10]
add dword [ebp - 8], 2
add dword [ebp - 0xc], 4
dec eax
cmp dword [ebp - 0x10], eax
jbe 0x40e470
mov eax, dword [esi + 0x14]
inc dword [ebp - 4]
dec eax
cmp dword [ebp - 4], eax
jbe 0x40e44f
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
mov eax, dword [ebp - 4]
mov eax, dword [edi + eax*4]
jmp 0x40e4f6
xor ebx, ebx
mov dword [ebp - 0x10], edi
mov eax, dword [esi + 0x10]
add eax, ebx
cmp dword [ebp + 0xc], eax
jne 0x40e4e1
call fcn.0040e31f
mov dh, 0x33
int 0x14
mov eax, dword [ebp - 0x10]
cmp dword [eax], 0
jne 0x40e4f0
mov eax, dword [esi + 0x14]
add dword [ebp - 0x10], 4
inc ebx
dec eax
cmp ebx, eax
jbe 0x40e4c6
jmp 0x40e4b2
mov eax, dword [edi + ebx*4]
shl eax, 6
add eax, dword [ebp + 8]
jmp 0x40e4b4