Function at 0x10016140
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push esi
push edi
mov edi, ecx
push 0
mov dword [edi + 8], 0
mov dword [edi + 4], 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov ecx, dword [eax + 0x3c]
add ecx, eax
mov eax, dword [ecx + 0x28]
add eax, 0x400000
cmp eax, 0x8245bc
ja 0x100162cf
je 0x10016268
cmp eax, 0x667bf0
ja 0x100161fd
je 0x100161ea
cmp eax, 0x5c6fd0
ja 0x100161cc
je 0x10016325
cmp eax, 0x5c1e70
je 0x100161b9
cmp eax, 0x5c2130
jne 0x100163a1
mov dword [edi + 4], 0x1010033
mov al, 1
mov byte [edi + 0xb], 0
pop edi
pop esi
mov esp, ebp
pop ebp
ret
mov dword [edi + 4], 0x10033
mov al, 1
mov byte [edi + 0xb], 0
pop edi
pop esi
mov esp, ebp
pop ebp
ret
cmp eax, 0x666ba0
jne 0x100163a1
mov dword [edi + 4], 0x1010056
mov al, 1
mov byte [edi + 0xb], 1
pop edi
pop esi
mov esp, ebp
pop ebp
ret
mov dword [edi + 4], 0x10056
mov al, 1
mov byte [edi + 0xb], 0
pop edi
pop esi
mov esp, ebp
pop ebp
ret
cmp eax, 0x82457c
ja 0x1001625d
je 0x10016218
cmp eax, 0x667c40
je 0x1001624a
cmp eax, 0x824570
jne 0x100163a1
push 1
push ecx
mov eax, esp
mov dword [edi + 4], 0x15553
mov byte [edi + 0xb], 0
mov dword [eax], 0x406a20
call fcn.10016740
add esp, 8
cmp al, 0xe9
setne al
dec al
and al, 0x48
mov byte [edi + 0xa], al
mov al, 1
pop edi
pop esi
mov esp, ebp
pop ebp
ret
mov dword [edi + 4], 0x1010056
mov al, 1
mov byte [edi + 0xb], 0
pop edi
pop esi
mov esp, ebp
pop ebp
ret
cmp eax, 0x8245b0
jne 0x100163a1
lea eax, [ebp - 0x10]
mov dword [edi + 4], 0x14553
push eax
push 0x40
mov esi, 0x406a20
mov byte [edi + 0xb], 0
push 1
push esi
mov dword [ebp - 0x14], 1
mov dword [ebp - 0x18], esi
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
setne byte [ebp - 0xc]
mov cl, byte [esi]
mov byte [ebp - 1], cl
test eax, eax
je 0x100162ba
mov eax, dword [ebp - 0x10]
lea ecx, [ebp - 8]
push ecx
push eax
push dword [ebp - 0x14]
mov dword [ebp - 8], eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
mov cl, byte [ebp - 1]
cmp cl, 0xe9
setne al
dec al
and al, 0x48
mov byte [edi + 0xa], al
mov al, 1
pop edi
pop esi
mov esp, ebp
pop ebp
ret
cmp eax, 0xa402ed
ja 0x10016338
je 0x100161d7
cmp eax, 0x85ec4a
ja 0x1001631e
je 0x100163a9
sub eax, 0x8252fc
je 0x1001630b
sub eax, 0x40
jne 0x100163a1
mov byte [edi + 0xb], al
mov al, 1
mov dword [edi + 4], 0x1014553
pop edi
pop esi
mov esp, ebp
pop ebp
ret
mov dword [edi + 4], 0x1015553
mov al, 1
mov byte [edi + 0xb], 0
pop edi
pop esi
mov esp, ebp
pop ebp
ret
cmp eax, 0x9912ed
jne 0x100163a1
mov dword [edi + 4], 0x1010033
mov al, 1
mov byte [edi + 0xb], 1
pop edi
pop esi
mov esp, ebp
pop ebp
ret
cmp eax, 0xd0d011
ja 0x1001639a
je 0x10016381
cmp eax, 0xc965ad
je 0x10016368
cmp eax, 0xd0af06
jne 0x100163a1
mov dword [edi + 4], 0x1015545
mov al, 1
mov word [edi + 8], 2
mov byte [edi + 0xb], 0
pop edi
pop esi
mov esp, ebp
pop ebp
ret
mov dword [edi + 4], 0x15549
mov al, 1
mov word [edi + 8], 0x400
mov byte [edi + 0xb], 0
pop edi
pop esi
mov esp, ebp
pop ebp
ret
mov dword [edi + 4], 0x15549
mov al, 1
mov word [edi + 8], 0x700
mov byte [edi + 0xb], 0
pop edi
pop esi
mov esp, ebp
pop ebp
ret
cmp eax, 0xd3c3db
je 0x100163a9
xor al, al
pop edi
pop esi
mov esp, ebp
pop ebp
ret
mov dword [edi + 4], 0x30053
mov al, 1
mov byte [edi + 0xb], 1
pop edi
pop esi
mov esp, ebp
pop ebp
ret