Function at 0x40c0c0
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
sub esp, 0x40
mov eax, dword [ebp + 8]
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x20], eax
mov ecx, dword [ebp - 0x1c]
add ecx, dword [eax + 0x11]
mov dword [ebp - 0x24], ecx
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x20]
add eax, dword [ecx + 0x15]
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x34], 0
mov eax, dword [ebp - 0x20]
mov eax, dword [eax + 5]
mov dword [esp + 4], eax
mov dword [esp + 0xc], 0x40
mov dword [esp + 8], 0x1000
mov dword [esp], 0
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
sub esp, 0x10
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x38], 0xe2ec64ad
mov edi, dword [sym.imp.ADVAPI32.dll_AccessCheck]
jmp 0x40c140
mov dword [ebp - 0x38], eax
nop
nop
nop
nop
mov eax, dword [ebp - 0x38]
cmp eax, 0x92890c74
jg 0x40c170
cmp eax, 0x82498298
jne 0x40c140
mov ecx, dword [ebp - 0x30]
mov edx, dword [ebp - 0x20]
mov eax, 0x92890c75
cmp ecx, dword [edx + 0xd]
jb 0x40c139
mov eax, 0x943f0d0
jmp 0x40c139
cmp eax, 0x797ca36b
jg 0x40c270
cmp eax, 0x6f0140f1
jg 0x40c2ac
cmp eax, 0x6a359d69
jg 0x40c2ca
cmp eax, 0x26245c70
jg 0x40c2e8
cmp eax, 0x23a3f0c7
jg 0x40c2ff
cmp eax, 0x1db27feb
jg 0x40c32d
cmp eax, 0x13e9d963
jg 0x40c377
cmp eax, 0x1261291d
jg 0x40c387
cmp eax, 0xf510e0a
jg 0x40c3a0
cmp eax, 0x943f0cf
jg 0x40c3c3
cmp eax, 0x2f74f98
jg 0x40c434
cmp eax, 0xf1ba4013
jg 0x40c458
cmp eax, 0xe2ec64ac
jg 0x40c48e
cmp eax, 0xbf23993c
jg 0x40c4b1
cmp eax, 0xabd5e935
jg 0x40c4ce
cmp eax, 0xaa48ed4c
jg 0x40c4e5
cmp eax, 0x92890c75
je 0x40c51b
cmp eax, 0x92d26fc6
jne 0x40c553
call fcn.0040cd20
mov eax, dword [ebp - 0x28]
movzx eax, byte [eax]
mov ecx, eax
not ecx
mov edx, ecx
and edx, 0xfd4121cf
and eax, 0x30
add eax, edx
xor eax, 0x2bede33
xor ecx, eax
test eax, ecx
mov eax, 0x1db27fec
jne 0x40c267
mov eax, 0x26245c71
mov dword [ebp - 0x38], eax
jmp 0x40c140
cmp eax, 0x797ca36c
jne 0x40c140
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x20]
add eax, dword [ecx + 0x11]
mov ecx, dword [ecx + 0xd]
mov edx, dword [ebp - 0x2c]
mov dword [esp + 8], eax
mov dword [esp + 4], ecx
mov dword [esp], edx
call fcn.0040ba90
test eax, eax
sets byte [ebp - 9]
mov dword [ebp - 0x38], 0x2f74f99
jmp 0x40c140
cmp eax, 0x6f0140f2
jne 0x40c140
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x38], 0x13e9d964
jmp 0x40c140
cmp eax, 0x6a359d6a
jne 0x40c140
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x38], 0x82498298
jmp 0x40c140
cmp eax, 0x26245c71
jne 0x40c140
mov dword [ebp - 0x38], 0x797ca36c
jmp 0x40c140
cmp eax, 0x23a3f0c8
jne 0x40c140
mov eax, dword [ebp - 0x2c]
mov ecx, dword [ebp - 0x28]
mov ecx, dword [ecx + 1]
add ecx, eax
mov dword [esp + 4], ecx
mov dword [esp], eax
call fcn.0040b280
mov dword [ebp - 0x38], 0x92d26fc6
jmp 0x40c140
cmp eax, 0x1db27fec
jne 0x40c140
mov eax, dword [ebp - 0x2c]
mov ecx, dword [ebp - 0x20]
mov edx, 0x53adfe22
sub edx, dword [ecx + 1]
lea eax, [edx + eax - 0x53adfe22]
mov dword [ebp - 0x34], eax
mov ecx, dword [ebp - 0x2c]
mov edx, dword [ebp - 0x28]
mov edx, dword [edx + 0x19]
add edx, ecx
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov dword [esp], ecx
call fcn.0040b6e0
mov dword [ebp - 0x38], 0x26245c71
jmp 0x40c140
cmp eax, 0x13e9d964
jne 0x40c140
jmp 0x40c56d
cmp eax, 0x1261291e
jne 0x40c140
mov esi, dword [edi]
mov dword [ebp - 0x38], 0xf510e0b
jmp 0x40c140
cmp eax, 0xf510e0b
jne 0x40c140
mov eax, 0xf1ba4014
cmp dword [ebp - 0x2c], 0
jne 0x40c3bb
mov eax, 0x6f0140f2
mov dword [ebp - 0x38], eax
jmp 0x40c140
cmp eax, 0x943f0d0
jne 0x40c140
mov eax, dword [ebp - 0x28]
inc eax
mov ecx, dword [ebp - 0x18]
mov dword [esp + 4], eax
mov dword [esp], ecx
mov dword [esp + 8], 0x20
call fcn.00403050
mov eax, dword [ebp - 0x28]
movzx eax, byte [eax]
mov ecx, eax
not ecx
and eax, 0x68
mov edx, ecx
and edx, 0x97
add edx, eax
xor edx, 0x96
and ecx, 0xfffffffe
or ecx, edx
mov eax, ecx
not eax
and eax, 0x7c
and ecx, 0xd4a96783
add ecx, eax
xor ecx, 0xd4a96783
mov eax, 0x23a3f0c8
jne 0x40c42c
mov eax, 0x92d26fc6
mov dword [ebp - 0x38], eax
jmp 0x40c140
cmp eax, 0x2f74f99
jne 0x40c140
mov al, byte [ebp - 9]
test al, al
mov eax, 0xabd5e936
jne 0x40c450
mov eax, 0xbf23993d
mov dword [ebp - 0x38], eax
jmp 0x40c140
cmp eax, 0xf1ba4014
jne 0x40c140
mov eax, dword [ebp - 0x2c]
mov dword [esp], eax
mov dword [esp + 8], 0x8000
mov dword [esp + 4], 0
call dword [sym.imp.KERNEL32.dll_VirtualFree]
sub esp, 0xc
mov dword [ebp - 0x38], 0x6f0140f2
jmp 0x40c140
cmp eax, 0xe2ec64ad
jne 0x40c140
mov eax, 0x6a359d6a
cmp dword [ebp - 0x10], 0
jne 0x40c4a9
mov eax, 0x1261291e
mov dword [ebp - 0x38], eax
jmp 0x40c140
cmp eax, 0xbf23993d
jne 0x40c140
mov eax, dword [ebp - 0x2c]
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x38], 0x13e9d964
jmp 0x40c140
cmp eax, 0xabd5e936
jne 0x40c140
mov dword [ebp - 0x38], 0xf510e0b
jmp 0x40c140
cmp eax, 0xaa48ed4d
jne 0x40c140
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x20]
add eax, dword [ecx + 0x11]
mov ecx, dword [ecx + 0xd]
mov edx, dword [ebp - 0x2c]
mov dword [esp + 8], eax
mov dword [esp + 4], ecx
mov dword [esp], edx
call fcn.0040ba90
mov dword [ebp - 0x38], 0x797ca36c
jmp 0x40c140
mov eax, dword [ebp - 0x24]
mov ecx, dword [eax + 5]
mov edx, dword [ebp - 0x2c]
add edx, dword [eax + 1]
add eax, 0xd
mov dword [esp + 8], ecx
mov dword [esp + 4], eax
mov dword [esp], edx
call fcn.00403050
mov eax, dword [ebp - 0x24]
mov ecx, dword [eax + 5]
lea eax, [eax + ecx + 0xd]
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x38], 0x9e1a659d
jmp 0x40c140
cmp eax, 0x9e1a659d
jne 0x40c140
inc dword [ebp - 0x30]
mov dword [ebp - 0x38], 0x82498298
jmp 0x40c140
mov eax, dword [ebp - 0x14]
add esp, 0x40
pop esi
pop edi
pop ebp
ret