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 0xf8
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.00430fde
mov ebx, eax
test ebx, ebx
jns 0x40e030
push 0x43cae2
push ebx
call fcn.00430a6a
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 0x47
push 0x43caa8
call fcn.004315c0
push dword [ebp - 0x64]
push 0x43ca7c
push ebx
call fcn.00430a6a
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 0x4c
push 0x43caa8
call fcn.004315c0
push 0x43ca60
push ebx
call fcn.00430a6a
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 0x51
push 0x43caa8
mov ebx, esi
call fcn.004315c0
push 0x43ca2e
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 0x5c
push 0x43caa8
call fcn.004315c0
push 0x43ca10
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 0x62
push 0x43caa8
call fcn.004315c0
push 0x43c9f6
jmp 0x40e0e4
cmp dword [ebp - 0x5c], 0x18
jb 0x40e1cb
cmp dword [ebp - 0x2c], 0x4550
je 0x40e1e9
mov esi, 0x8007000d
push esi
push 0x67
push 0x43caa8
mov ebx, esi
call fcn.004315c0
push 0x43c9c6
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 0x72
push 0x43caa8
call fcn.004315c0
push 0x43c9a6
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 0x77
push 0x43caa8
call fcn.004315c0
push 0x43c984
jmp 0x40e0e4
push 0
lea eax, [ebp - 0x5c]
push eax
push 4
lea eax, [ebp - 0x6c]
push eax
push dword [ebp - 0x58]
call ebx
test eax, eax
jne 0x40e2dc
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x40e2ba
and eax, 0xffff
or eax, 0x80070000
mov ebx, eax
test ebx, ebx
js 0x40e2c5
mov ebx, 0x80004005
push ebx
push 0x7c
push 0x43caa8
call fcn.004315c0
push 0x43c964
jmp 0x40e0e4
movzx eax, word [ebp - 0x18]
mov ecx, dword [ebp + 0x108]
lea eax, [eax + ecx + 0x18]
xor ecx, ecx
push ecx
push ecx
push ecx
push eax
push dword [ebp - 0x58]
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
jne 0x40e336
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x40e311
and eax, 0xffff
or eax, 0x80070000
mov ebx, eax
test ebx, ebx
js 0x40e31c
mov ebx, 0x80004005
push ebx
push 0x87
push 0x43caa8
call fcn.004315c0
push 0x43c93e
jmp 0x40e0e4
and dword [ebp - 0x68], edi
push 0
lea eax, [ebp - 0x5c]
push eax
push 0x28
lea eax, [ebp - 0x54]
push eax
push dword [ebp - 0x58]
call ebx
test eax, eax
je 0x40e39e
mov dword [ebp - 0x60], 1
cmp dword [ebp - 0x5c], 0x28
jb 0x40e3e0
push 8
lea eax, [ebp - 0x54]
push 0x43c934
push eax
call fcn.00409228
add esp, 0xc
test eax, eax
je 0x40e463
movzx eax, word [ebp - 0x26]
cmp dword [ebp - 0x60], eax
jae 0x40e402
inc dword [ebp - 0x68]
inc dword [ebp - 0x60]
push 0
lea eax, [ebp - 0x5c]
push eax
push 0x28
lea eax, [ebp - 0x54]
push eax
push dword [ebp - 0x58]
call ebx
test eax, eax
jne 0x40e355
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x40e3b2
and eax, 0xffff
or eax, 0x80070000
mov ebx, eax
test ebx, ebx
js 0x40e3bd
mov ebx, 0x80004005
push ebx
push 0x90
push 0x43caa8
call fcn.004315c0
push dword [ebp - 0x68]
push 0x43c904
push ebx
call fcn.00430a6a
add esp, 0xc
jmp 0x40e430
mov esi, 0x8007000d
push esi
push 0x95
push 0x43caa8
mov ebx, esi
call fcn.004315c0
push dword [ebp - 0x68]
push 0x43c8cc
push esi
jmp 0x40e3d6
mov esi, 0x8007000d
push esi
push 0xa3
push 0x43caa8
mov ebx, esi
call fcn.004315c0
push 0x43c8ae
push esi
call fcn.00430a6a
pop ecx
pop ecx
test edi, edi
je 0x40e430
push edi
call fcn.004318fe
push dword [ebp - 0x58]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x64], 0
je 0x40e447
push dword [ebp - 0x64]
call fcn.0042eb62
mov ecx, dword [ebp + 0x10c]
pop edi
pop esi
mov eax, ebx
xor ecx, ebp
pop ebx
call fcn.00408498
add ebp, 0x110
leave
ret 4
cmp dword [ebp - 0x44], 0x34
jae 0x40e48d
mov esi, 0x8007000d
push esi
push 0xaf
push 0x43caa8
mov ebx, esi
call fcn.004315c0
push dword [ebp - 0x44]
push 0x43c87e
jmp 0x40e3ff
push 1
push dword [ebp - 0x44]
call fcn.0043176e
mov edi, eax
test edi, edi
jne 0x40e4bc
mov ebx, 0x8007000e
push ebx
push 0xb4
push 0x43caa8
call fcn.004315c0
push 0x43c852
jmp 0x40e0e4
mov eax, dword [ebp - 0x40]
xor ecx, ecx
push ecx
push ecx
push ecx
push eax
push dword [ebp - 0x58]
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
jne 0x40e50c
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x40e4e6
and eax, 0xffff
or eax, 0x80070000
mov ebx, eax
test ebx, ebx
js 0x40e4f1
mov ebx, 0x80004005
push ebx
push 0xba
push 0x43caa8
call fcn.004315c0
push 0x43c9a6
push ebx
jmp 0x40e41f
mov eax, dword [ebp - 0x40]
add eax, 0x1c
push 0
mov dword [ebp - 0x60], eax
lea eax, [ebp - 0x5c]
push eax
push dword [ebp - 0x44]
push edi
push dword [ebp - 0x58]
call ebx
test eax, eax
jne 0x40e55e
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x40e53c
and eax, 0xffff
or eax, 0x80070000
mov ebx, eax
test ebx, ebx
js 0x40e547
mov ebx, 0x80004005
push ebx
push 0xc3
push 0x43caa8
call fcn.004315c0
push 0x43c834
jmp 0x40e506
mov eax, dword [ebp - 0x44]
cmp eax, dword [ebp - 0x5c]
jbe 0x40e587
mov esi, 0x8007000d
push esi
push 0xc8
push 0x43caa8
mov ebx, esi
call fcn.004315c0
push 0x43c80e
jmp 0x40e41e
cmp dword [edi + 4], 2
je 0x40e5b7
mov esi, 0x8007000d
push esi
push 0xcf
push 0x43caa8
mov ebx, esi
call fcn.004315c0
push dword [edi + 4]
push 0x43c7d6
push esi
call fcn.00430a6a
jmp 0x40e67b
lea eax, [ebp - 0x78]
push eax
push dword [ebp - 0x58]
call fcn.004350b8
mov ebx, eax
test ebx, ebx
jns 0x40e5d3
push 0x43c7b2
jmp 0x40e506
mov eax, dword [edi + 0x18]
mov dword [esi], eax
mov ecx, dword [edi + 0x20]
test ecx, ecx
je 0x40e5e4
mov eax, dword [edi + 0x24]
jmp 0x40e5ee
mov ecx, dword [ebp - 0x70]
test ecx, ecx
je 0x40e5f5
mov eax, dword [ebp - 0x6c]
add eax, ecx
mov dword [esi + 4], eax
jmp 0x40e5fd
mov ecx, dword [edi + 0x30]
add ecx, eax
mov dword [esi + 4], ecx
mov eax, dword [ebp - 0x78]
mov dword [esi + 8], eax
mov eax, dword [ebp - 0x74]
mov dword [esi + 0xc], eax
mov eax, dword [ebp - 0x7c]
mov dword [esi + 0x10], eax
mov eax, dword [ebp - 0x80]
mov dword [esi + 0x14], eax
mov eax, dword [ebp - 0x60]
mov dword [esi + 0x18], eax
mov eax, dword [edi + 0x1c]
mov dword [esi + 0x1c], eax
mov eax, dword [edi + 0x20]
mov dword [esi + 0x20], eax
mov eax, dword [edi + 0x24]
mov dword [esi + 0x24], eax
mov eax, dword [edi + 0x28]
mov dword [esi + 0x28], eax
mov eax, dword [edi + 0x2c]
mov dword [esi + 0x2c], eax
push 1
shl eax, 2
push eax
call fcn.0043176e
mov dword [esi + 0x30], eax
test eax, eax
jne 0x40e66a
mov ebx, 0x8007000e
push ebx
push 0xf2
push 0x43caa8
call fcn.004315c0
push 0x43c782
jmp 0x40e506
mov ecx, dword [esi + 0x2c]
shl ecx, 2
push ecx
lea ecx, [edi + 0x30]
push ecx
push eax
call fcn.00406be0
add esp, 0xc
jmp 0x40e426