Function at 0x140005410
Capabilities:
Delete registry key
Delete registry value
Print debug messages
Read file on windows
Write file on windows

Disassembly:
mov qword [rsp + 8], rbx
push rbp
push rsi
push rdi
push r12
push r13
sub rsp, 0x4d0
xor eax, eax
xor r13d, r13d
mov r12, rcx
mov rdi, r8
lea rcx, [rsp + 0xc4]
xor edx, edx
mov r8d, 0x400
mov dword [rsp + 0xb0], r13d
mov dword [rsp + 0xb4], eax
mov qword [rsp + 0xb8], rax
mov word [rsp + 0x50], r13w
mov qword [rsp + 0x52], rax
mov dword [rsp + 0x5a], eax
mov word [rsp + 0x5e], ax
mov word [rsp + 0x60], r13w
mov qword [rsp + 0x62], rax
mov dword [rsp + 0x6a], eax
mov word [rsp + 0x6e], ax
mov dword [rsp + 0xc0], r13d
call fcn.14000aca0
mov edx, dword [rdi + 0xc]
xor ecx, ecx
call qword [sym.imp.ntoskrnl.exe_ExAllocatePool]
mov r8d, dword [rdi + 0xc]
xor edx, edx
mov rcx, rax
mov rbp, rax
call fcn.14000aca0
mov esi, dword [rdi + 0xc]
mov edi, 0xc0000001
mov ebx, r13d
test esi, esi
je 0x140005527
nop word [rax + rax]
xor eax, eax
mov qword [rsp + 0x40], r13
mov qword [rsp + 0x38], r13
mov qword [rsp + 0xa0], rax
mov qword [rsp + 0xa8], rax
mov ecx, esi
sub ecx, ebx
mov eax, ebx
xor r9d, r9d
mov dword [rsp + 0x30], ecx
add rax, rbp
xor r8d, r8d
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0xa0]
xor edx, edx
mov rcx, r12
mov qword [rsp + 0x20], rax
call qword [sym.imp.ntoskrnl.exe_ZwReadFile]
mov edi, eax
test eax, eax
jns 0x140005519
cmp eax, 0x80000005
jne 0x140005527
add ebx, dword [rsp + 0xa8]
mov edi, r13d
cmp ebx, esi
jb 0x1400054c0
test edi, edi
js 0x1400056b2
lea rcx, [rsp + 0x50]
mov rdx, rbp
call qword [sym.imp.ntoskrnl.exe_RtlInitUnicodeString]
lea rdi, [rbp + 0x800]
lea rcx, [rsp + 0x60]
mov rdx, rdi
call qword [sym.imp.ntoskrnl.exe_RtlInitUnicodeString]
xor eax, eax
or rcx, 0xffffffffffffffff
repne scasw ax, word [rdi]
lea rax, [rsp + 0x50]
xor r9d, r9d
not rcx
mov qword [rsp + 0x80], rax
lea rax, [rsp + 0x510]
mov qword [rsp + 0x30], rax
cmp rcx, 1
mov dword [rsp + 0x28], r13d
lea rcx, [rsp + 0x518]
mov qword [rsp + 0x518], r13
mov dword [rsp + 0x70], 0x30
mov qword [rsp + 0x78], r13
mov dword [rsp + 0x88], 0x240
mov qword [rsp + 0x90], r13
mov qword [rsp + 0x98], r13
lea r8, [rsp + 0x70]
mov edx, 0x10000
mov qword [rsp + 0x20], r13
jne 0x1400055f5
call qword [sym.imp.ntoskrnl.exe_ZwCreateKey]
mov edi, eax
test eax, eax
jns 0x1400055e5
cmp eax, 0xc0000034
jne 0x140005622
mov edi, r13d
jmp 0x140005622
mov rcx, qword [rsp + 0x518]
call qword [sym.imp.ntoskrnl.exe_ZwDeleteKey]
jmp 0x140005620
call qword [sym.imp.ntoskrnl.exe_ZwCreateKey]
mov edi, eax
test eax, eax
jns 0x14000560d
cmp eax, 0xc0000034
jne 0x140005622
mov edi, r13d
jmp 0x140005622
mov rcx, qword [rsp + 0x518]
lea rdx, [rsp + 0x60]
call qword [sym.imp.ntoskrnl.exe_ZwDeleteValueKey]
mov edi, eax
mov rcx, qword [rsp + 0x518]
test rcx, rcx
je 0x14000563d
call qword [sym.imp.ntoskrnl.exe_ZwClose]
mov qword [rsp + 0x518], r13
test edi, edi
jns 0x140005657
cmp edi, 0xc0000034
je 0x140005657
lea rcx, str.DeleteRegistryKeyOrValue_failed__status___08x_n
mov edx, edi
call sub.ntoskrnl.exe_DbgPrint
mov qword [rsp + 0x40], r13
mov eax, r13d
mov qword [rsp + 0x38], r13
mov dword [rsp + 0x30], 0x404
test edi, edi
mov rcx, r12
setns al
xor r9d, r9d
xor r8d, r8d
mov dword [rsp + 0xc0], eax
lea rax, [rsp + 0xc0]
xor edx, edx
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0xb0]
mov dword [rsp + 0xc4], edi
mov qword [rsp + 0x20], rax
call qword [sym.imp.ntoskrnl.exe_ZwWriteFile]
mov edi, eax
test eax, eax
cmovns edi, r13d
test rbp, rbp
je 0x1400056c2
xor edx, edx
mov rcx, rbp
call qword [sym.imp.ntoskrnl.exe_ExFreePoolWithTag]
mov eax, edi
mov rbx, qword [rsp + 0x500]
add rsp, 0x4d0
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret