Function at 0x14000508c
Capabilities:
Attach user process memory
Find process by pid

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x18], rsi
push rbp
push rdi
push r12
push r13
push r15
lea rbp, [rsp - 0x37]
sub rsp, 0xb0
mov rax, qword [0x140012010]
xor rax, rsp
mov qword [rbp + 0x27], rax
xor ebx, ebx
mov qword [rbp - 0x11], 0xfffffffffff0bdc0
mov rsi, rdx
mov qword [rbp - 0x39], rbx
mov rdx, qword [rdx + 8]
mov r12d, ebx
mov qword [rbp - 0x29], rbx
or rax, 0xffffffffffffffff
mov r13, rcx
inc rax
cmp word [rdx + rax*2], bx
jne 0x1400050db
lea rdi, [rax*2 + 2]
mov r8, rdi
lea rdx, [rbp - 0x29]
lea rcx, [rbp - 0x21]
call fcn.140003804
mov r15, qword [rsi + 8]
mov qword [rbp - 0x31], rbx
test r15, r15
je 0x1400052f2
cmp qword [rbp - 0x21], rbx
je 0x1400052f2
cmp rdi, qword [rbp - 0x19]
jbe 0x140005127
mov ebx, 0xc000000d
jmp 0x1400052f7
call qword [sym.imp.ntoskrnl.exe_IoGetCurrentProcess]
mov rbx, rax
call qword [sym.imp.ntoskrnl.exe_IoGetCurrentProcess]
mov r9, qword [rbp - 0x21]
lea rcx, [rbp - 0x31]
mov qword [rsp + 0x30], rcx
mov r8, rbx
mov byte [rsp + 0x28], r12b
mov rcx, rax
mov rdx, r15
mov qword [rsp + 0x20], rdi
call sub.ntoskrnl.exe_MmCopyVirtualMemory
xor r15d, r15d
mov ebx, eax
test eax, eax
js 0x140005176
mov rax, qword [rbp - 0x31]
sub rax, rdi
neg rax
sbb ebx, ebx
and ebx, 0xc0000206
test ebx, ebx
js 0x1400052fa
mov ecx, dword [rsi]
lea rdx, [rbp - 0x39]
call qword [sym.imp.ntoskrnl.exe_PsLookupProcessByProcessId]
mov ebx, eax
test eax, eax
js 0x1400052fa
mov rcx, qword [rbp - 0x39]
lea rdx, [rbp - 9]
call qword [sym.imp.ntoskrnl.exe_KeStackAttachProcess]
mov rcx, qword [rbp - 0x39]
call sub.ntoskrnl.exe_PsGetProcessPeb
mov rsi, rax
test rax, rax
jne 0x1400051d1
lea rcx, [rbp - 9]
call qword [sym.imp.ntoskrnl.exe_KeUnstackDetachProcess]
mov rcx, qword [rbp - 0x39]
call qword [sym.imp.ntoskrnl.exe_ObfDereferenceObject]
mov ebx, 0x80
jmp 0x1400052fa
mov rax, qword [rax + 0x18]
mov ebx, r15d
jmp 0x1400051f3
cmp ebx, 0xa
jge 0x1400051b3
lea r8, [rbp - 0x11]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.ntoskrnl.exe_KeDelayExecutionThread]
mov rax, qword [rsi + 0x18]
inc ebx
test rax, rax
je 0x1400051da
add rax, 0x10
je 0x1400051b3
mov rdi, qword [rax]
mov ebx, 0xc0000225
jmp 0x14000523c
test rdi, rdi
je 0x140005231
movzx eax, word [rdi + 0x48]
test ax, ax
je 0x140005231
mov rdx, qword [rbp - 0x29]
mov r8d, eax
mov rcx, qword [rdi + 0x50]
shr r8, 1
sub r8, 4
call sub.ntoskrnl.exe__wcsnicmp
test eax, eax
je 0x14000526f
mov rax, qword [rsi + 0x18]
mov rdi, qword [rdi]
add rax, 0x10
cmp rdi, rax
jne 0x140005208
lea rcx, [rbp - 9]
call qword [sym.imp.ntoskrnl.exe_KeUnstackDetachProcess]
test ebx, ebx
js 0x140005260
mov rdx, qword [rbp - 0x39]
mov r8, r12
mov rcx, r13
call fcn.140006400
mov ebx, eax
mov rcx, qword [rbp - 0x39]
call qword [sym.imp.ntoskrnl.exe_ObfDereferenceObject]
jmp 0x1400052fa
mov rcx, qword [rdi]
mov r12, qword [rdi + 0x30]
cmp qword [rcx + 8], rdi
jne 0x1400052eb
mov rax, qword [rdi + 8]
cmp qword [rax], rdi
jne 0x1400052eb
mov qword [rax], rcx
mov qword [rcx + 8], rax
lea rax, [rdi + 0x20]
mov rdx, qword [rax]
cmp qword [rdx + 8], rax
jne 0x1400052eb
mov rcx, qword [rax + 8]
cmp qword [rcx], rax
jne 0x1400052eb
mov qword [rcx], rdx
lea rax, [rdi + 0x10]
mov qword [rdx + 8], rcx
mov rdx, qword [rax]
cmp qword [rdx + 8], rax
jne 0x1400052eb
mov rcx, qword [rax + 8]
cmp qword [rcx], rax
jne 0x1400052eb
mov qword [rcx], rdx
add rdi, 0x70
mov qword [rdx + 8], rcx
mov rcx, qword [rdi]
cmp qword [rcx + 8], rdi
jne 0x1400052eb
mov rax, qword [rdi + 8]
cmp qword [rax], rdi
jne 0x1400052eb
mov qword [rax], rcx
mov ebx, r15d
mov qword [rcx + 8], rax
jmp 0x140005241
mov ecx, 3
int 0x29
mov ebx, 0xc0000206
xor r15d, r15d
cmp qword [rbp - 0x21], r15
je 0x14000530f
mov rcx, qword [rbp - 0x21]
mov edx, 0x6864694e
call qword [sym.imp.ntoskrnl.exe_ExFreePoolWithTag]
mov eax, ebx
mov rcx, qword [rbp + 0x27]
xor rcx, rsp
call fcn.14000e590
lea r11, [rsp + 0xb0]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r13
pop r12
pop rdi
pop rbp
ret