Function at 0x140058c60
Capabilities:
Persist via run registry key

Disassembly:
push rbp
push rdi
push r14
lea rbp, [rsp - 0x15a0]
mov eax, 0x16a0
call fcn.14006ee90
sub rsp, rax
mov qword [rsp + 0x40], 0xfffffffffffffffe
mov qword [rsp + 0x16d0], rbx
mov qword [rsp + 0x16d8], rsi
mov rax, qword [0x1400bb008]
xor rax, rsp
mov qword [rbp + 0x1590], rax
mov esi, edx
mov rbx, rcx
call fcn.140008300
test dword [rax + 0xb8], 0x800000
je 0x140058e82
test esi, esi
jne 0x140058ce8
mov dword [rsp + 0x48], 1
lea r8, [rsp + 0x48]
lea edx, [rsi + 1]
lea rcx, str.schtasks__TN_RtkAudUService64_BG
call fcn.140020160
cmp dword [rsp + 0x48], esi
je 0x14005904f
xor ecx, ecx
lea rdx, [0x140081d58]
nop dword [rax]
nop word [rax + rax]
movzx eax, word [rcx + rdx]
mov word [rbp + rcx + 0x170], ax
lea rcx, [rcx + 2]
test ax, ax
jne 0x140058d00
xor ecx, ecx
lea r14, str.RtkAudUService64_BG
nop
movzx eax, word [rcx + r14]
mov word [rbp + rcx + 0x380], ax
lea rcx, [rcx + 2]
test ax, ax
jne 0x140058d20
lea r8, str.SoftwareMicrosoftWindowsCurrentVersionRun
mov edx, 0x800
lea rcx, [rbp + 0x590]
call fcn.140012e80
mov dword [rsp + 0x4c], 0
call fcn.140008300
test dword [rax + 0x40], 0x20000000
je 0x140058d73
call fcn.140008300
movzx r8d, byte [rax + 0x173]
jmp 0x140058d79
mov r8d, 0x1e
lea r9, str._background
mov rcx, r14
call fcn.14001fd10
mov dword [rsp + 0x4c], eax
mov r9, r14
lea r8, str.RunCplByTaskScheduler__s
mov edx, 0x104
lea rcx, [rsp + 0x60]
call fcn.140012e80
lea r8, [rsp + 0x4c]
lea rdx, [rsp + 0x60]
call fcn.14001f8d0
lea rdi, str.SetScheduler_at_FirstTime
test esi, esi
jne 0x140058dfa
xor r9d, r9d
mov r8, rdi
lea rdx, str.DebugLog
lea rcx, [0x1400bf590]
call fcn.140003a40
cmp eax, 1
jne 0x140058dfa
mov r9d, eax
lea r8, str.SetScheduler_EntryDisappear
lea rdx, str.DebugLog
lea rcx, [0x1400bf590]
call fcn.140003b10
mov dword [rsp + 0x50], 1
lea r8, [rsp + 0x50]
mov edx, 1
lea rcx, str.schtasks__TN_RtkAudUService64_BG
call fcn.140020160
cmp dword [rsp + 0x50], 0
je 0x140058e35
lea rax, str.AlreadySetScheduler_but_NoEntry_at_FirstTime
lea r8, str.AlreadySetScheduler_but_NoEntry
test esi, esi
cmovne r8, rax
jmp 0x140058e42
lea r8, str.SetScheduler
test esi, esi
cmovne r8, rdi
mov r9d, 1
lea rdx, str.DebugLog
lea rcx, [0x1400bf590]
call fcn.140003b10
mov dword [rbx + 0x17c], 1
call fcn.1400085d0
mov rcx, rax
mov edx, 0x400
mov r8d, 0x7918
call fcn.14005ea10
jmp 0x14005904f
call fcn.1400429e0
mov r14d, eax
test eax, eax
je 0x140058e96
test esi, esi
je 0x140058fbb
call fcn.140003520
mov rcx, rax
test rax, rax
je 0x140059076
mov rax, qword [rax]
call qword [rax + reloc.OLEAUT32.dll_SafeArrayGetElement]
add rax, 0x18
mov qword [rsp + 0x58], rax
call fcn.140004830
mov r8, rax
lea rdi, str._background
mov r9, rdi
lea rdx, str._s__s
lea rcx, [rsp + 0x58]
call fcn.140004c30
mov rbx, qword [rsp + 0x58]
mov r9, rbx
mov r8d, 0x23
lea rdx, str.CRegKeyMgr::AddRtkAudUServiceRunKey
lea rcx, str._s__d_szPath_s
call fcn.140026f80
mov r9, rbx
lea r8, str.RtkAudUService
lea rdx, str.SOFTWAREMicrosoftWindowsCurrentVersionRun_
mov rcx, 0xffffffff80000002
call fcn.140042260
nop
lea rdx, [rbx - 0x18]
or rbx, 0xffffffffffffffff
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x140058f35
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
call fcn.140064000
test eax, eax
je 0x140058fbb
lea rax, [rsp + 0x30]
mov qword [rsp + 0x58], rax
call fcn.140003520
mov rcx, rax
test rax, rax
je 0x140059081
mov rax, qword [rax]
call qword [rax + reloc.OLEAUT32.dll_SafeArrayGetElement]
add rax, 0x18
mov qword [rsp + 0x30], rax
mov rdx, rdi
lea rcx, [rsp + 0x30]
call fcn.140004a90
test al, al
jne 0x140058f9b
nop dword [rax]
inc rbx
cmp word [rdi + rbx*2], 0
jne 0x140058f80
mov r8d, ebx
mov rdx, rdi
lea rcx, [rsp + 0x30]
call fcn.140002f50
nop
call fcn.140004830
mov rdx, rax
lea rcx, [rsp + 0x38]
call fcn.140004a00
nop
lea rdx, [rsp + 0x30]
mov rcx, rax
call fcn.1400633f0
test r14d, r14d
jne 0x14005904f
lea rbx, str.AddRtkAudUServiceRunKey_at_FirstTime
test esi, esi
jne 0x14005900a
xor r9d, r9d
mov r8, rbx
lea rdx, str.DebugLog
lea rcx, [0x1400bf590]
call fcn.140003a40
cmp eax, 1
jne 0x14005900a
mov r9d, eax
lea r8, str.AddRtkAudUServiceRunKey_RunKeyDisappear
lea rdx, str.DebugLog
lea rcx, [0x1400bf590]
call fcn.140003b10
call fcn.1400429e0
mov r9d, 1
lea rdx, str.DebugLog
lea rcx, [0x1400bf590]
test eax, eax
jne 0x14005903d
lea rax, str.AddRtkAudUServiceRunKey_but_NoEntry_at_FirstTime
lea r8, str.AddRtkAudUServiceRunKey_but_NoEntry
test esi, esi
cmovne r8, rax
jmp 0x14005904a
lea r8, str.AddRtkAudUServiceRunKey
test esi, esi
cmovne r8, rbx
call fcn.140003b10
mov rcx, qword [rbp + 0x1590]
xor rcx, rsp
call fcn.140065bd0
lea r11, [rsp + 0x16a0]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x38]
mov rsp, r11
pop r14
pop rdi
pop rbp
ret
mov ecx, 0x80004005
call fcn.140003270
int3
mov ecx, 0x80004005
call fcn.140003270
int3