Function at 0x14013f410
Capabilities:
Persist via windows service
Set registry value

Disassembly:
mov qword [rsp + 8], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x27]
sub rsp, 0xd0
mov r15, rcx
lea rcx, [rbp - 9]
call fcn.140136980
mov r13, qword [rbp + 7]
movabs rcx, 0x7ffffffffffffffe
mov r14, rcx
sub r14, r13
cmp r14, 0x22
jb 0x14013f9a3
cmp qword [rbp + 0xf], 7
lea rdx, [rbp - 9]
mov r12, qword [rbp - 9]
lea rax, [r13 + 0x22]
mov esi, 7
lea rbx, [rbp - 0x49]
cmova rdx, r12
xorps xmm0, xmm0
xor r8d, r8d
mov qword [rbp + 0x7f], rdx
xorps xmm1, xmm1
mov edi, esi
lea r10d, [rsi + 3]
movabs r9, 0x7fffffffffffffff
movups xmmword [rbp - 0x49], xmm0
movdqu xmmword [rbp - 0x39], xmm1
cmp rax, rsi
jbe 0x14013f529
mov rdi, rax
or rdi, rsi
cmp rdi, rcx
jbe 0x14013f4b7
mov rdi, rcx
lea rcx, [r9 + r9]
jmp 0x14013f4d7
cmp rdi, r10
cmovb rdi, r10
lea rcx, [rdi + 1]
cmp rcx, r9
ja 0x14013f99d
add rcx, rcx
cmp rcx, 0x1000
jb 0x14013f50b
lea rax, [rcx + 0x27]
cmp rax, rcx
jbe 0x14013f99d
mov rcx, rax
call fcn.1401c7ed4
test rax, rax
je 0x14013f970
mov rdx, qword [rbp + 0x7f]
lea rbx, [rax + 0x27]
and rbx, 0xffffffffffffffe0
mov qword [rbx - 8], rax
lea rax, [r13 + 0x22]
jmp 0x14013f525
test rcx, rcx
je 0x14013f522
call fcn.1401c7ed4
mov rdx, qword [rbp + 0x7f]
mov rbx, rax
lea rax, [r13 + 0x22]
jmp 0x14013f525
mov rbx, r8
mov qword [rbp - 0x49], rbx
movaps xmm0, xmmword [str.SYSTEMCurrentControlSetServices_]
lea rcx, [rbx + 0x44]
mov qword [rbp - 0x39], rax
mov qword [rbp - 0x31], rdi
movups xmmword [rbx], xmm0
movaps xmm1, xmmword [0x140492770]
movups xmmword [rbx + 0x10], xmm1
movaps xmm0, xmmword [0x140492780]
movups xmmword [rbx + 0x20], xmm0
movaps xmm1, xmmword [0x140492790]
movups xmmword [rbx + 0x30], xmm1
mov eax, dword [0x1404927a0]
mov dword [rbx + 0x40], eax
lea rax, [r13*2]
mov r8, rax
mov qword [rbp + 0x7f], rax
call sub.VCRUNTIME140.dll_memcpy
xor edi, edi
movabs rax, 0x7ffffffffffffffe
mov word [rbx + r13*2 + 0x44], di
mov rcx, qword [r15 + 0x10]
sub rax, rcx
cmp rax, 4
jb 0x14013f9a3
cmp qword [r15 + 0x18], rsi
jbe 0x14013f5a9
mov r15, qword [r15]
mov qword [rsp + 0x30], rcx
lea r9, [0x1404927a8]
mov qword [rsp + 0x28], r15
lea rcx, [rbp - 0x29]
mov qword [rsp + 0x20], 4
call fcn.14013cae0
cmp qword [rbp - 0x31], rsi
lea rdx, [rbp - 0x49]
lea r8, [rbp + 0x77]
mov rcx, 0xffffffff80000002
cmova rdx, qword [rbp - 0x49]
call qword [sym.imp.ADVAPI32.dll_RegCreateKeyW]
test eax, eax
jne 0x14013f89c
mov eax, dword [rbp - 0x19]
lea rcx, [rbp - 0x29]
add eax, eax
lea r8, str.ImagePath
cmp qword [rbp - 0x11], rsi
mov r9d, 2
mov dword [rsp + 0x28], eax
cmova rcx, qword [rbp - 0x29]
xor edx, edx
mov qword [rsp + 0x20], rcx
mov rcx, qword [rbp + 0x77]
call qword [sym.imp.ADVAPI32.dll_RegSetKeyValueW]
mov rcx, qword [rbp + 0x77]
test eax, eax
je 0x14013f639
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x14013f89c
lea rax, [0x140492890]
mov dword [rsp + 0x28], 4
mov r9d, 4
mov qword [rsp + 0x20], rax
lea r8, str.Type
xor edx, edx
call qword [sym.imp.ADVAPI32.dll_RegSetKeyValueW]
mov rcx, qword [rbp + 0x77]
test eax, eax
je 0x14013f675
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x14013f89c
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea rcx, [0x140492738]
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov rdi, rax
test rax, rax
je 0x14013f89a
lea rdx, str.RtlAdjustPrivilege
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.NtLoadDriver
mov rcx, rdi
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
xor r8d, r8d
lea r9, [rbp + 0x6f]
mov dl, 1
mov r15, rax
lea ecx, [r8 + 0xa]
call rbx
test eax, eax
js 0x14013f89a
cmp r14, 0x34
jb 0x14013f9a3
mov r14, qword [rbp + 0xf]
lea rdi, [rbp - 9]
cmp r14, rsi
lea rbx, [rbp - 0x69]
xorps xmm0, xmm0
xorps xmm1, xmm1
cmova rdi, r12
add r13, 0x34
movups xmmword [rbp - 0x69], xmm0
movdqu xmmword [rbp - 0x59], xmm1
cmp r13, rsi
jbe 0x14013f7a8
mov rsi, r13
movabs rax, 0x7ffffffffffffffe
or rsi, 7
cmp rsi, rax
jbe 0x14013f733
mov rsi, rax
movabs rax, 0x7fffffffffffffff
lea rcx, [rax + rax]
jmp 0x14013f763
cmp rsi, 0xa
mov eax, 0xa
cmovb rsi, rax
movabs rax, 0x7fffffffffffffff
lea rcx, [rsi + 1]
cmp rcx, rax
ja 0x14013f99d
add rcx, rcx
cmp rcx, 0x1000
jb 0x14013f78f
lea rax, [rcx + 0x27]
cmp rax, rcx
jbe 0x14013f99d
mov rcx, rax
call fcn.1401c7ed4
test rax, rax
je 0x14013f970
lea rbx, [rax + 0x27]
and rbx, 0xffffffffffffffe0
mov qword [rbx - 8], rax
jmp 0x14013f7a4
test rcx, rcx
je 0x14013f79e
call fcn.1401c7ed4
mov rbx, rax
jmp 0x14013f7a4
xor r8d, r8d
mov ebx, r8d
mov qword [rbp - 0x69], rbx
movaps xmm0, xmmword [str.RegistryMachineSystemCurrentControlSetServices_]
lea rcx, [rbx + 0x68]
mov r8, qword [rbp + 0x7f]
mov rdx, rdi
mov qword [rbp - 0x59], r13
mov qword [rbp - 0x51], rsi
movups xmmword [rbx], xmm0
movaps xmm1, xmmword [0x140492820]
movups xmmword [rbx + 0x10], xmm1
movaps xmm0, xmmword [0x140492830]
movups xmmword [rbx + 0x20], xmm0
movaps xmm1, xmmword [0x140492840]
movups xmmword [rbx + 0x30], xmm1
movaps xmm0, xmmword [0x140492850]
movups xmmword [rbx + 0x40], xmm0
movaps xmm1, xmmword [0x140492860]
movups xmmword [rbx + 0x50], xmm1
movsd xmm0, qword [0x140492870]
movsd qword [rbx + 0x60], xmm0
call sub.VCRUNTIME140.dll_memcpy
xor edi, edi
lea rdx, [rbp - 0x69]
mov word [rbx + r13*2], di
lea rcx, [rbp + 0x17]
cmp qword [rbp - 0x51], 7
cmova rdx, qword [rbp - 0x69]
call qword [sym.imp.ntdll.dll_RtlInitUnicodeString]
lea rcx, [rbp + 0x17]
call r15
mov ebx, eax
cmp eax, 0xc000010e
jne 0x14013f841
mov bl, 1
jmp 0x14013f847
shr ebx, 0x1f
xor bl, 1
mov rdx, qword [rbp - 0x51]
cmp rdx, 7
jbe 0x14013f887
mov rcx, qword [rbp - 0x69]
lea rdx, [rdx*2 + 2]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14013f882
mov rcx, qword [rcx - 8]
add rdx, 0x27
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14013f970
call fcn.1401c7f18
movdqa xmm0, xmmword [0x140495310]
movdqu xmmword [rbp - 0x59], xmm0
mov word [rbp - 0x69], di
jmp 0x14013f8a2
xor edi, edi
mov r14, qword [rbp + 0xf]
xor bl, bl
mov rdx, qword [rbp - 0x11]
cmp rdx, 7
jbe 0x14013f8e2
mov rcx, qword [rbp - 0x29]
lea rdx, [rdx*2 + 2]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14013f8dd
mov rcx, qword [rcx - 8]
add rdx, 0x27
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14013f970
call fcn.1401c7f18
mov rdx, qword [rbp - 0x31]
movdqa xmm0, xmmword [0x140495310]
mov word [rbp - 0x29], di
movdqu xmmword [rbp - 0x19], xmm0
cmp rdx, 7
jbe 0x14013f92f
mov rcx, qword [rbp - 0x49]
lea rdx, [rdx*2 + 2]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14013f92a
mov rcx, qword [rcx - 8]
add rdx, 0x27
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14013f970
call fcn.1401c7f18
movdqa xmm0, xmmword [0x140495310]
mov word [rbp - 0x49], di
movdqu xmmword [rbp - 0x39], xmm0
cmp r14, 7
jbe 0x14013f97f
lea rdx, [r14*2 + 2]
mov rax, r12
cmp rdx, 0x1000
jb 0x14013f977
mov r12, qword [r12 - 8]
add rdx, 0x27
sub rax, r12
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14013f977
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
mov rcx, r12
call fcn.1401c7f18
movzx eax, bl
mov rbx, qword [rsp + 0x110]
add rsp, 0xd0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
call fcn.140133c10
int3
call fcn.140133cb0
int3