Function at 0x403e70
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x45e30d
mov eax, dword fs:[0]
push eax
sub esp, 0xa8
mov eax, dword [0x46d040]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov byte [ebp - 0x1c], 0xc7
mov byte [ebp - 0x1b], 0x47
mov byte [ebp - 0x1a], 0xc
mov eax, dword [ebp + 0x14]
and eax, 0xff
mov byte [ebp - 0x19], al
mov ecx, dword [ebp + 0x14]
shr ecx, 8
and ecx, 0xff
mov byte [ebp - 0x18], cl
mov edx, dword [ebp + 0x14]
shr edx, 0x10
and edx, 0xff
mov byte [ebp - 0x17], dl
mov eax, dword [ebp + 0x14]
shr eax, 0x18
and eax, 0xff
mov byte [ebp - 0x16], al
mov byte [ebp - 0x15], 0xe9
mov byte [ebp - 0x14], 0
mov byte [ebp - 0x13], 0
mov byte [ebp - 0x12], 0
mov byte [ebp - 0x11], 0
mov ecx, dword [ebp + 0xc]
add ecx, 0x9a14ab
mov dword [ebp - 0x40], ecx
mov dword [ebp - 0x3c], 0xc
movzx edx, byte [ebp + 0x10]
test edx, edx
je 0x404215
cmp dword [0x508c40], 0
jne 0x403f77
mov eax, dword [ebp - 0x3c]
add eax, 0xa
mov dword [0x508c1c], eax
push 0x40
push 0x3000
mov ecx, dword [0x508c1c]
push ecx
push 0
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.KERNEL32.dll_VirtualAllocEx]
mov dword [0x508c40], eax
cmp dword [0x508c40], 0
jne 0x403f77
push 0x46057c
mov eax, dword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
push eax
call fcn.004118c0
add esp, 8
mov dword [ebp - 0x50], eax
push 0x411d00
mov ecx, dword [ebp - 0x50]
call dword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______thiscall_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char_______cdecl___class_std::basic_ostream_char__struct_std::char_traits_char_____]
nop
jmp 0x40425e
mov ecx, dword [0x508c40]
mov dword [ebp - 0x4c], ecx
mov edx, dword [ebp - 0x40]
add edx, 5
mov dword [ebp - 0xa8], edx
mov eax, dword [ebp - 0x40]
add eax, 5
mov ecx, dword [ebp - 0x4c]
sub ecx, eax
mov dword [ebp - 0x34], ecx
xor edx, edx
mov dword [ebp - 0x30], edx
mov dword [ebp - 0x2c], edx
mov dword [ebp - 0x28], edx
lea eax, [ebp - 0x45]
mov dword [ebp - 0x54], eax
mov ecx, dword [ebp - 0x54]
mov dword [ebp - 0xb4], ecx
mov edx, dword [0x508c1c]
mov dword [ebp - 0x5c], edx
lea eax, [ebp - 0x30]
mov dword [ebp - 0x58], eax
mov ecx, dword [ebp - 0x58]
mov dword [ebp - 0x44], ecx
mov edx, dword [ebp - 0x44]
mov dword [edx], 0
mov eax, dword [ebp - 0x44]
mov dword [eax + 4], 0
mov ecx, dword [ebp - 0x44]
mov dword [ecx + 8], 0
mov edx, dword [ebp - 0x5c]
push edx
lea ecx, [ebp - 0x30]
call fcn.004131b0
nop
mov dword [ebp - 4], 0
mov eax, dword [ebp - 0x30]
mov dword [ebp - 0x60], eax
mov ecx, dword [ebp - 0x60]
mov dword [ebp - 0x64], ecx
mov edx, dword [ebp - 0x64]
mov dword [ebp - 0x68], edx
mov eax, dword [ebp - 0x68]
mov ecx, dword [0x5082b0]
mov dword [eax], ecx
mov dl, byte [0x5082b4]
mov byte [eax + 4], dl
mov eax, dword [ebp - 0x30]
mov dword [ebp - 0x6c], eax
mov ecx, dword [ebp - 0x6c]
mov dword [ebp - 0x70], ecx
mov edx, dword [ebp - 0x70]
mov dword [ebp - 0xac], edx
mov eax, dword [ebp - 0x3c]
push eax
lea ecx, [ebp - 0x1c]
push ecx
mov edx, dword [ebp - 0xac]
add edx, 5
push edx
call sub.VCRUNTIME140.dll_memcpy
add esp, 0xc
mov eax, dword [ebp - 0x3c]
mov ecx, dword [ebp - 0x4c]
lea edx, [ecx + eax + 0xa]
mov eax, dword [ebp - 0xa8]
sub eax, edx
mov dword [ebp - 0x38], eax
lea ecx, [ebp - 0x30]
mov dword [ebp - 0x9c], ecx
mov edx, dword [ebp - 0x9c]
mov eax, dword [edx]
mov ecx, dword [ebp - 0x3c]
lea edx, [eax + ecx + 5]
mov dword [ebp - 0x7c], edx
mov eax, dword [ebp - 0x7c]
mov byte [eax], 0xe9
mov ecx, dword [ebp - 0x30]
mov dword [ebp - 0xb0], ecx
mov edx, dword [ebp - 0xb0]
mov dword [ebp - 0x74], edx
mov eax, dword [ebp - 0x74]
mov dword [ebp - 0x78], eax
mov ecx, dword [ebp - 0x78]
add ecx, dword [ebp - 0x3c]
mov edx, dword [ebp - 0x38]
mov dword [ecx + 6], edx
mov eax, dword [0x508c1c]
mov dword [ebp - 0x8c], eax
mov ecx, dword [ebp - 0x30]
mov dword [ebp - 0x80], ecx
mov edx, dword [ebp - 0x80]
mov dword [ebp - 0x84], edx
mov eax, dword [ebp - 0x84]
mov dword [ebp - 0x88], eax
mov ecx, dword [ebp - 0x88]
mov dword [ebp - 0x90], ecx
mov edx, dword [0x508c40]
mov dword [ebp - 0x94], edx
mov eax, dword [ebp - 0x8c]
push eax
mov ecx, dword [ebp - 0x90]
push ecx
mov edx, dword [ebp - 0x94]
push edx
mov eax, dword [ebp + 8]
push eax
call fcn.00403970
add esp, 0x10
movzx ecx, al
test ecx, ecx
jne 0x404170
push str.Failed_to_write_trampoline_to_allocated_memory.
mov edx, dword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
push edx
call fcn.004118c0
add esp, 8
mov dword [ebp - 0x98], eax
push 0x411d00
mov ecx, dword [ebp - 0x98]
call dword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______thiscall_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char_______cdecl___class_std::basic_ostream_char__struct_std::char_traits_char_____]
push 0x8000
push 0
mov eax, dword [0x508c40]
push eax
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_VirtualFreeEx]
mov dword [0x508c40], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x30]
call fcn.004101d0
nop
jmp 0x40425e
mov byte [ebp - 0x24], 0xe9
xor edx, edx
mov dword [ebp - 0x23], edx
mov eax, 1
shl eax, 0
mov ecx, dword [ebp - 0x34]
mov dword [ebp + eax - 0x24], ecx
push 5
lea edx, [ebp - 0x24]
push edx
mov eax, dword [ebp - 0x40]
push eax
mov ecx, dword [ebp + 8]
push ecx
call fcn.00403970
add esp, 0x10
movzx edx, al
test edx, edx
jne 0x404203
push str.Failed_to_write_jump_to_trampoline.
mov eax, dword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
push eax
call fcn.004118c0
add esp, 8
mov dword [ebp - 0xa0], eax
push 0x411d00
mov ecx, dword [ebp - 0xa0]
call dword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______thiscall_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char_______cdecl___class_std::basic_ostream_char__struct_std::char_traits_char_____]
push 0x8000
push 0
mov ecx, dword [0x508c40]
push ecx
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.KERNEL32.dll_VirtualFreeEx]
mov dword [0x508c40], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x30]
call fcn.004101d0
nop
jmp 0x40425e
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x30]
call fcn.004101d0
nop
jmp 0x40425e
push 5
push 0x5082b0
mov eax, dword [ebp - 0x40]
push eax
mov ecx, dword [ebp + 8]
push ecx
call fcn.00403970
add esp, 0x10
movzx edx, al
test edx, edx
jne 0x40425e
push str.Failed_to_restore_original_bytes.
mov eax, dword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
push eax
call fcn.004118c0
add esp, 8
mov dword [ebp - 0xa4], eax
push 0x411d00
mov ecx, dword [ebp - 0xa4]
call dword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______thiscall_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char_______cdecl___class_std::basic_ostream_char__struct_std::char_traits_char_____]
nop
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0045caa8
mov esp, ebp
pop ebp
ret