Function at 0x30f02a0
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x600
mov eax, dword [0x310e008]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov ebx, ecx
mov dword [ebp - 0x5bc], eax
mov eax, dword [ebx + 0x808]
push esi
xor esi, esi
mov dword [ebp - 0x5d0], esi
test eax, eax
je 0x30f02df
push 0xb
push dword [ebx + 0x804]
call eax
add esp, 8
mov dword [ebx + 0x834], eax
test eax, eax
je 0x30f0304
pop esi
mov byte [ebx + 0xc94], 1
mov al, 1
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0307c5f7
mov esp, ebp
pop ebp
ret 8
mov eax, dword [ebx + 0x808]
test eax, eax
je 0x30f031b
push 0xa
push dword [ebx + 0x804]
call eax
add esp, 8
mov dword [ebx + 0x838], eax
test eax, eax
je 0x30f0356
mov ecx, ebx
call fcn.030f2140
test al, al
je 0x30f0356
push dword [ebp - 0x5bc]
mov ecx, ebx
mov byte [ebx + 0xc78], 1
call fcn.030f23a0
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0307c5f7
mov esp, ebp
pop ebp
ret 8
mov eax, dword [ebx + 0x808]
test eax, eax
je 0x30f036d
push 4
push dword [ebx + 0x804]
call eax
add esp, 8
push edi
mov dword [ebx + 0x82c], eax
test eax, eax
jne 0x30f03c7
mov eax, dword [ebx + 0x808]
test eax, eax
je 0x30f038f
push 5
push dword [ebx + 0x804]
call eax
add esp, 8
mov edi, dword [ebp - 0x5bc]
mov dword [ebx + 0x830], eax
test eax, eax
jne 0x30f03cd
push 0x20
push 0x3008014
push edi
call fcn.030df7a0
mov esi, eax
add esp, 0xc
mov dword [ebp - 0x5d0], esi
test esi, esi
jne 0x30f03cd
push edi
push 4
mov ecx, ebx
call fcn.030f2ba0
jmp 0x30f0441
mov edi, dword [ebp - 0x5bc]
push 1
lea eax, [ebp - 0x4a8]
push eax
push 0x40
push 0
push 0
push esi
mov ecx, ebx
call fcn.030f1f40
test al, al
je 0x30f0424
mov ax, word [ebp - 0x4a8]
test esi, esi
je 0x30f0456
mov ecx, 0x4944
cmp ax, cx
jne 0x30f0456
push esi
call dword [sym.imp.msvcrt.dll_fclose]
mov eax, dword [ebp - 0x4a0]
add esp, 4
mov ecx, ebx
push edi
mov dword [ebx + 0xc80], eax
call fcn.030f15e0
test al, al
jne 0x30f0443
cmp dword [ebx], 0xb
jne 0x30f0443
push dword [ebp - 0x5bc]
mov ecx, ebx
push 0x11
call fcn.030f2ba0
test esi, esi
je 0x30f0441
push esi
call dword [sym.imp.msvcrt.dll_fclose]
add esp, 4
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0307c5f7
mov esp, ebp
pop ebp
ret 8
mov ecx, 0x5a4d
cmp ax, cx
jne 0x30f0424
push edi
mov ecx, ebx
call fcn.030f23a0
test al, al
je 0x30f0433
mov eax, dword [ebp - 0x46c]
test eax, eax
jle 0x30f0424
push 1
lea ecx, [ebp - 0x5b0]
push ecx
push pe_nt_image_headers32
push eax
push eax
push esi
mov ecx, ebx
call fcn.030f1f40
test al, al
je 0x30f0424
cmp dword [ebp - 0x5b0], 0x4550
jne 0x30f0424
movzx eax, word [ebp - 0x598]
xor edx, edx
xor edi, edi
mov dword [ebp - 0x5c4], edx
mov dword [ebp - 0x5c0], edx
mov dword [ebp - 0x5c8], edi
mov dword [ebp - 0x5d8], edx
cmp eax, 0x10b
je 0x30f0528
cmp eax, 0x20b
jne 0x30f0424
mov eax, dword [ebp - 0x560]
mov dword [ebx + 0xc7c], eax
mov eax, dword [ebp - 0x52c]
cmp eax, 6
jb 0x30f0502
mov edx, dword [ebp - 0x4f8]
mov ecx, dword [ebp - 0x4f4]
mov dword [ebp - 0x5c4], edx
mov dword [ebp - 0x5c0], ecx
mov cl, byte [ebp + 0xc]
test cl, cl
je 0x30f057d
cmp eax, 0xe
jb 0x30f057d
mov edi, dword [ebp - 0x4b8]
mov eax, dword [ebp - 0x4b4]
mov dword [ebp - 0x5c8], edi
mov dword [ebp - 0x5d8], eax
jmp 0x30f057f
mov eax, dword [ebp - 0x560]
mov dword [ebx + 0xc7c], eax
mov eax, dword [ebp - 0x53c]
cmp eax, 6
jb 0x30f0557
mov edx, dword [ebp - 0x508]
mov ecx, dword [ebp - 0x504]
mov dword [ebp - 0x5c4], edx
mov dword [ebp - 0x5c0], ecx
mov cl, byte [ebp + 0xc]
test cl, cl
je 0x30f057d
cmp eax, 0xe
jb 0x30f057d
mov edi, dword [ebp - 0x4c8]
mov eax, dword [ebp - 0x4c4]
mov dword [ebp - 0x5c8], edi
mov dword [ebp - 0x5d8], eax
jmp 0x30f057f
xor eax, eax
test edx, edx
je 0x30f0a3e
cmp dword [ebp - 0x5c0], 0
je 0x30f0a3e
test cl, cl
je 0x30f05a8
test edi, edi
je 0x30f0424
test eax, eax
je 0x30f0424
cmp dword [ebx + 0x82c], 0
jne 0x30f05d3
cmp dword [ebx + 0x830], 0
je 0x30f05d3
mov eax, dword [ebp - 0x5cc]
mov edx, dword [ebp - 0x5c8]
xor edi, edi
mov dword [ebp - 0x5b8], edi
jmp 0x30f0736
movzx ecx, word [ebp - 0x59c]
mov eax, dword [ebp - 0x46c]
add eax, 0x18
add eax, ecx
mov dword [ebp - 0x5e0], eax
movzx eax, word [ebp - 0x5aa]
mov dword [ebp - 0x5dc], eax
xor eax, eax
xor edi, edi
xor ecx, ecx
mov dword [ebp - 0x5e4], edi
mov dword [ebp - 0x5cc], eax
mov dword [ebp - 0x5d4], eax
mov dword [ebp - 0x5b8], ecx
cmp dword [ebp - 0x5dc], eax
jbe 0x30f0707
push 1
lea eax, [ebp - 0x448]
push eax
mov eax, dword [ebp - 0x5e0]
push 0x28
push eax
push eax
push esi
mov ecx, ebx
call fcn.030f1f40
test al, al
je 0x30f06f5
mov edx, dword [ebp - 0x43c]
add dword [ebp - 0x5e0], 0x28
cmp edx, dword [ebp - 0x5c4]
ja 0x30f0684
mov eax, dword [ebp - 0x5c4]
mov ecx, dword [ebp - 0x438]
add eax, dword [ebp - 0x5c0]
mov esi, dword [ebp - 0x5d0]
add ecx, edx
cmp ecx, eax
jb 0x30f0684
mov edi, dword [ebp - 0x434]
mov dword [ebp - 0x5e4], edx
mov cl, byte [ebp + 0xc]
test cl, cl
je 0x30f06c8
cmp edx, dword [ebp - 0x5c8]
ja 0x30f06c8
mov eax, dword [ebp - 0x5c8]
mov ecx, dword [ebp - 0x438]
add eax, dword [ebp - 0x5d8]
mov esi, dword [ebp - 0x5d0]
add ecx, edx
cmp ecx, eax
mov cl, byte [ebp + 0xc]
jb 0x30f06c8
mov eax, dword [ebp - 0x434]
mov dword [ebp - 0x5cc], eax
mov dword [ebp - 0x5d4], edx
jmp 0x30f06ce
mov eax, dword [ebp - 0x5cc]
test edi, edi
je 0x30f06da
test cl, cl
je 0x30f06f5
test eax, eax
jne 0x30f06f5
mov ecx, dword [ebp - 0x5b8]
inc ecx
mov dword [ebp - 0x5b8], ecx
cmp ecx, dword [ebp - 0x5dc]
jb 0x30f0622
jmp 0x30f06fb
mov ecx, dword [ebp - 0x5b8]
mov eax, dword [ebp - 0x5cc]
mov edx, dword [ebp - 0x5c4]
cmp ecx, dword [ebp - 0x5dc]
je 0x30f0424
sub edi, dword [ebp - 0x5e4]
mov cl, byte [ebp + 0xc]
add edi, edx
mov dword [ebp - 0x5b8], edi
test cl, cl
je 0x30f0771
sub eax, dword [ebp - 0x5d4]
mov edx, dword [ebp - 0x5c8]
add eax, edx
test cl, cl
je 0x30f0771
push 0
lea ecx, [ebp - 0x468]
push ecx
push 0x48
push edx
push eax
push esi
mov ecx, ebx
call fcn.030f1f40
test al, al
je 0x30f0424
cmp dword [ebp - 0x428], 0
je 0x30f0424
cmp dword [ebp - 0x424], 0
je 0x30f0424
mov ecx, dword [ebp - 0x5c0]
mov eax, 0x24924925
mul ecx
sub ecx, edx
shr ecx, 1
add ecx, edx
shr ecx, 4
cmp byte [ebp + 0xc], 0
mov dword [ebp - 0x430], 0
mov dword [ebp - 0x5f4], 0
mov dword [ebp - 0x5c0], ecx
je 0x30f07d3
push 0
push 0
push 0x100
lea eax, [ebp - 0x204]
push eax
push 0
push 0
push 0
push 0
push dword [ebp - 0x5bc]
call fcn.0307db8f
mov ecx, dword [ebp - 0x5c0]
add esp, 0x24
mov dword [ebp - 0x5d4], 0
test ecx, ecx
je 0x30f0949
push 0
lea eax, [ebp - 0x420]
push eax
push 0x1c
push dword [ebp - 0x5c4]
mov ecx, ebx
push edi
push esi
call fcn.030f1f40
test al, al
je 0x30f0424
add dword [ebp - 0x5c4], 0x1c
cmp dword [ebx + 0x82c], 0
jne 0x30f0820
cmp dword [ebx + 0x830], 0
jne 0x30f0829
add edi, 0x1c
mov dword [ebp - 0x5b8], edi
lea eax, [ebp - 0x420]
push eax
push 1
mov ecx, ebx
call fcn.030f2660
mov eax, dword [ebp - 0x414]
cmp eax, 2
jne 0x30f090c
cmp byte [ebp + 0xc], 0
je 0x30f0904
mov eax, dword [ebp - 0x410]
mov dword [ebx + 0xc98], eax
mov eax, dword [ebp - 0x40c]
mov dword [ebx + 0xc9c], eax
mov eax, dword [ebp - 0x408]
mov ecx, ebx
mov byte [ebx + 0xc94], 1
mov dword [ebx + 0x86c], esi
mov dword [ebx + 0xca0], eax
call fcn.030f1ff0
test al, al
je 0x30f0930
cmp byte [ebx + 0xca4], 0
je 0x30f0930
cmp dword [ebx + 0xcbc], 0
je 0x30f0930
mov eax, dword [ebx + 0xcc0]
test eax, eax
je 0x30f0930
push 0
push 0
push 0x100
lea ecx, [ebp - 0x404]
push ecx
push 0
push 0
push 0
push 0
push eax
call fcn.0307db8f
lea eax, [ebp - 0x404]
push eax
lea eax, [ebp - 0x204]
push eax
call dword [sym.imp.msvcrt.dll__wcsicmp]
add esp, 0x2c
test eax, eax
jne 0x30f0930
pop edi
pop esi
mov al, 1
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0307c5f7
mov esp, ebp
pop ebp
ret 8
lea edi, [ebp - 0x43c]
jmp 0x30f0917
cmp eax, 4
jne 0x30f0930
lea edi, [ebp - 0x600]
mov ecx, 7
lea esi, [ebp - 0x420]
rep movsd dword es:[edi], dword [esi]
mov edi, dword [ebp - 0x5b8]
mov esi, dword [ebp - 0x5d0]
mov eax, dword [ebp - 0x5d4]
inc eax
mov dword [ebp - 0x5d4], eax
cmp eax, dword [ebp - 0x5c0]
jb 0x30f07e5
xor cl, cl
cmp dword [ebp - 0x430], 0
mov dword [ebx + 0x86c], esi
mov byte [ebp - 0x5b1], cl
je 0x30f0994
mov eax, dword [ebp - 0x42c]
mov dword [ebx + 0xc98], eax
mov eax, dword [ebp - 0x428]
mov cl, 1
mov dword [ebx + 0xc9c], eax
mov eax, dword [ebp - 0x424]
mov byte [ebp - 0x5b1], cl
mov byte [ebx + 0xc94], cl
mov dword [ebx + 0xca0], eax
jmp 0x30f099e
cmp byte [ebp + 0xc], 0
jne 0x30f0424
mov eax, dword [ebp - 0x59a]
shr eax, 9
and al, 1
mov byte [ebx + 0xc78], al
je 0x30f0a10
cmp dword [ebp - 0x5f4], 0
je 0x30f0a10
push dword [ebp - 0x5f0]
mov eax, dword [ebp - 0x5a8]
push dword [ebp - 0x5ec]
mov dword [ebx + 0xc80], eax
push dword [ebp - 0x5e8]
mov eax, dword [ebp - 0x5fc]
push esi
push 0
mov ecx, ebx
mov byte [ebp - 0x5b1], 1
mov dword [ebx + 0xc84], eax
call fcn.030f2920
mov cl, byte [ebp - 0x5b1]
pop edi
pop esi
mov al, cl
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0307c5f7
mov esp, ebp
pop ebp
ret 8
test cl, cl
jne 0x30f0a29
push dword [ebp - 0x5bc]
mov ecx, ebx
push 0x13
call fcn.030f2ba0
mov cl, byte [ebp - 0x5b1]
mov al, cl
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0307c5f7
mov esp, ebp
pop ebp
ret 8
push dword [ebp - 0x5bc]
mov ecx, ebx
push 0x13
call fcn.030f2ba0
push esi
call fcn.030f0270
jmp 0x30f043e