Function at 0x18003be74
Capabilities:
Allocate or change rwx memory

Disassembly:
mov qword [rsp + 0x10], rbx
push rbp
push rsi
push rdi
sub rsp, 0x30
mov ebx, r8d
mov rsi, rdx
mov rdi, rcx
test rcx, rcx
je 0x18003c0e7
test rdx, rdx
je 0x18003c110
test r8d, r8d
je 0x18003c139
lea r9, [rsp + 0x50]
mov r8d, 0x40
mov edx, ebx
mov ebp, ebx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
je 0x18003bfc2
sub ebx, 1
je 0x18003bf96
sub ebx, 1
je 0x18003bf5e
sub ebx, 2
je 0x18003bf28
cmp ebx, 4
je 0x18003bef0
mov r8d, ebp
mov rdx, rsi
mov rcx, rdi
call sub.VCRUNTIME140.dll_memcpy
jmp 0x18003bf9a
test dil, 7
je 0x18003bf20
lea rcx, str.C:UsersSethDesktopcodeStarfield_Console_Replacer_srchook_api.cpp
mov al, 0x43
lea rdx, str.C:UsersSethDesktopcodeStarfield_Console_Replacer_srchook_api.cpp
cmp al, 0x5c
je 0x18003bf0e
cmp al, 0x2f
jne 0x18003bf11
mov rdx, rcx
inc rcx
mov al, byte [rcx]
test al, al
je 0x18003bfeb
jmp 0x18003bf06
mov rax, qword [rsi]
mov qword [rdi], rax
jmp 0x18003bf9a
test dil, 3
je 0x18003bf58
lea rcx, str.C:UsersSethDesktopcodeStarfield_Console_Replacer_srchook_api.cpp
mov al, 0x43
lea rdx, str.C:UsersSethDesktopcodeStarfield_Console_Replacer_srchook_api.cpp
cmp al, 0x5c
je 0x18003bf46
cmp al, 0x2f
jne 0x18003bf49
mov rdx, rcx
inc rcx
mov al, byte [rcx]
test al, al
je 0x18003c03f
jmp 0x18003bf3e
mov eax, dword [rsi]
mov dword [rdi], eax
jmp 0x18003bf9a
test dil, 1
je 0x18003bf8e
lea rcx, str.C:UsersSethDesktopcodeStarfield_Console_Replacer_srchook_api.cpp
mov al, 0x43
lea rdx, str.C:UsersSethDesktopcodeStarfield_Console_Replacer_srchook_api.cpp
cmp al, 0x5c
je 0x18003bf7c
cmp al, 0x2f
jne 0x18003bf7f
mov rdx, rcx
inc rcx
mov al, byte [rcx]
test al, al
je 0x18003c093
jmp 0x18003bf74
movzx eax, word [rsi]
mov word [rdi], ax
jmp 0x18003bf9a
mov al, byte [rsi]
mov byte [rdi], al
mov r8d, dword [rsp + 0x50]
lea r9, [rsp + 0x68]
mov rdx, rbp
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
mov rbx, qword [rsp + 0x58]
test eax, eax
setne al
add rsp, 0x30
pop rdi
pop rsi
pop rbp
ret
lea rcx, str.C:UsersSethDesktopcodeStarfield_Console_Replacer_srchook_api.cpp
call fcn.18003a814
mov rcx, rax
lea rdx, str.SafeWriteMemory
lea r9, str._false___virtualprotect_failed_
mov r8d, 0x35
call fcn.18003e0c0
int3
lea rcx, [rdx + 1]
mov qword [rsp + 0x28], rdi
lea rdx, str.VolatileWrite
mov qword [rsp + 0x20], 8
lea r9, str._ERROR:_write__u_bytes_to_address__p_is_not_atomic
mov r8d, 0x25
call fcn.18003def0
lea rcx, str.C:UsersSethDesktopcodeStarfield_Console_Replacer_srchook_api.cpp
call fcn.18003a814
mov rcx, rax
lea rdx, str.VolatileWrite
lea r9, str._false___Unaligned_write_to_atomic_memory_is_not_atomic____
mov r8d, 0x26
call fcn.18003e0c0
int3
lea rcx, [rdx + 1]
mov qword [rsp + 0x28], rdi
lea rdx, str.VolatileWrite
mov qword [rsp + 0x20], 4
lea r9, str._ERROR:_write__u_bytes_to_address__p_is_not_atomic
mov r8d, 0x25
call fcn.18003def0
lea rcx, str.C:UsersSethDesktopcodeStarfield_Console_Replacer_srchook_api.cpp
call fcn.18003a814
mov rcx, rax
lea rdx, str.VolatileWrite
lea r9, str._false___Unaligned_write_to_atomic_memory_is_not_atomic____
mov r8d, 0x26
call fcn.18003e0c0
int3
lea rcx, [rdx + 1]
mov qword [rsp + 0x28], rdi
lea rdx, str.VolatileWrite
mov qword [rsp + 0x20], 2
lea r9, str._ERROR:_write__u_bytes_to_address__p_is_not_atomic
mov r8d, 0x25
call fcn.18003def0
lea rcx, str.C:UsersSethDesktopcodeStarfield_Console_Replacer_srchook_api.cpp
call fcn.18003a814
mov rcx, rax
lea rdx, str.VolatileWrite
lea r9, str._false___Unaligned_write_to_atomic_memory_is_not_atomic____
mov r8d, 0x26
call fcn.18003e0c0
int3
lea rcx, str.C:UsersSethDesktopcodeStarfield_Console_Replacer_srchook_api.cpp
call fcn.18003a814
mov rcx, rax
lea rdx, str.SafeWriteMemory
lea r9, str._dest___NULL
mov r8d, 0x30
call fcn.18003e0c0
int3
lea rcx, str.C:UsersSethDesktopcodeStarfield_Console_Replacer_srchook_api.cpp
call fcn.18003a814
mov rcx, rax
lea rdx, str.SafeWriteMemory
lea r9, str._src___NULL
mov r8d, 0x31
call fcn.18003e0c0
int3
lea rcx, str.C:UsersSethDesktopcodeStarfield_Console_Replacer_srchook_api.cpp
call fcn.18003a814
mov rcx, rax
lea rdx, str.SafeWriteMemory
lea r9, str._length___0
mov r8d, 0x32
call fcn.18003e0c0
int3