Function at 0x1401899e0
Capabilities:
Create service
Modify service
Persist via windows service

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
mov qword [rsp + 0x20], r12
push rbp
push r14
push r15
lea rbp, [rsp - 0x400]
sub rsp, 0x500
mov rax, qword [0x1405f98c0]
xor rax, rsp
mov qword [rbp + 0x3f0], rax
mov r14, qword [rbp + 0x458]
mov bl, 1
mov r8d, 0x104
lea rdx, [rbp - 0x30]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
jne 0x140189a6b
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea r9, str.GetModuleFileName_failed_w_err_
mov dword [rsp + 0x70], eax
lea rax, [rsp + 0x70]
mov qword [rsp + 0x20], rax
lea r8, str.InstallService
mov edx, 4
call fcn.1400d1640
xor bl, bl
jmp 0x14018a04d
lea rax, [rbp - 0x30]
mov qword [rsp + 0x20], rax
lea r9, str.__s_
mov edx, 0x106
mov r8d, edx
lea rcx, [rbp + 0x1e0]
call fcn.140189970
test eax, eax
jns 0x140189aa2
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea r9, str._snwprintf_s_failed_w_err_
jmp 0x140189a45
xor edx, edx
xor ecx, ecx
mov r8d, 0xf003f
call qword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov rsi, rax
test rax, rax
jne 0x140189acc
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea r9, str.OpenSCManager_failed_w_err_
jmp 0x140189a45
xor r15d, r15d
mov qword [rsp + 0x60], r15
mov qword [rsp + 0x58], r15
lea r12, str.Event_Log
mov qword [rsp + 0x50], r12
mov qword [rsp + 0x48], r15
mov qword [rsp + 0x40], r15
lea rax, [rbp + 0x1e0]
mov qword [rsp + 0x38], rax
mov dword [rsp + 0x30], 1
mov dword [rsp + 0x28], 2
mov dword [rsp + 0x20], reloc.WS2_32.dll_recv
mov r9d, 0xf01ff
lea r8, [0x140578fe8]
lea rdx, [0x140578fe8]
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_CreateServiceW]
mov rdi, rax
test rax, rax
jne 0x140189c2d
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x431
jne 0x140189bfa
lea r9, str.Uninstalling_previous_service
lea r8, str.InstallService
lea edx, [rdi + 2]
call fcn.1400c6f10
mov rdx, r14
call fcn.14018a290
test al, al
jne 0x140189b9b
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x70], eax
lea rax, [rsp + 0x70]
mov qword [rsp + 0x20], rax
lea r9, str.UninstallService___failed____trying_CreateService___anyway...
lea r8, str.InstallService
lea edx, [rdi + 4]
call fcn.1400d1640
xor bl, bl
mov qword [rsp + 0x60], r15
mov qword [rsp + 0x58], r15
mov qword [rsp + 0x50], r12
mov qword [rsp + 0x48], r15
mov qword [rsp + 0x40], r15
lea rax, [rbp - 0x30]
mov qword [rsp + 0x38], rax
mov dword [rsp + 0x30], 1
mov dword [rsp + 0x28], 2
mov dword [rsp + 0x20], reloc.WS2_32.dll_recv
mov r9d, 0xf01ff
lea r8, [0x140578fe8]
lea rdx, [0x140578fe8]
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_CreateServiceW]
mov rdi, rax
test rax, rax
jne 0x140189c2d
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x70], eax
lea rax, [rsp + 0x70]
mov qword [rsp + 0x20], rax
lea r9, str.CreateService_failed_w_err_
lea r8, str.InstallService
mov edx, 4
call fcn.1400d1640
xor bl, bl
jmp 0x14018a044
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea ecx, [rax - 0xbc2]
cmp ecx, 1
jbe 0x140189c45
cmp eax, 0x669
jne 0x140189c49
mov byte [r14], 1
xorps xmm0, xmm0
movups xmmword [rbp - 0x80], xmm0
xorps xmm1, xmm1
movdqu xmmword [rbp - 0x70], xmm1
mov r8d, setsockopt
lea rdx, [0x140578fe8]
lea rcx, [rbp - 0x80]
call fcn.1400c71d0
nop
lea rdx, [rbp - 0x80]
lea rcx, [rbp - 0x60]
call fcn.1401844a0
nop
cmp qword [rax + 0x18], 0xf
jbe 0x140189c87
mov rax, qword [rax]
mov qword [rsp + 0x70], rax
lea rax, [rsp + 0x70]
mov qword [rsp + 0x20], rax
lea r9, str.Service__is_installed.
lea r8, str.InstallService
mov edx, 2
call fcn.1400d2b90
nop
mov rdx, qword [rbp - 0x48]
cmp rdx, 0xf
jbe 0x140189cea
inc rdx
mov rcx, qword [rbp - 0x60]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140189ce5
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14018a086
call fcn.1403e3650
movdqa xmm0, xmmword [0x14057a8c0]
movdqu xmmword [rbp - 0x50], xmm0
mov byte [rbp - 0x60], 0
mov rdx, qword [rbp - 0x68]
cmp rdx, 7
jbe 0x140189d3b
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp - 0x80]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140189d36
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14018a08c
call fcn.1403e3650
lea rax, str.Blade_SAS_Shadow_El_Processator_Service
mov qword [rsp + 0x78], rax
lea r8, [rsp + 0x78]
mov edx, 1
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_ChangeServiceConfig2W]
test eax, eax
jne 0x140189d8a
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x70], eax
lea rax, [rsp + 0x70]
mov qword [rsp + 0x20], rax
lea r9, str.ChangeServiceConfig2_SERVICE_CONFIG_DESCRIPTION__failed_w_err_
lea r8, str.InstallService
mov edx, 4
call fcn.1400d1640
mov dword [rbp - 0x80], 1
mov dword [rbp - 0x7c], 0x3e8
mov dword [rbp - 0x78], 1
mov dword [rbp - 0x74], 0x3e8
mov dword [rbp - 0x70], 1
mov dword [rbp - 0x6c], 0x3e8
mov dword [rbp - 0x60], 0x15180
xorps xmm0, xmm0
movdqu xmmword [rbp - 0x58], xmm0
mov dword [rbp - 0x48], 3
lea rax, [rbp - 0x80]
mov qword [rbp - 0x40], rax
lea r8, [rbp - 0x60]
mov edx, 2
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_ChangeServiceConfig2W]
test eax, eax
jne 0x140189e14
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x70], eax
lea rax, [rsp + 0x70]
mov qword [rsp + 0x20], rax
lea r9, str.ChangeServiceConfig2_SERVICE_CONFIG_FAILURE_ACTIONS__failed_w_err_
lea r8, str.InstallService
mov edx, 4
call fcn.1400d1640
xorps xmm0, xmm0
movups xmmword [rbp - 0x80], xmm0
xorps xmm1, xmm1
movdqu xmmword [rbp - 0x70], xmm1
mov r8d, setsockopt
lea rdx, [0x140578fe8]
lea rcx, [rbp - 0x80]
call fcn.1400c71d0
nop
lea rdx, [rbp - 0x80]
lea rcx, [rbp - 0x60]
call fcn.1401844a0
nop
cmp qword [rax + 0x18], 0xf
jbe 0x140189e52
mov rax, qword [rax]
mov qword [rsp + 0x78], rax
lea rax, [rsp + 0x78]
mov qword [rsp + 0x20], rax
lea r9, str.Service__is_setup.
lea r8, str.InstallService
mov edx, 2
call fcn.1400d2b90
nop
mov rdx, qword [rbp - 0x48]
cmp rdx, 0xf
jbe 0x140189eb5
inc rdx
mov rcx, qword [rbp - 0x60]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140189eb0
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14018a092
call fcn.1403e3650
movdqa xmm0, xmmword [0x14057a8c0]
movdqu xmmword [rbp - 0x50], xmm0
mov byte [rbp - 0x60], 0
mov rdx, qword [rbp - 0x68]
cmp rdx, 7
jbe 0x140189f06
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp - 0x80]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140189f01
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14018a098
call fcn.1403e3650
mov rdx, r14
mov rcx, rdi
call fcn.14018a0b0
test al, al
jne 0x140189f48
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x70], eax
lea rax, [rsp + 0x70]
mov qword [rsp + 0x20], rax
lea r9, str.StartService___failed_w_err_
lea r8, str.InstallService
mov edx, 4
call fcn.1400d1640
xor bl, bl
jmp 0x14018a036
xorps xmm0, xmm0
movups xmmword [rbp - 0x80], xmm0
xorps xmm1, xmm1
movdqu xmmword [rbp - 0x70], xmm1
mov r8d, setsockopt
lea rdx, [0x140578fe8]
lea rcx, [rbp - 0x80]
call fcn.1400c71d0
nop
lea rdx, [rbp - 0x80]
lea rcx, [rbp - 0x60]
call fcn.1401844a0
nop
cmp qword [rax + 0x18], 0xf
jbe 0x140189f86
mov rax, qword [rax]
mov qword [rsp + 0x78], rax
lea rax, [rsp + 0x78]
mov qword [rsp + 0x20], rax
lea r9, str.Service__is_started.
lea r8, str.InstallService
mov edx, 2
call fcn.1400d2b90
nop
mov rdx, qword [rbp - 0x48]
cmp rdx, 0xf
jbe 0x140189fe9
inc rdx
mov rcx, qword [rbp - 0x60]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140189fe4
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14018a09e
call fcn.1403e3650
movdqa xmm0, xmmword [0x14057a8c0]
movdqu xmmword [rbp - 0x50], xmm0
mov byte [rbp - 0x60], 0
mov rdx, qword [rbp - 0x68]
cmp rdx, 7
jbe 0x14018a036
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp - 0x80]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14018a031
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14018a080
call fcn.1403e3650
test rdi, rdi
je 0x14018a044
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
movzx eax, bl
mov rcx, qword [rbp + 0x3f0]
xor rcx, rsp
call fcn.1403e3630
lea r11, [rsp + 0x500]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rdi, qword [r11 + 0x30]
mov r12, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop rbp
ret
call fcn.1403fd768
nop
call fcn.1403fd768
nop
call fcn.1403fd768
nop
call fcn.1403fd768
nop
call fcn.1403fd768
nop
call fcn.1403fd768
int3