Function at 0x413940
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call

Disassembly:
sub esp, 0x2c
push ebx
mov ebx, dword [esp + 0x34]
xor cl, cl
cmp dword [0x4467d4], 0
push ebp
push esi
push edi
mov byte [esp + 0x13], cl
mov word [esp + 0x1c], 0x6850
mov byte [esp + 0x22], 0xc3
je 0x41396e
mov edx, dword [ebx + 0x68]
mov eax, dword [ebx + 0x6c]
jmp 0x413974
mov edx, dword [ebx + 0x10]
mov eax, dword [ebx + 0x14]
mov ebp, dword [esp + 0x44]
mov dword [esp + 0x38], eax
mov dword [esp + 0x1e], edx
cmp dword [ebp + 8], 1
jne 0x413b4e
cmp dword [0x4467d4], 0
je 0x413aab
mov eax, dword [0x446818]
mov esi, dword [0x4471f0]
mov edi, dword [0x4471f4]
mov dword [esp + 0x44], eax
mov eax, dword [0x44681c]
mov dword [esp + 0x40], eax
mov eax, dword [ebp]
mov dword [esp + 0x14], eax
mov eax, esi
or eax, edi
jne 0x4139f0
push 0x4169b0
call fcn.004154a0
push edx
push eax
call fcn.00412340
mov esi, eax
mov edi, edx
mov ecx, esi
mov dword [0x4471f0], esi
add esp, 0xc
mov dword [0x4471f4], edi
or ecx, edi
je 0x413b4a
push dword [esp + 0x40]
mov eax, dword [esp + 0x18]
push dword [esp + 0x48]
cdq
push edx
push eax
push 2
push edi
push esi
call fcn.00414f50
add esp, 0x1c
test eax, eax
jne 0x413b4a
mov dword [esp + 0x40], eax
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], eax
lea eax, [esp + 0x14]
push eax
lea eax, [esp + 0x44]
push eax
push dword [0x446824]
push dword [0x44681c]
push dword [0x446818]
push dword [ebp]
call fcn.0040fe10
test eax, eax
js 0x413b4a
mov eax, dword [esp + 0x40]
push 0
push dword [0x446824]
cdq
push dword [0x44681c]
push dword [0x446818]
push edx
push eax
call fcn.004157f0
mov esi, dword [0x44683c]
lea eax, [esp + 0x1c]
push 0
push 7
cdq
xor ecx, ecx
push edx
push eax
mov eax, dword [esp + 0x50]
cdq
add esi, eax
adc ecx, edx
push ecx
push esi
call fcn.004157f0
mov eax, dword [esp + 0x40]
test eax, eax
je 0x413aa4
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ntdll.dll_NtUnmapViewOfSection]
mov cl, 1
jmp 0x413b4e
push dword [0x446810]
mov esi, dword [sym.imp.ntdll.dll_NtUnmapViewOfSection]
push dword [ebp]
call esi
test eax, eax
jne 0x413b4a
mov dword [esp + 0x40], eax
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], eax
lea eax, [esp + 0x14]
push eax
lea eax, [esp + 0x44]
push eax
push dword [0x446820]
push dword [0x446814]
push dword [0x446810]
push dword [ebp]
call fcn.0040fe10
test eax, eax
js 0x413b4a
push dword [0x446820]
push dword [0x446810]
push dword [esp + 0x48]
call fcn.004015a0
mov ecx, dword [esp + 0x4c]
add esp, 0xc
add ecx, dword [0x446838]
mov eax, dword [esp + 0x1c]
mov dword [ecx], eax
mov ax, word [esp + 0x20]
mov word [ecx + 4], ax
mov al, byte [esp + 0x22]
mov byte [ecx + 6], al
mov eax, dword [esp + 0x40]
test eax, eax
je 0x413aa4
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call esi
mov cl, 1
jmp 0x413b4e
mov cl, byte [esp + 0x13]
cmp dword [ebp + 8], 0
je 0x413b5c
test cl, cl
jne 0x413d48
cmp dword [0x4467d4], 0
je 0x413cc9
mov eax, dword [0x44683c]
xor ecx, ecx
add eax, dword [0x446818]
mov esi, dword [0x447200]
adc ecx, dword [0x44681c]
mov edi, dword [0x447204]
mov dword [esp + 0x2c], eax
mov eax, dword [ebp]
mov dword [esp + 0x40], eax
mov eax, esi
or eax, edi
mov dword [esp + 0x24], 0x20
mov dword [esp + 0x28], 0
mov dword [esp + 0x30], ecx
jne 0x413bd7
push 0x4169dc
call fcn.004154a0
push edx
push eax
call fcn.00412340
mov esi, eax
mov edi, edx
mov ecx, esi
mov dword [0x447200], esi
add esp, 0xc
mov dword [0x447204], edi
or ecx, edi
je 0x413c09
lea eax, [ebx + 0x88]
cdq
push edx
push eax
push 0
push 0x40
lea eax, [esp + 0x34]
cdq
push edx
push eax
lea eax, [esp + 0x44]
cdq
push edx
push eax
mov eax, dword [esp + 0x60]
cdq
push edx
push eax
push 5
push edi
push esi
call fcn.00414f50
add esp, 0x34
test eax, eax
je 0x413c16
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
add esp, 0x2c
ret 8
mov eax, dword [0x44683c]
xor ecx, ecx
add eax, dword [0x446818]
mov esi, dword [0x4471e8]
adc ecx, dword [0x44681c]
mov edi, dword [0x4471ec]
mov dword [esp + 0x44], eax
mov eax, dword [ebp]
mov dword [esp + 0x14], eax
mov eax, esi
or eax, edi
mov dword [esp + 0x34], 0
mov dword [esp + 0x38], 0
mov dword [esp + 0x40], ecx
jne 0x413c88
push 0x416998
call fcn.004154a0
push edx
push eax
call fcn.00412340
mov esi, eax
mov edi, edx
mov ecx, esi
mov dword [0x4471e8], esi
add esp, 0xc
mov dword [0x4471ec], edi
or ecx, edi
je 0x413cba
mov ecx, dword [esp + 0x40]
lea eax, [esp + 0x34]
cdq
push edx
push eax
push 0
push 7
lea eax, [esp + 0x2c]
cdq
push edx
push eax
mov eax, dword [esp + 0x2c]
push ecx
push dword [esp + 0x60]
cdq
push edx
push eax
push 5
push edi
push esi
call fcn.00414f50
add esp, 0x34
test eax, eax
je 0x413d48
pop edi
pop esi
pop ebp
mov eax, 0xfffffffe
pop ebx
add esp, 0x2c
ret 8
mov eax, dword [0x446810]
add eax, dword [0x446838]
mov dword [esp + 0x44], eax
lea eax, [ebx + 0x30]
push eax
push 0x40
lea eax, [esp + 0x48]
mov dword [esp + 0x48], 0x20
push eax
lea eax, [esp + 0x50]
push eax
push dword [ebp]
call dword [sym.imp.ntdll.dll_NtProtectVirtualMemory]
test eax, eax
je 0x413d0c
pop edi
pop esi
pop ebp
mov eax, 0xfffffffd
pop ebx
add esp, 0x2c
ret 8
lea eax, [esp + 0x14]
mov dword [esp + 0x14], 0
push eax
push 7
lea eax, [esp + 0x24]
push eax
mov eax, dword [0x446810]
add eax, dword [0x446838]
push eax
push dword [ebp]
call dword [sym.imp.ntdll.dll_NtWriteVirtualMemory]
test eax, eax
je 0x413d48
pop edi
pop esi
pop ebp
mov eax, 0xfffffffc
pop ebx
add esp, 0x2c
ret 8
lea edi, [ebx + 0x38]
mov ecx, 8
mov esi, 0x446848
rep movsd dword es:[edi], dword [esi]
lea edi, [ebx + 0x90]
mov ecx, 8
mov esi, 0x446868
rep movsd dword es:[edi], dword [esi]
lea edi, [ebx + 0xd4]
mov ecx, 0x10
mov esi, 0x446888
rep movsd dword es:[edi], dword [esi]
lea edi, [ebx + 0x114]
mov ecx, 0x10
mov esi, 0x4468c8
rep movsd dword es:[edi], dword [esi]
lea edi, [ebx + 0x154]
mov ecx, 0x40
mov esi, 0x446908
rep movsd dword es:[edi], dword [esi]
mov eax, dword [0x446808]
mov esi, dword [sym.imp.KERNEL32.dll_DuplicateHandle]
mov dword [ebx + 0xc0], eax
mov eax, dword [0x44680c]
mov dword [ebx + 0xc4], eax
cmp byte [0x430f38], 0
je 0x413e01
mov edx, dword [0x4467f8]
xor ecx, ecx
mov dword [esp + 0x40], ecx
lea eax, [edx + 1]
cmp eax, 1
jbe 0x413df2
push 2
push ecx
push ecx
lea eax, [esp + 0x4c]
push eax
push dword [ebp]
push edx
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call esi
mov ecx, dword [esp + 0x40]
mov eax, ecx
cdq
mov dword [ebx + 0xb0], eax
mov dword [ebx + 0xb4], edx
cmp byte [0x4462c0], 0
je 0x413e47
mov edx, dword [0x418008]
xor ecx, ecx
mov dword [esp + 0x40], ecx
lea eax, [edx + 1]
cmp eax, 1
jbe 0x413e38
push 2
push ecx
push ecx
lea eax, [esp + 0x4c]
push eax
push dword [ebp]
push edx
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call esi
mov ecx, dword [esp + 0x40]
mov eax, ecx
cdq
mov dword [ebx + 0xb8], eax
mov dword [ebx + 0xbc], edx
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x2c
ret 8