Function at 0x1400146d0
Capabilities:
Create process on windows
Get common file path
Print debug messages
Write and execute a file
Write file on windows

Disassembly:
push rbp
push rsi
push rdi
push r14
push r15
lea rbp, [rsp - 0x1240]
mov eax, 0x1340
call fcn.14001a240
sub rsp, rax
mov qword [rsp + 0x60], 0xfffffffffffffffe
mov qword [rsp + 0x1380], rbx
mov rax, qword [0x14006c038]
xor rax, rsp
mov qword [rbp + 0x1230], rax
mov rdi, rdx
mov rbx, rcx
xor edx, edx
mov r8d, 0x400
lea rcx, [rbp + 0x30]
call fcn.14001cd80
test rdi, rdi
jne 0x140014732
xor eax, eax
jmp 0x140014c50
mov eax, dword [rbx + 0x3dc]
test eax, eax
jle 0x14001472b
dec eax
mov dword [rbx + 0x3dc], eax
lea r8, str.HKEY_LOCAL_MACHINE_
mov edx, 0x200
lea rcx, [rbp + 0x30]
call fcn.140031158
lea r8, str.SOFTWAREMicrosoftWindowsCurrentVersionMMDevicesAudioRender
mov edx, 0x200
lea rcx, [rbp + 0x30]
call fcn.1400310d4
lea r8, [0x14005d4c0]
mov edx, 0x200
lea rcx, [rbp + 0x30]
call fcn.1400310d4
mov r8, rdi
mov edx, 0x200
lea rcx, [rbp + 0x30]
call fcn.1400310d4
xor r15d, r15d
mov qword [rbp - 0x68], r15
lea r8, str.SOFTWAREMicrosoftWindowsCurrentVersionMMDevicesAudioRender
mov edx, 0x200
lea rcx, [rbp + 0x630]
call fcn.140031158
lea r8, [0x14005d4c0]
mov edx, 0x200
lea rcx, [rbp + 0x630]
call fcn.1400310d4
mov r8, rdi
mov edx, 0x200
lea rcx, [rbp + 0x630]
call fcn.1400310d4
lea r8, str.FxProperties_
mov edx, 0x200
lea rcx, [rbp + 0x630]
call fcn.1400310d4
lea r8, [0x14005d620]
mov edx, 0x200
lea rcx, [rbp + 0x630]
call fcn.1400310d4
lea r8, str.User
mov edx, 0x200
lea rcx, [rbp + 0x630]
call fcn.1400310d4
lea rax, [rbp - 0x68]
mov qword [rsp + 0x20], rax
mov r9d, 0x2001b
xor r8d, r8d
lea rdx, [rbp + 0x630]
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x14001488e
mov rcx, qword [rbp - 0x68]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea r8, str.FxProperties_
mov edx, 0x200
lea rcx, [rbp + 0x30]
call fcn.1400310d4
lea r8, [0x14005d620]
mov edx, 0x200
lea rcx, [rbp + 0x30]
call fcn.1400310d4
lea r8, str.User_n
jmp 0x140014895
lea r8, str.FxProperties_n
mov edx, 0x200
lea rcx, [rbp + 0x30]
call fcn.1400310d4
lea r8, str._2B24BE42_A892_11DC_8314_0800200C9A66_2__REG_DWORD_0
mov edx, 0x200
lea rcx, [rbp + 0x30]
call fcn.1400310d4
mov ecx, 0x18
call fcn.14001986c
mov rbx, rax
mov qword [rsp + 0x70], rax
test rax, rax
je 0x1400148fb
xor eax, eax
mov qword [rbx], rax
mov qword [rbx + 0x10], rax
mov qword [rbx + 8], r15
mov dword [rbx + 0x10], 1
lea rcx, [rbp + 0x30]
call qword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov qword [rbx], rax
test rax, rax
je 0x140014c81
jmp 0x1400148fe
mov rbx, r15
mov qword [rbp - 0x50], rbx
test rbx, rbx
je 0x140014c76
mov rdi, qword [rbx + 8]
test rdi, rdi
jne 0x140014923
mov rcx, qword [rbx]
call fcn.140019590
mov rdi, rax
mov qword [rbx + 8], rax
mov dword [rbp - 0x54], r15d
mov edx, 0x100
lea rcx, [rbp + 0x430]
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
lea r9, [rbp + 0x430]
lea r8, str._sk2_restore.txt
mov edx, 0x200
lea rcx, [rbp + 0x430]
call fcn.140002050
mov qword [rsp + 0x30], r15
mov dword [rsp + 0x28], r15d
mov dword [rsp + 0x20], 2
xor r9d, r9d
mov edx, 0xc0000000
lea r8d, [r9 + 3]
lea rcx, [rbp + 0x430]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov r14, rax
mov rsi, 0xffffffffffffffff
cmp rax, rsi
je 0x1400149bd
mov r8, rsi
inc r8
cmp byte [rdi + r8], 0
jne 0x140014995
mov qword [rsp + 0x20], r15
lea r9, [rbp - 0x54]
mov rdx, rdi
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov qword [rsp + 0x68], r15
mov qword [rbp - 0x60], r15
mov qword [rsp + 0x78], r15
mov edx, 0x200
lea rcx, [rbp + 0xa30]
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
lea rax, [rbp + 0x430]
mov qword [rsp + 0x20], rax
lea r9, [rbp + 0xa30]
lea r8, str._s_regini.exe__s
mov edx, 0x400
lea rcx, [rbp + 0xa30]
call fcn.140002050
xor edx, edx
lea r8d, [rdx + 0x64]
lea rcx, [rbp - 0x3c]
call fcn.14001cd80
mov dword [rbp - 0x40], 0x68
xor eax, eax
mov qword [rbp - 0x80], rax
mov qword [rbp - 0x78], rax
mov qword [rbp - 0x70], rax
call qword [sym.imp.KERNEL32.dll_WTSGetActiveConsoleSessionId]
mov ecx, eax
lea rdx, [rsp + 0x68]
call qword [sym.imp.WTSAPI32.dll_WTSQueryUserToken]
lea rax, [rbp - 0x60]
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], 1
mov r9d, 1
xor r8d, r8d
mov edx, 0x2000000
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.ADVAPI32.dll_DuplicateTokenEx]
test eax, eax
je 0x140014c11
mov qword [rsp + 0x70], r15
mov dword [rbp - 0x58], 8
lea rax, [rbp - 0x58]
mov qword [rsp + 0x20], rax
mov r9d, 8
lea r8, [rsp + 0x70]
lea edx, [r9 + 0xb]
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.ADVAPI32.dll_GetTokenInformation]
test eax, eax
je 0x140014b61
lea rax, [rsp + 0x78]
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], 1
mov r9d, 2
xor r8d, r8d
mov edx, 0x2000000
mov rcx, qword [rsp + 0x70]
call qword [sym.imp.ADVAPI32.dll_DuplicateTokenEx]
test eax, eax
je 0x140014b4e
lea rax, [rbp - 0x80]
mov qword [rsp + 0x50], rax
lea rax, [rbp - 0x40]
mov qword [rsp + 0x48], rax
mov qword [rsp + 0x40], r15
mov qword [rsp + 0x38], r15
mov dword [rsp + 0x30], 0x8000000
mov dword [rsp + 0x28], r15d
mov qword [rsp + 0x20], r15
xor r9d, r9d
lea r8, [rbp + 0xa30]
xor edx, edx
mov rcx, qword [rsp + 0x78]
call qword [sym.imp.ADVAPI32.dll_CreateProcessAsUserW]
test eax, eax
je 0x140014b43
mov edx, 0x1388
mov rcx, qword [rbp - 0x80]
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, qword [rbp - 0x80]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbp - 0x78]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x78]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x70]
test rcx, rcx
je 0x140014bf1
jmp 0x140014beb
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r9d, eax
lea r8, str.GetTokenInformation_fail:__d_r_n
mov edx, 0x400
lea rcx, [rbp + 0xe30]
call fcn.140002050
lea rcx, [rbp + 0xe30]
call qword [sym.imp.KERNEL32.dll_OutputDebugStringW]
lea rax, [rbp - 0x80]
mov qword [rsp + 0x48], rax
lea rax, [rbp - 0x40]
mov qword [rsp + 0x40], rax
mov qword [rsp + 0x38], r15
mov qword [rsp + 0x30], r15
mov dword [rsp + 0x28], r15d
mov dword [rsp + 0x20], r15d
xor r9d, r9d
xor r8d, r8d
lea rdx, [rbp + 0xa30]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x140014bf1
mov edx, 0x1388
mov rcx, qword [rbp - 0x80]
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, qword [rbp - 0x80]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbp - 0x78]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x68]
test rcx, rcx
je 0x140014c01
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbp - 0x60]
test rcx, rcx
je 0x140014c11
call qword [sym.imp.KERNEL32.dll_CloseHandle]
nop
lock xadd dword [rbx + 0x10], esi
cmp esi, 1
jne 0x140014c4b
mov rcx, qword [rbx]
test rcx, rcx
je 0x140014c2c
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
mov qword [rbx], r15
mov rcx, qword [rbx + 8]
test rcx, rcx
je 0x140014c3e
call fcn.140019864
mov qword [rbx + 8], r15
mov edx, 0x18
mov rcx, rbx
call fcn.140019864
mov eax, 1
mov rcx, qword [rbp + 0x1230]
xor rcx, rsp
call fcn.140019840
mov rbx, qword [rsp + 0x1380]
add rsp, 0x1340
pop r15
pop r14
pop rdi
pop rsi
pop rbp
ret
mov ecx, 0x8007000e
call fcn.140019580
nop
mov ecx, 0x8007000e
call fcn.140019580
int3