Function at 0x100f1a30
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call
Print debug messages

Disassembly:
sub esp, 0x214
mov eax, dword [0x1036a00c]
xor eax, esp
mov dword [esp + 0x210], eax
push esi
mov esi, edx
test ecx, ecx
je 0x100f1cc4
test esi, esi
je 0x100f1cc4
cmp byte [0x1036ea7b], 0
push ebp
mov ebp, dword [ecx]
jne 0x100f1a75
push 0x1036f5d4
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
mov byte [0x1036ea7b], 1
push ebx
push edi
push 0x1036f5d4
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [esi], 0xffffffff
mov ebx, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
je 0x100f1c6d
cmp dword [esi + 8], 0
je 0x100f1aa7
push str.WARNING:_Attempting_to_patch_two_different_VTables_with_the_same_VTable_information__or_patching_the_same_interface_on_multiple_threads_n
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
jmp 0x100f1c61
mov eax, dword [esi]
mov edi, dword [ebp + eax*4]
mov eax, dword [esi + 4]
mov dword [esp + 0x14], eax
mov eax, dword [0x1036f8ac]
test eax, eax
jne 0x100f1af1
push 0x1036f894
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [0x1036f8ac], 0
jne 0x100f1ae5
push 0
push 0
push 0x40000
call dword [sym.imp.KERNEL32.dll_HeapCreate]
mov dword [0x1036f8ac], eax
push 0x1036f894
call ebx
mov eax, dword [0x1036f8ac]
push 0x24
push 0
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ebx, eax
test ebx, ebx
je 0x100f1cb1
mov eax, dword [esp + 0x14]
lea edx, [ebx + 0x20]
mov dword [edx], eax
lea ecx, [ebx + 6]
mov dword [ebx + 0x1c], ecx
lea eax, [ebx + 0x1c]
mov dword [ebx + 0x18], edi
mov edi, 0x25ff
mov dword [ebx + 0x14], 0x10000000
mov dword [ebx + 2], eax
mov eax, 0x35ff
mov word [ebx + 7], ax
lea eax, [ebx + 0x18]
push 0x14
push ebx
mov word [ebx], di
mov byte [ecx], 0x58
mov dword [ebx + 9], eax
mov byte [ebx + 0xd], 0x50
mov word [ebx + 0xe], di
mov dword [ebx + 0x10], edx
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_FlushInstructionCache]
xor al, al
xor edi, edi
mov byte [esp + 0x13], al
cmp edi, 3
jge 0x100f1be0
lea eax, [esp + 0x14]
mov dword [esp + 0x14], 0
push eax
mov eax, dword [esi]
push 0x40
push 4
lea eax, [eax*4]
add eax, ebp
push eax
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x100f1b95
call fcn.1001d720
jmp 0x100f1bd5
mov eax, dword [esi]
mov edx, ebx
mov eax, dword [ebp + eax*4]
mov dword [ebx + 0x18], eax
push eax
mov eax, dword [esi]
lea ecx, [eax*4]
add ecx, ebp
call fcn.100f1990
mov ecx, dword [esi]
add esp, 4
mov byte [esp + 0x13], al
lea eax, [esp + 0x14]
push eax
push dword [esp + 0x18]
lea ecx, [ecx*4]
push 4
add ecx, ebp
push ecx
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
mov al, byte [esp + 0x13]
inc edi
test al, al
je 0x100f1b62
jmp 0x100f1be8
test al, al
je 0x100f1c8f
cmp byte [0x10372b00], 0
mov dword [esi + 8], ebx
jne 0x100f1c5b
push 0x208
lea eax, [esp + 0x1c]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
lea eax, [esp + 0x18]
push 0x104
push eax
push 0x10000000
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
je 0x100f1c4f
lea eax, [esp + 0x14]
mov dword [esp + 0x14], 0
push eax
lea eax, [esp + 0x1c]
push eax
push 1
call dword [sym.imp.KERNEL32.dll_GetModuleHandleExW]
test eax, eax
jne 0x100f1c46
push str.ERROR:_Failed_to_pin_module__n
jmp 0x100f1c54
mov byte [0x10372b00], 1
jmp 0x100f1c5b
push str.ERROR:_Could_not_get_module_path._n
mov eax, dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
call eax
mov ebx, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
add esi, 0xc
cmp dword [esi], 0xffffffff
jne 0x100f1a91
push 0x1036f5d4
call ebx
xor eax, eax
pop edi
pop ebx
pop ebp
pop esi
mov ecx, dword [esp + 0x210]
xor ecx, esp
call fcn.102af9d5
add esp, 0x214
ret
push ebx
push 0
push dword [0x1036f8ac]
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
push 0x1036f5d4
call eax
mov eax, 0x80004005
jmp 0x100f1c76
mov eax, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
push 0x1036f5d4
call eax
mov eax, 0x8007000e
jmp 0x100f1c76
mov ecx, dword [esp + 0x214]
mov eax, 0x80070057
pop esi
xor ecx, esp
call fcn.102af9d5
add esp, 0x214
ret