Function at 0x1018bf90
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
mov eax, dword [ebp + 8]
sub esp, 0x438
push esi
mov esi, dword [eax]
push edi
xor edi, edi
cmp dword [0x10320eb4], edi
jne 0x1018bfd5
push 0x10320fc0
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
push 0x100
push edi
push 0x10320ec0
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
mov dword [0x10320eb4], 1
push 0x10320fc0
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ecx, esi
call fcn.1018ccd0
mov ecx, dword [ebp + 0xc]
mov esi, eax
mov dword [esp + 0x10], esi
call fcn.1018ccd0
push 0x3bc
mov dword [esp + 0x20], eax
lea eax, [esp + 0x88]
push 0
push eax
mov dword [esp + 0x24], edi
call sub.VCRUNTIME140.dll_memset
mov eax, dword [0x102f74f0]
add esp, 0xc
mov edx, 0x1234566f
mov ecx, 0x102f74f0
mov dword [esp + 0x80], edx
test eax, eax
je 0x1018c03f
nop
cmp eax, 1
je 0x1018c081
mov eax, dword [ecx + 8]
add ecx, 8
test eax, eax
jne 0x1018c030
push 0x77
push str.e:watermarkmodulecommon_vendorincludemhookdisasm_libdisasm_mhook.c
push 0x102683fc
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__wassert]
add esp, 0xc
push 0x36
push str.e:watermarkmodulecommon_vendorincludemhookdisasm_libdisasm_mhook.c
push 0x102683fc
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__wassert]
add esp, 0xc
push 0x10320fc0
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
xor eax, eax
test edi, edi
pop edi
setne al
pop esi
mov esp, ebp
pop ebp
ret
test ecx, ecx
je 0x1018c054
mov eax, dword [ecx]
mov dword [esp + 0x84], eax
mov eax, dword [ecx + 4]
mov dword [esp + 0x88], eax
mov dword [esp + 0xc], esi
mov eax, dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__wassert]
cmp edx, 0x1234566f
jne 0x1018c1f0
test esi, esi
jne 0x1018c0c2
push 0x5a
push str.e:watermarkmodulecommon_vendorincludemhookdisasm_libdisasm_mhook.c
push str.Address
call eax
add esp, 0xc
push 0x3a0
lea eax, [esp + 0x94]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
mov dword [esp + 0x90], 0x1234567f
lea eax, [esp + 0x80]
mov dword [esp + 0x94], eax
lea eax, [esp + 0x98]
push 0xff
push 0x20
push eax
call sub.VCRUNTIME140.dll_memset
mov eax, dword [esp + 0x18]
mov ecx, esi
cdq
add esp, 0xc
mov dword [esp + 0x1b0], esi
xor esi, esi
sub ecx, eax
mov byte [esp + 0x197], 0
lea eax, [esp + 0x90]
mov dword [esp + 0x1a0], ecx
sbb esi, edx
mov dword [esp + 0x1a4], esi
mov esi, dword [esp + 0xc]
push 0x26
push esi
push eax
mov eax, dword [esp + 0x94]
mov eax, dword [eax + 8]
call eax
add esp, 0xc
test eax, eax
je 0x1018c1b6
mov eax, dword [esp + 0x1ac]
cmp eax, 0x105
je 0x1018c201
cmp eax, 0x101
je 0x1018c201
cmp eax, 0x102
je 0x1018c201
cmp eax, 0x103
je 0x1018c201
cmp eax, 0x104
je 0x1018c201
mov ecx, dword [esp + 0x18]
add ecx, dword [esp + 0x1b8]
add esi, dword [esp + 0x1b8]
mov dword [esp + 0x18], ecx
mov dword [esp + 0xc], esi
cmp ecx, 5
jae 0x1018c210
mov edx, dword [esp + 0x80]
jmp 0x1018c09c
cmp dword [esp + 0x1b0], esi
mov esi, dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__wassert]
je 0x1018c1d6
push 0x60
push str.e:watermarkmodulecommon_vendorincludemhookdisasm_libdisasm_mhook.c
push str.Disassembler__Instruction.Address__Address
call esi
add esp, 0xc
cmp dword [esp + 0x1b8], 0x19
jb 0x1018c201
push 0x61
push str.e:watermarkmodulecommon_vendorincludemhookdisasm_libdisasm_mhook.c
push str.Disassembler__Instruction.Length___MAX_INSTRUCTION_LENGTH
call esi
jmp 0x1018c1fe
push 0x59
push str.e:watermarkmodulecommon_vendorincludemhookdisasm_libdisasm_mhook.c
push 0x102683fc
call eax
add esp, 0xc
mov esi, dword [esp + 0x18]
cmp esi, 5
jb 0x1018c069
jmp 0x1018c214
mov esi, dword [esp + 0x18]
mov ecx, dword [esp + 0x10]
mov edx, esi
call fcn.1018c760
xor edi, edi
cmp dword [0x10320eb8], 0x40
mov dword [esp + 0x20], edi
jae 0x1018c322
mov ecx, dword [esp + 0x10]
cmp ecx, 0x80000000
jae 0x1018c248
mov dword [esp + 0xc], 1
jmp 0x1018c252
lea eax, [ecx - 0x7fff0000]
mov dword [esp + 0xc], eax
jae 0x1018c260
lea eax, [ecx + 0x7ff80000]
mov dword [esp + 0x14], eax
jmp 0x1018c268
mov dword [esp + 0x14], 0xfff80000
xorps xmm0, xmm0
mov dword [esp + 0x70], edi
lea eax, [esp + 0x50]
movaps xmmword [esp + 0x50], xmm0
push eax
movaps xmmword [esp + 0x64], xmm0
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov eax, dword [esp + 0xc]
cmp eax, dword [esp + 0x14]
jae 0x1018c322
push 0x1c
lea ecx, [esp + 0x38]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x1018c2f9
cmp dword [esp + 0x44], 0x10000
jne 0x1018c2e7
mov eax, dword [esp + 0x40]
cmp eax, 0x6c
jb 0x1018c2eb
mov ecx, dword [esp + 0x6c]
cmp eax, ecx
jb 0x1018c2eb
mov eax, dword [esp + 0xc]
xor edx, edx
dec eax
add eax, ecx
div ecx
push 0x20
imul eax, ecx
push 0x3000
push 0x6c
push eax
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov edi, eax
mov dword [esp + 0x20], edi
test edi, edi
jne 0x1018c301
mov eax, dword [esp + 0x40]
add eax, dword [esp + 0x34]
mov dword [esp + 0xc], eax
cmp eax, dword [esp + 0x14]
jb 0x1018c292
test edi, edi
je 0x1018c51c
xor eax, eax
cmp dword [eax*4 + 0x10320ec0], 0
je 0x1018c315
inc eax
cmp eax, 0x40
jb 0x1018c303
jmp 0x1018c322
inc dword [0x10320eb8]
mov dword [eax*4 + 0x10320ec0], edi
test edi, edi
je 0x1018c51c
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea ecx, [esp + 0x28]
mov dword [esp + 0xc], eax
push ecx
push 0x40
push esi
push dword [esp + 0x1c]
mov dword [esp + 0x38], 0
push eax
mov dword [esp + 0x28], 0
call dword [sym.imp.KERNEL32.dll_VirtualProtectEx]
test eax, eax
je 0x1018c4c4
lea eax, [esp + 0x14]
push eax
push 0x40
push 0x6c
push edi
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_VirtualProtectEx]
test eax, eax
je 0x1018c49d
lea eax, [edi + 0x2c]
xor ecx, ecx
mov dword [esp + 0x24], eax
test esi, esi
je 0x1018c3c2
mov edx, eax
mov eax, dword [esp + 0x10]
sub eax, edx
mov dword [esp + 0x2c], eax
lea eax, [edi + 0x4c]
mov edi, dword [esp + 0x2c]
mov dword [esp + 0x30], eax
nop
mov esi, dword [esp + 0x30]
lea edx, [edx + 1]
mov al, byte [edi + edx - 1]
mov byte [edx - 1], al
mov byte [esi + ecx], al
inc ecx
mov esi, dword [esp + 0x18]
cmp ecx, esi
jb 0x1018c3a0
mov edi, dword [esp + 0x20]
mov eax, dword [esp + 0x24]
mov edx, dword [esp + 0x10]
lea ecx, [esi + edx]
mov dword [esp + 0x24], ecx
lea ecx, [eax + 5]
add ecx, esi
lea eax, [esi + edx]
sub eax, ecx
mov dword [esp + 0x20], eax
mov eax, ecx
sub eax, dword [esp + 0x24]
cmp ecx, dword [esp + 0x24]
cmovbe eax, dword [esp + 0x20]
cmp eax, 0x7fff0000
ja 0x1018c400
mov ecx, dword [esp + 0x20]
mov byte [edi + esi + 0x2c], 0xe9
mov dword [edi + esi + 0x2d], ecx
jmp 0x1018c415
lea ecx, [edi + 0x2c]
add ecx, esi
lea eax, [ecx + 6]
mov word [ecx], 0x25ff
mov dword [ecx + 2], eax
lea ecx, [esi + edx]
mov dword [eax], ecx
mov ecx, dword [esp + 0x1c]
mov eax, edx
sub eax, dword [esp + 0x1c]
sub ecx, edx
cmp dword [esp + 0x1c], edx
mov edx, dword [esp + 0x1c]
cmovae eax, ecx
cmp eax, 0x7fff0000
jbe 0x1018c45f
lea esi, [edi + 0xc]
mov ecx, esi
call fcn.1018cc90
sub eax, edi
sub eax, 0xc
push eax
push esi
push dword [esp + 0x14]
call dword [sym.imp.KERNEL32.dll_FlushInstructionCache]
mov ecx, dword [esp + 0x10]
mov edx, esi
call fcn.1018cc90
mov esi, dword [esp + 0x18]
jmp 0x1018c468
mov ecx, dword [esp + 0x10]
call fcn.1018cc90
mov eax, dword [esp + 0x10]
mov dword [edi], eax
mov eax, dword [esp + 0x1c]
mov dword [edi + 8], eax
lea eax, [edi + 0x2c]
push esi
push eax
push dword [esp + 0x14]
mov dword [edi + 4], esi
call dword [sym.imp.KERNEL32.dll_FlushInstructionCache]
lea eax, [esp + 0x14]
push eax
push dword [esp + 0x18]
push 0x6c
push edi
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_VirtualProtectEx]
push esi
push dword [esp + 0x14]
push dword [esp + 0x14]
call dword [sym.imp.KERNEL32.dll_FlushInstructionCache]
lea eax, [esp + 0x28]
push eax
push dword [esp + 0x2c]
push esi
push dword [esp + 0x1c]
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_VirtualProtectEx]
cmp dword [edi], 0
je 0x1018c4db
mov ecx, dword [ebp + 8]
lea eax, [edi + 0x2c]
mov dword [ecx], eax
call fcn.1018c990
jmp 0x1018c069
xor eax, eax
nop dword [eax]
cmp dword [eax*4 + 0x10320ec0], edi
je 0x1018c4fb
inc eax
cmp eax, 0x40
jb 0x1018c4e0
xor edi, edi
call fcn.1018c990
jmp 0x1018c069
push 0x8000
push 0
push edi
mov dword [eax*4 + 0x10320ec0], 0
call dword [sym.imp.KERNEL32.dll_VirtualFree]
dec dword [0x10320eb8]
xor edi, edi
call fcn.1018c990
jmp 0x1018c069