Function at 0x3004af40
Capabilities:
Access peb ldr_data
Get number of processors
Get process heap flags

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword fs:[0x30]
push ebx
push esi
push edi
mov eax, dword [eax + 0xc]
add eax, 0xc
mov dword [ebp - 8], eax
mov ecx, dword [eax]
mov dword [ebp - 4], ecx
mov ax, word [ecx + 0x24]
sub ax, word [ecx + 0x2c]
mov word [ebp - 0x18], ax
mov word [ebp - 0x16], ax
movzx ecx, ax
pushfd
mov eax, dword fs:[0x18]
pop ebx
test eax, eax
jne 0x3004af84
or esi, 0xffffffff
or edi, 0xffffffff
jmp 0x3004af8d
mov esi, dword [eax + 0x34]
mov edi, dword [eax + 0xbf4]
and ecx, 0xfffffffe
add ecx, 2
push ecx
push 8
push dword [0x30271450]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, dword fs:[0x18]
mov edx, eax
test ecx, ecx
je 0x3004afbe
mov dword [ecx + 0x34], esi
mov dword [ecx + 0xbf4], edi
test ebx, ebx
je 0x3004afbe
push ebx
popfd
movzx eax, word [ebp - 0x18]
push eax
mov eax, dword [ebp - 4]
mov dword [ebp - 0x14], edx
push dword [eax + 0x28]
push edx
call fcn.30160350
mov ecx, dword [ebp - 8]
add esp, 0xc
mov eax, dword [ecx]
mov esi, dword [eax]
cmp esi, ecx
je 0x3004b1ba
mov ax, word [esi + 0x24]
sub ax, word [esi + 0x2c]
mov word [ebp - 0x10], ax
mov word [ebp - 0xe], ax
movzx ecx, ax
pushfd
mov eax, dword fs:[0x18]
pop dword [ebp - 4]
test eax, eax
jne 0x3004b00d
or edi, 0xffffffff
or ebx, 0xffffffff
jmp 0x3004b016
mov edi, dword [eax + 0x34]
mov ebx, dword [eax + 0xbf4]
and ecx, 0xfffffffe
add ecx, 2
push ecx
push 8
push dword [0x30271450]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, dword fs:[0x18]
mov edx, eax
test ecx, ecx
je 0x3004b04a
mov eax, dword [ebp - 4]
mov dword [ecx + 0x34], edi
mov dword [ecx + 0xbf4], ebx
test eax, eax
je 0x3004b04a
push eax
popfd
movzx eax, word [ebp - 0x10]
push eax
mov dword [ebp - 0xc], edx
push dword [esi + 0x28]
push edx
call fcn.30160350
mov edi, dword [ebp - 0xc]
push 0x14
push str.c:windows_system32_
push edi
call fcn.30169d44
add esp, 0x18
test eax, eax
je 0x3004b0ae
push 0x14
push str.c:windows_syswow64_
push edi
call fcn.30169d44
add esp, 0xc
test eax, eax
je 0x3004b0ae
push 0x15
push str.c:windows_sysnative_
push edi
call fcn.30169d44
add esp, 0xc
test eax, eax
je 0x3004b0ae
push 0
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x18]
push eax
call dword [0x3024554c]
test eax, eax
jne 0x3004b0b9
mov eax, dword [esi + 0x18]
cmp eax, dword [0x3026c328]
jne 0x3004b118
mov ecx, dword [ebp - 0xc]
pushfd
mov eax, dword fs:[0x18]
pop edi
test eax, eax
jne 0x3004b0d4
or ebx, 0xffffffff
mov dword [ebp - 4], 0xffffffff
jmp 0x3004b0e0
mov ebx, dword [eax + 0x34]
mov eax, dword [eax + 0xbf4]
mov dword [ebp - 4], eax
push ecx
push 0
push dword [0x30271450]
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, dword fs:[0x18]
test eax, eax
je 0x3004b1af
mov ecx, dword [ebp - 4]
mov dword [eax + 0x34], ebx
mov dword [eax + 0xbf4], ecx
test edi, edi
je 0x3004b1af
push edi
popfd
jmp 0x3004b1af
mov ecx, dword [ebp - 0xc]
pushfd
mov eax, dword fs:[0x18]
pop edi
test eax, eax
jne 0x3004b133
or ebx, 0xffffffff
mov dword [ebp - 4], 0xffffffff
jmp 0x3004b13f
mov ebx, dword [eax + 0x34]
mov eax, dword [eax + 0xbf4]
mov dword [ebp - 4], eax
push ecx
push 0
push dword [0x30271450]
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, dword fs:[0x18]
test eax, eax
je 0x3004b16a
mov ecx, dword [ebp - 4]
mov dword [eax + 0x34], ebx
mov dword [eax + 0xbf4], ecx
test edi, edi
je 0x3004b16a
push edi
popfd
mov edi, dword [esi + 0x20]
mov edx, dword [esi + 0x18]
add edi, edx
mov ecx, dword [0x3026c664]
cmp ecx, 0x64
jae 0x3004b1af
xor eax, eax
test ecx, ecx
je 0x3004b19a
cmp edx, dword [eax*8 + 0x3026c340]
jb 0x3004b195
cmp edx, dword [eax*8 + 0x3026c344]
jb 0x3004b1af
inc eax
cmp eax, ecx
jb 0x3004b183
mov dword [ecx*8 + 0x3026c340], edx
mov dword [ecx*8 + 0x3026c344], edi
inc ecx
mov dword [0x3026c664], ecx
mov esi, dword [esi]
cmp esi, dword [ebp - 8]
jne 0x3004afe4
mov ecx, dword [ebp - 0x14]
pushfd
mov eax, dword fs:[0x18]
pop esi
test eax, eax
jne 0x3004b1d1
or edi, 0xffffffff
or ebx, 0xffffffff
jmp 0x3004b1da
mov edi, dword [eax + 0x34]
mov ebx, dword [eax + 0xbf4]
push ecx
push 0
push dword [0x30271450]
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, dword fs:[0x18]
test eax, eax
je 0x3004b202
mov dword [eax + 0x34], edi
mov dword [eax + 0xbf4], ebx
test esi, esi
je 0x3004b202
push esi
popfd
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret