Function at 0x14005f820
Capabilities:
Create service

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r12
push r14
push r15
sub rsp, 0xa90
mov rax, qword [0x140170608]
xor rax, rsp
mov qword [rsp + 0xa80], rax
mov esi, 0xf003f
xor ebp, ebp
mov r8d, esi
xor edx, edx
xor ecx, ecx
mov edi, ebp
call qword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
lea r14d, [rbp + 1]
mov rbx, rax
lea r15, [0x1401713a8]
test rax, rax
je 0x14005f8b0
mov r8d, r14d
mov rdx, r15
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenServiceW]
test rax, rax
je 0x14005f89b
mov rcx, rax
mov edi, r14d
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
test edi, edi
je 0x14005f8b0
mov eax, r14d
jmp 0x14005f9bb
mov ebx, 0x104
lea rdx, [rsp + 0x72]
mov r8d, ebx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
je 0x14005f9b9
cmp eax, ebx
je 0x14005f9b9
lea ecx, [rax + 1]
mov r12d, 0x22
mov word [rsp + 0x70], r12w
mov word [rsp + rcx*2 + 0x70], r12w
lea ecx, [rax + 2]
add rcx, rcx
cmp rcx, 0x20c
jae 0x14005faf3
mov word [rsp + rcx + 0x70], bp
mov r8d, esi
xor ecx, ecx
xor edx, edx
call qword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov rbx, rax
test rax, rax
jne 0x14005f9ed
xor edx, edx
call fcn.1400834a0
mov edi, ebp
mov esi, r14d
mov ebx, 0x400
test rax, rax
je 0x14005f963
test edi, edi
jne 0x14005f9a3
mov r9d, ebx
lea r8, [rsp + 0x280]
mov edx, 0xd80a
mov rcx, rax
call qword [sym.imp.USER32.dll_LoadStringW]
mov edx, esi
mov edi, eax
call fcn.1400834a0
add esi, r14d
test rax, rax
jne 0x14005f931
test edi, edi
jne 0x14005f9a3
lea r8, str.Could_not_open_Service_Manager
mov rdx, rbx
lea rcx, [rsp + 0x280]
call qword [sym.imp.msvcrt.dll_wcscpy_s]
test eax, eax
je 0x14005f9a3
cmp eax, 0xc
je 0x14005fb0f
cmp eax, 0x16
je 0x14005fb04
cmp eax, r12d
je 0x14005fb04
cmp eax, 0x50
jne 0x14005faf9
xor r9d, r9d
lea rdx, [rsp + 0x280]
mov r8, r15
xor ecx, ecx
call qword [sym.imp.USER32.dll_MessageBoxW]
xor eax, eax
mov rcx, qword [rsp + 0xa80]
xor rcx, rsp
call fcn.140141360
lea r11, [rsp + 0xa90]
mov rbx, qword [r11 + 0x20]
mov rbp, qword [r11 + 0x28]
mov rsi, qword [r11 + 0x30]
mov rdi, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop r12
ret
mov qword [rsp + 0x60], rbp
lea rax, str.RPCSS
mov qword [rsp + 0x58], rbp
mov r9d, 0xf01ff
mov qword [rsp + 0x50], rax
mov r8, r15
mov qword [rsp + 0x48], rbp
lea rax, [rsp + 0x70]
mov qword [rsp + 0x40], rbp
mov rdx, r15
mov qword [rsp + 0x38], rax
mov rcx, rbx
mov dword [rsp + 0x30], r14d
mov dword [rsp + 0x28], 3
mov dword [rsp + 0x20], 0x10
call qword [sym.imp.ADVAPI32.dll_CreateServiceW]
test rax, rax
jne 0x14005fadc
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
xor edx, edx
call fcn.1400834a0
mov edi, ebp
mov esi, r14d
mov ebx, 0x400
test rax, rax
je 0x14005faa3
test edi, edi
jne 0x14005f9a3
mov r9d, ebx
lea r8, [rsp + 0x280]
mov edx, 0xd80b
mov rcx, rax
call qword [sym.imp.USER32.dll_LoadStringW]
mov edx, esi
mov edi, eax
call fcn.1400834a0
add esi, r14d
test rax, rax
jne 0x14005fa69
test edi, edi
jne 0x14005f9a3
lea r8, str.Could_not_start_service
mov rdx, rbx
lea rcx, [rsp + 0x280]
call qword [sym.imp.msvcrt.dll_wcscpy_s]
test eax, eax
je 0x14005f9a3
cmp eax, 0xc
je 0x14005fb30
cmp eax, 0x16
je 0x14005fb25
cmp eax, r12d
je 0x14005fb25
cmp eax, 0x50
jne 0x14005fb1a
jmp 0x14005f9a3
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x14005f8a8
call fcn.140141538
int3
mov ecx, 0x80004005
call fcn.140001c2c
int3
mov ecx, 0x80070057
call fcn.140001c2c
int3
mov ecx, 0x8007000e
call fcn.140001c2c
int3
mov ecx, 0x80004005
call fcn.140001c2c
int3
mov ecx, 0x80070057
call fcn.140001c2c
int3
mov ecx, 0x8007000e
call fcn.140001c2c
int3