Function at 0x40d040
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x34
mov dword [ebp - 0x38], 0x7bc7afb5
jmp 0x40d060
mov dword [ebp - 0x38], 0xe687d6bf
nop
nop
nop
nop
nop
nop
nop
mov eax, dword [ebp - 0x38]
cmp eax, 0x9db33f67
jg 0x40d080
cmp eax, 0x88b2fcf0
jne 0x40d060
jmp 0x40d052
cmp eax, 0xa4a40c0a
jg 0x40d0a0
cmp eax, 0x9db33f68
jne 0x40d060
mov eax, dword [ebp - 0x18]
mov eax, dword [ebp - 0x28]
mov dword [ebp - 0x38], 0x402a7ab7
jmp 0x40d060
cmp eax, 0xa9f11f6f
jg 0x40d0b7
cmp eax, 0xa4a40c0b
jne 0x40d060
mov dword [ebp - 0x38], 0xbd03649b
jmp 0x40d060
cmp eax, 0xb32f89bc
jg 0x40d0ce
cmp eax, 0xa9f11f70
jne 0x40d060
mov dword [ebp - 0x38], 0xce02f0ee
jmp 0x40d060
cmp eax, 0xbd03649a
jg 0x40d0f5
cmp eax, 0xb32f89bd
jne 0x40d060
mov al, byte [ebp - 0xe]
test al, al
mov eax, 0x7779ab7b
jne 0x40d0ed
mov eax, 0x33732ef9
mov dword [ebp - 0x38], eax
jmp 0x40d060
cmp eax, 0xc0c0ccda
jg 0x40d11e
cmp eax, 0xbd03649b
jne 0x40d060
mov eax, dword [ebp - 0x18]
mov eax, dword [eax]
inc eax
mov ecx, dword [ebp - 0x18]
mov dword [ecx], eax
mov dword [ebp - 0x38], 0xe766a626
jmp 0x40d060
cmp eax, 0xc788076d
jg 0x40d200
cmp eax, 0xc0c0ccdb
jne 0x40d060
mov eax, 4
call fcn.00415e20
mov eax, 4
call fcn.00415e20
mov ecx, esp
mov eax, 4
call fcn.00415e20
mov edx, esp
mov eax, 4
call fcn.00415e20
mov esi, esp
mov eax, 4
call fcn.00415e20
mov edi, esp
mov eax, 4
call fcn.00415e20
mov dword [ebp - 0x3c], esp
mov eax, 4
call fcn.00415e20
mov ebx, esp
mov eax, 4
call fcn.00415e20
mov eax, 4
call fcn.00415e20
mov eax, dword [ebp + 0xc]
mov dword [ecx], eax
mov eax, dword [ebp + 8]
mov ecx, eax
mov dword [edx], ecx
mov dword [esi], ecx
mov eax, dword [edx]
add eax, dword [ecx + 0x11]
mov dword [edi], eax
mov eax, dword [edx]
mov edx, dword [esi]
add eax, dword [edx + 0x15]
mov ecx, dword [ebp - 0x3c]
mov dword [ecx], eax
mov dword [ebx], 0
mov dword [esp], 0
mov eax, dword [esi]
mov eax, dword [eax + 5]
sub esp, 0x10
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]
mov dword [ebx], eax
mov dword [ebp - 0x38], 0xc3d70d9
jmp 0x40d060
cmp eax, 0xcb95f0de
jg 0x40d21e
cmp eax, 0xc788076e
jne 0x40d060
mov dword [ebp - 0x38], 0xcb95f0df
jmp 0x40d060
cmp eax, 0xce02f0ed
jg 0x40d245
cmp eax, 0xcb95f0df
jne 0x40d060
mov eax, dword [ebp - 0x34]
mov dword [eax], 0
mov dword [ebp - 0x38], 0x2bfa723
jmp 0x40d060
cmp eax, 0xd9447a6a
jg 0x40d263
cmp eax, 0xce02f0ee
jne 0x40d060
mov dword [ebp - 0x38], 0xd9447a6b
jmp 0x40d060
cmp eax, 0xe687d6be
jg 0x40d281
cmp eax, 0xd9447a6b
jne 0x40d060
mov dword [ebp - 0x38], 0x25eb8539
jmp 0x40d060
cmp eax, 0x7e14f407
jg 0x40d2e0
cmp eax, 0x7bc7afb4
jg 0x40d30a
cmp eax, 0x78e12a61
jg 0x40d321
cmp eax, 0xe766a625
jg 0x40d383
cmp eax, 0xe687d6bf
jne 0x40d060
mov eax, dword [ebp - 0x1c]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x20]
mov ecx, dword [ecx]
add eax, dword [ecx + 1]
mov ecx, dword [ebp - 0x1c]
mov ecx, dword [ecx]
sub esp, 8
mov dword [esp + 4], eax
mov dword [esp], ecx
call fcn.0040bf10
add esp, 8
mov dword [ebp - 0x38], 0x9586744
jmp 0x40d060
cmp eax, 0x7e14f408
jne 0x40d060
mov eax, dword [ebp - 0x18]
mov eax, dword [eax]
neg eax
mov ecx, 1
sub ecx, eax
mov eax, dword [ebp - 0x18]
mov dword [eax], ecx
mov dword [ebp - 0x38], 0xbd03649b
jmp 0x40d060
cmp eax, 0x7bc7afb5
jne 0x40d060
mov dword [ebp - 0x38], 0xc3d70d9
jmp 0x40d060
cmp eax, 0x78e12a62
jne 0x40d060
mov eax, dword [ebp - 0x1c]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x28]
mov ecx, dword [ecx]
mov edx, 0xa8138a11
sub edx, dword [ecx + 1]
lea eax, [edx + eax + 0x57ec75ef]
mov ecx, dword [ebp - 0x14]
mov dword [ecx], eax
mov eax, dword [ebp - 0x1c]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x20]
mov ecx, dword [ecx]
add eax, dword [ecx + 0x19]
mov ecx, dword [ebp - 0x14]
mov ecx, dword [ecx]
mov edx, dword [ebp - 0x1c]
mov edx, dword [edx]
sub esp, 0xc
mov dword [esp + 8], eax
mov dword [esp + 4], ecx
mov dword [esp], edx
call fcn.0040c350
add esp, 0xc
mov dword [ebp - 0x38], 0x46843d10
jmp 0x40d060
cmp eax, 0xea5c4953
jg 0x40d3a1
cmp eax, 0xe766a626
jne 0x40d060
mov dword [ebp - 0x38], 0x76dfe690
jmp 0x40d060
cmp eax, 0xf37eb7ee
jg 0x40d408
cmp eax, 0xea5c4954
jne 0x40d060
mov eax, dword [ebp - 0x24]
mov eax, dword [eax]
mov eax, dword [eax + 5]
mov ecx, dword [ebp - 0x24]
mov ecx, dword [ecx]
add ecx, 0xd
mov edx, dword [ebp - 0x1c]
mov edx, dword [edx]
mov esi, dword [ebp - 0x24]
mov esi, dword [esi]
add edx, dword [esi + 1]
sub esp, 0xc
mov dword [esp + 8], eax
mov dword [esp + 4], ecx
mov dword [esp], edx
call fcn.00402cc0
add esp, 0xc
mov eax, dword [ebp - 0x24]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x24]
mov ecx, dword [ecx]
mov ecx, dword [ecx + 5]
lea eax, [eax + ecx + 0xd]
mov ecx, dword [ebp - 0x24]
mov dword [ecx], eax
mov dword [ebp - 0x38], 0xa4a40c0b
jmp 0x40d060
cmp eax, 0xf554fb9a
jg 0x40d42f
cmp eax, 0xf37eb7ef
jne 0x40d060
mov eax, dword [ebp - 0x34]
mov dword [eax], 0
mov dword [ebp - 0x38], 0xcb95f0df
jmp 0x40d060
cmp eax, 0x2bfa722
jg 0x40d471
cmp eax, 0xf554fb9b
jne 0x40d060
mov eax, dword [ebp - 0x1c]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x20]
mov ecx, dword [ecx]
add eax, dword [ecx + 1]
mov ecx, dword [ebp - 0x1c]
mov ecx, dword [ecx]
sub esp, 8
mov dword [esp + 4], eax
mov dword [esp], ecx
call fcn.0040bf10
add esp, 8
mov dword [ebp - 0x38], 0xe687d6bf
jmp 0x40d060
cmp eax, 0x9586743
jg 0x40d48f
cmp eax, 0x2bfa723
jne 0x40d060
mov dword [ebp - 0x38], 0x3f5381e3
jmp 0x40d060
cmp eax, 0xc3d70d8
jg 0x40d4ad
cmp eax, 0x9586744
jne 0x40d060
mov dword [ebp - 0x38], 0x1e84985b
jmp 0x40d060
cmp eax, 0x110c7050
jg 0x40d5cf
cmp eax, 0xc3d70d9
jne 0x40d060
mov eax, 4
call fcn.00415e20
mov dword [ebp - 0x34], esp
mov eax, 4
call fcn.00415e20
mov dword [ebp - 0x30], esp
mov eax, 4
call fcn.00415e20
mov dword [ebp - 0x2c], esp
mov eax, 4
call fcn.00415e20
mov dword [ebp - 0x28], esp
mov eax, 4
call fcn.00415e20
mov dword [ebp - 0x24], esp
mov eax, 4
call fcn.00415e20
mov dword [ebp - 0x20], esp
mov eax, 4
call fcn.00415e20
mov dword [ebp - 0x1c], esp
mov eax, 4
call fcn.00415e20
mov dword [ebp - 0x18], esp
mov eax, 4
call fcn.00415e20
mov dword [ebp - 0x14], esp
mov eax, dword [ebp - 0x30]
mov ecx, dword [ebp + 0xc]
mov dword [eax], ecx
mov eax, dword [ebp - 0x2c]
mov ecx, dword [ebp + 8]
mov dword [eax], ecx
mov eax, dword [ebp - 0x2c]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x28]
mov dword [ecx], eax
mov eax, dword [ebp - 0x2c]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x28]
mov ecx, dword [ecx]
add eax, dword [ecx + 0x11]
mov ecx, dword [ebp - 0x24]
mov dword [ecx], eax
mov eax, dword [ebp - 0x2c]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x28]
mov ecx, dword [ecx]
add eax, dword [ecx + 0x15]
mov ecx, dword [ebp - 0x20]
mov dword [ecx], eax
mov eax, dword [ebp - 0x1c]
mov dword [eax], 0
mov eax, dword [ebp - 0x14]
mov dword [eax], 0
mov eax, dword [ebp - 0x28]
mov eax, dword [eax]
mov eax, dword [eax + 5]
sub esp, 0x10
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]
mov ecx, dword [ebp - 0x1c]
mov dword [ecx], eax
mov eax, dword [ebp - 0x1c]
cmp dword [eax], 0
setne byte [ebp - 0xe]
mov dword [ebp - 0x38], 0xb32f89bd
jmp 0x40d060
cmp eax, 0x1e84985a
jg 0x40d5f7
cmp eax, 0x110c7051
jne 0x40d060
mov eax, dword [ebp - 0x1c]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x34]
mov dword [ecx], eax
mov dword [ebp - 0x38], 0x3f5381e3
jmp 0x40d060
cmp eax, 0x20c4856f
jg 0x40d634
cmp eax, 0x1e84985b
jne 0x40d060
call fcn.0040e230
mov eax, dword [ebp - 0x20]
mov eax, dword [eax]
movzx eax, byte [eax]
mov ecx, eax
xor ecx, 0xfc
test eax, ecx
mov eax, 0x78e12a62
jne 0x40d62c
mov eax, 0x46843d10
mov dword [ebp - 0x38], eax
jmp 0x40d060
cmp eax, 0x25eb8538
jg 0x40d652
cmp eax, 0x20c48570
jne 0x40d060
mov dword [ebp - 0x38], 0xce02f0ee
jmp 0x40d060
cmp eax, 0x33732ef8
jg 0x40d67e
cmp eax, 0x25eb8539
jne 0x40d060
mov ecx, dword [ebp - 0x1c]
mov eax, 0x3c713c3a
cmp dword [ecx], 0
jne 0x40d676
mov eax, 0xc788076e
mov dword [ebp - 0x38], eax
jmp 0x40d060
cmp eax, 0x3890a360
jg 0x40d6a3
cmp eax, 0x33732ef9
jne 0x40d060
mov eax, dword [sym.imp.ADVAPI32.dll_ClearEventLogA]
mov esi, dword [eax]
mov dword [ebp - 0x38], 0x25eb8539
jmp 0x40d060
cmp eax, 0x3c713c39
jg 0x40d6ce
cmp eax, 0x3890a361
jne 0x40d060
mov al, byte [ebp - 0xd]
test al, al
mov eax, 0xea5c4954
jne 0x40d6c6
mov eax, 0x5a9f4276
mov dword [ebp - 0x38], eax
jmp 0x40d060
cmp eax, 0x3f5381e2
jg 0x40d70d
cmp eax, 0x3c713c3a
jne 0x40d060
mov eax, dword [ebp - 0x1c]
mov eax, dword [eax]
sub esp, 0xc
mov dword [esp], eax
mov dword [esp + 8], 0x8000
mov dword [esp + 4], 0
call dword [sym.imp.KERNEL32.dll_VirtualFree]
mov dword [ebp - 0x38], 0xc788076e
jmp 0x40d060
cmp eax, 0x402a7ab6
jg 0x40d724
cmp eax, 0x3f5381e3
jne 0x40d060
jmp 0x40d830
cmp eax, 0x46843d0f
jg 0x40d755
cmp eax, 0x402a7ab7
jne 0x40d060
mov eax, dword [ebp - 0x18]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x28]
mov ecx, dword [ecx]
cmp eax, dword [ecx + 0xd]
setb al
mov byte [ebp - 0xd], al
mov dword [ebp - 0x38], 0x3890a361
jmp 0x40d060
cmp eax, 0x5a9f4275
jg 0x40d7ad
cmp eax, 0x46843d10
jne 0x40d060
mov eax, dword [ebp - 0x2c]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x28]
mov ecx, dword [ecx]
add eax, dword [ecx + 0x11]
mov ecx, dword [ebp - 0x28]
mov ecx, dword [ecx]
mov ecx, dword [ecx + 0xd]
mov edx, dword [ebp - 0x1c]
mov edx, dword [edx]
sub esp, 0xc
mov dword [esp + 8], eax
mov dword [esp + 4], ecx
mov dword [esp], edx
call fcn.0040c910
add esp, 0xc
test eax, eax
mov eax, 0x20c48570
js 0x40d7a5
mov eax, 0x110c7051
mov dword [ebp - 0x38], eax
jmp 0x40d060
cmp eax, 0x5a9f4276
je 0x40d7c7
cmp eax, 0x76dfe690
jne 0x40d810
mov dword [ebp - 0x38], 0x402a7ab7
jmp 0x40d060
mov eax, dword [ebp - 0x20]
mov eax, dword [eax]
inc eax
mov ecx, dword [ebp - 0x30]
mov ecx, dword [ecx]
sub esp, 0xc
mov dword [esp + 4], eax
mov dword [esp], ecx
mov dword [esp + 8], 0x20
call fcn.00402cc0
add esp, 0xc
mov eax, dword [ebp - 0x20]
mov eax, dword [eax]
movzx eax, byte [eax]
not eax
or eax, 0xfffffffe
cmp eax, 0xffffffff
mov eax, 0x88b2fcf0
jne 0x40d808
mov eax, 0x1e84985b
mov dword [ebp - 0x38], eax
jmp 0x40d060
cmp eax, 0x7779ab7b
jne 0x40d060
mov eax, dword [ebp - 0x18]
mov dword [eax], 0
mov dword [ebp - 0x38], 0x76dfe690
jmp 0x40d060
mov eax, dword [ebp - 0x34]
mov eax, dword [eax]
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret