Function at 0x1400c7680
Capabilities:
Query service status
Start service
Stop service

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x80
mov rax, qword [0x140467f78]
xor rax, rsp
mov qword [rsp + 0x70], rax
xorps xmm0, xmm0
movups xmmword [rsp + 0x38], xmm0
mov qword [rsp + 0x40], 0
xor edx, edx
lea r8d, [rdx + 0x34]
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov qword [rsp + 0x38], rax
test rax, rax
jne 0x1400c76e0
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r8d, eax
lea rdx, str.SEUtilServiceControlManager::SEUtilServiceControlManager_OpenSCManager_failed__LastError:_d__n
mov ecx, 1
call fcn.1400ab7f0
nop
lea rax, [rsp + 0x48]
mov qword [rsp + 0x30], rax
lea rdx, str.UxSms
lea rcx, [rsp + 0x48]
call fcn.14008f3f0
nop
mov r8d, 0x34
mov rdx, rax
lea rcx, [rsp + 0x38]
call fcn.1400c6960
mov rdi, qword [rsp + 0x40]
test al, al
jne 0x1400c7724
lea rdx, str.SEUtilServiceRestart_ServiceOpen_failed___n
jmp 0x1400c78d5
lea rax, [rsp + 0x30]
mov qword [rsp + 0x20], rax
mov r9d, 0x24
lea r8, [rsp + 0x48]
xor edx, edx
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_QueryServiceStatusEx]
test eax, eax
jne 0x1400c776e
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r8d, eax
lea rdx, str.SEUtilServiceControlManager::ServiceStatusQuery_QueryServiceStatusEx_failed___d__n
mov ecx, 1
call fcn.1400ab7f0
lea rdx, str.SEUtilServiceRestart_ServiceStatusQuery_failed___1__n
jmp 0x1400c78d5
cmp dword [rsp + 0x4c], 4
je 0x1400c777c
mov bl, 1
jmp 0x1400c78e1
lea r8, [rsp + 0x48]
mov edx, 1
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
jne 0x1400c77b9
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r8d, eax
lea rdx, str.SEUtilServiceControlManager::ServiceStop_ControlService_failed__LastError:_d__n
mov ecx, 1
call fcn.1400ab7f0
lea rdx, str.SEUtilServiceRestart_ServiceStop_failed___n
jmp 0x1400c78d5
xor ebx, ebx
nop dword [rax + rax]
lea rax, [rsp + 0x30]
mov qword [rsp + 0x20], rax
mov r9d, 0x24
lea r8, [rsp + 0x48]
xor edx, edx
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_QueryServiceStatusEx]
test eax, eax
je 0x1400c78a3
cmp dword [rsp + 0x4c], 1
je 0x1400c7807
mov ecx, 0x64
call qword [sym.imp.KERNEL32.dll_Sleep]
inc ebx
cmp ebx, 0x64
jae 0x1400c78ce
jmp 0x1400c77c0
test rdi, rdi
jne 0x1400c7827
lea rdx, str.SEUtilServiceControlManager::ServiceStart_Service_handle_invalid__n
lea ecx, [rdi + 1]
call fcn.1400ab7f0
lea rdx, str.SEUtilServiceRestart_ServiceStart_failed___n
jmp 0x1400c78d5
xor r8d, r8d
xor edx, edx
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_StartServiceW]
test eax, eax
jne 0x1400c785c
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r8d, eax
lea rdx, str.SEUtilServiceControlManager::ServiceStart_StartService_failed___d_n
mov ecx, 1
call fcn.1400ab7f0
lea rdx, str.SEUtilServiceRestart_ServiceStart_failed___n
jmp 0x1400c78d5
xor ebx, ebx
nop
lea rax, [rsp + 0x30]
mov qword [rsp + 0x20], rax
mov r9d, 0x24
lea r8, [rsp + 0x48]
xor edx, edx
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_QueryServiceStatusEx]
test eax, eax
je 0x1400c78a3
cmp dword [rsp + 0x4c], 4
je 0x1400c7775
mov ecx, 0x64
call qword [sym.imp.KERNEL32.dll_Sleep]
inc ebx
cmp ebx, 0x64
jae 0x1400c78ce
jmp 0x1400c7860
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r8d, eax
lea rdx, str.SEUtilServiceControlManager::ServiceStatusQuery_QueryServiceStatusEx_failed___d__n
mov ecx, 1
call fcn.1400ab7f0
lea rdx, str.PrivateServiceStatusQueryWait_ServiceStatusQuery_failed__n
mov ecx, 1
call fcn.1400ab7f0
lea rdx, str.SEUtilServiceRestart_PrivateServiceStatusQueryWait_failed___n
mov ecx, 1
call fcn.1400ab7f0
xor bl, bl
mov rcx, qword [rsp + 0x38]
test rcx, rcx
je 0x1400c78fa
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov qword [rsp + 0x38], 0
test rdi, rdi
je 0x1400c7911
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov qword [rsp + 0x40], 0
movzx eax, bl
mov rcx, qword [rsp + 0x70]
xor rcx, rsp
call fcn.1402ab320
mov rbx, qword [rsp + 0x90]
add rsp, 0x80
pop rdi
ret