Function at 0x40bde0
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
sub esp, 0x3c
mov eax, dword [ebp + 8]
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x1c], eax
mov ecx, dword [ebp - 0x18]
add ecx, dword [eax + 0x11]
mov dword [ebp - 0x20], ecx
mov eax, dword [ebp - 0x18]
mov ecx, dword [ebp - 0x1c]
add eax, dword [ecx + 0x15]
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x30], 0
mov eax, dword [ebp - 0x1c]
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 - 0x28], eax
mov dword [ebp - 0xc], eax
mov dword [ebp - 0x34], 0xf512b1cc
mov edi, dword [sym.imp.ADVAPI32.dll_BuildExplicitAccessWithNameW]
jmp 0x40be60
mov dword [ebp - 0x34], eax
nop
nop
nop
nop
mov eax, dword [ebp - 0x34]
cmp eax, 0x7a0e8134
jg 0x40bec0
cmp eax, 0x66476c08
jg 0x40bee0
cmp eax, 0x54558e65
jg 0x40bf23
cmp eax, 0xa442d98d
jg 0x40bf63
cmp eax, 0x958960f2
jne 0x40be60
mov eax, dword [ebp - 0x28]
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 - 0x34], 0xd2aa41d6
jmp 0x40be60
cmp eax, 0x7a0e8135
jne 0x40be60
mov eax, 0x958960f2
cmp dword [ebp - 0x28], 0
jne 0x40be59
mov eax, 0xd2aa41d6
jmp 0x40be59
cmp eax, 0x66476c09
jne 0x40be60
mov eax, dword [ebp - 0x20]
mov ecx, dword [eax + 5]
mov edx, dword [ebp - 0x28]
add edx, dword [eax + 1]
add eax, 0xd
mov dword [esp + 8], ecx
mov dword [esp + 4], eax
mov dword [esp], edx
call fcn.00402590
mov eax, dword [ebp - 0x20]
mov ecx, dword [eax + 5]
lea eax, [eax + ecx + 0xd]
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x34], 0xbb6fb9e8
jmp 0x40be60
cmp eax, 0x54558e66
jne 0x40be60
mov eax, dword [ebp - 0x18]
mov ecx, dword [ebp - 0x1c]
add eax, dword [ecx + 0x11]
mov ecx, dword [ecx + 0xd]
mov edx, dword [ebp - 0x28]
mov dword [esp + 8], eax
mov dword [esp + 4], ecx
mov dword [esp], edx
call fcn.0040b9b0
test eax, eax
mov eax, 0x125c0a8
js 0x40bf5b
mov eax, 0x90d739f
mov dword [ebp - 0x34], eax
jmp 0x40be60
cmp eax, 0xbb6fb9e7
jg 0x40bfae
cmp eax, 0xa442d98e
jne 0x40be60
call fcn.0040cbc0
mov eax, dword [ebp - 0x24]
movzx eax, byte [eax]
mov ecx, eax
not ecx
mov edx, ecx
and edx, 0x9f6668c1
and eax, 0x3e
add eax, edx
xor eax, 0x6099973d
xor ecx, eax
test eax, ecx
mov eax, 0x2edb2672
jne 0x40bfa6
mov eax, 0x54558e66
mov dword [ebp - 0x34], eax
jmp 0x40be60
cmp eax, 0xd2aa41d5
jg 0x40bfde
cmp eax, 0xbb6fb9e8
jne 0x40be60
mov eax, 0x41e8a271
sub eax, dword [ebp - 0x2c]
mov ecx, 0x41e8a272
sub ecx, eax
mov dword [ebp - 0x2c], ecx
mov dword [ebp - 0x34], 0xf0c91793
jmp 0x40be60
cmp eax, 0xf0c91792
jg 0x40c003
cmp eax, 0xd2aa41d6
jne 0x40be60
mov dword [ebp - 0x10], 0
mov dword [ebp - 0x34], 0x27879a8c
jmp 0x40be60
cmp eax, 0x3e7272fa
jg 0x40c05a
cmp eax, 0x380782d9
jg 0x40c073
cmp eax, 0x2edb2671
jg 0x40c0a1
cmp eax, 0x27879a8b
jg 0x40c0df
cmp eax, 0xf512b1cb
jg 0x40c0ef
cmp eax, 0xf0c91793
jne 0x40be60
mov ecx, dword [ebp - 0x2c]
mov edx, dword [ebp - 0x1c]
mov eax, 0x66476c09
cmp ecx, dword [edx + 0xd]
jb 0x40c052
mov eax, 0xcc70027
mov dword [ebp - 0x34], eax
jmp 0x40be60
cmp eax, 0x3e7272fb
jne 0x40be60
mov esi, dword [edi]
mov dword [ebp - 0x34], 0x7a0e8135
jmp 0x40be60
cmp eax, 0x380782da
jne 0x40be60
mov eax, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x24]
mov ecx, dword [ecx + 1]
add ecx, eax
mov dword [esp + 4], ecx
mov dword [esp], eax
call fcn.0040b300
mov dword [ebp - 0x34], 0xa442d98e
jmp 0x40be60
cmp eax, 0x2edb2672
jne 0x40be60
mov eax, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x1c]
sub eax, dword [ecx + 1]
mov dword [ebp - 0x30], eax
mov ecx, dword [ebp - 0x28]
mov edx, dword [ebp - 0x24]
mov edx, dword [edx + 0x19]
add edx, ecx
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov dword [esp], ecx
call fcn.0040b660
mov dword [ebp - 0x34], 0x54558e66
jmp 0x40be60
cmp eax, 0x27879a8c
jne 0x40be60
jmp 0x40c1c6
cmp eax, 0xaf6bc0
jg 0x40c119
cmp eax, 0xf512b1cc
jne 0x40be60
mov eax, 0xaf6bc1
cmp dword [ebp - 0xc], 0
jne 0x40c111
mov eax, 0x3e7272fb
mov dword [ebp - 0x34], eax
jmp 0x40be60
cmp eax, 0xcc70026
jg 0x40c13a
cmp eax, 0xaf6bc1
je 0x40c196
cmp eax, 0x125c0a8
jne 0x40c1a9
mov dword [ebp - 0x34], 0x7a0e8135
jmp 0x40be60
cmp eax, 0xcc70027
jne 0x40be60
mov eax, dword [ebp - 0x24]
inc eax
mov ecx, dword [ebp - 0x14]
mov dword [esp + 4], eax
mov dword [esp], ecx
mov dword [esp + 8], 0x20
call fcn.00402590
mov eax, dword [ebp - 0x24]
movzx eax, byte [eax]
mov ecx, eax
not ecx
mov edx, ecx
and edx, 0xb73c115d
and eax, 0xa2
add eax, edx
xor eax, 0x48c3eea3
xor ecx, eax
test eax, ecx
mov eax, 0x380782da
jne 0x40c18e
mov eax, 0xa442d98e
mov dword [ebp - 0x34], eax
jmp 0x40be60
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x34], 0xf0c91793
jmp 0x40be60
cmp eax, 0x90d739f
jne 0x40be60
mov eax, dword [ebp - 0x28]
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x34], 0x27879a8c
jmp 0x40be60
mov eax, dword [ebp - 0x10]
add esp, 0x3c
pop esi
pop edi
pop ebp
ret