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

Disassembly:
mov rax, rsp
push rbp
push rdi
push r12
lea rbp, [rax - 0x7a8]
sub rsp, 0x890
mov qword [rsp + 0x58], 0xfffffffffffffffe
mov qword [rax + 8], rbx
mov qword [rax + 0x18], rsi
mov rax, qword [0x140398250]
xor rax, rsp
mov qword [rbp + 0x780], rax
mov esi, edx
xor r8d, r8d
lea rdx, str.CBaseOSSpecTypeWin2K::DOMSServiceControl
lea rcx, [rsp + 0x40]
call fcn.1400075a0
nop
mov r9d, esi
lea r8, str.bMode___d
mov edx, 1
lea rcx, [rsp + 0x40]
call fcn.140007780
xor ebx, ebx
xor edx, edx
xor ecx, ecx
mov r8d, 0x20000000
call qword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov r12, rax
test rax, rax
jne 0x1400de126
lea r8, str._t_t_tOpenSCManager_Error
lea edx, [rbx + 7]
lea rcx, [rsp + 0x40]
call fcn.140007780
test esi, esi
jne 0x1400de38f
xor r9d, r9d
lea r8, str.return___08x
lea edx, [rbx + 2]
lea rcx, [rsp + 0x40]
call fcn.140007780
nop
lea rcx, [rsp + 0x40]
call fcn.140007730
xor eax, eax
jmp 0x1400de528
mov r8d, 0xf01ff
lea rdx, str.Canon_Output_Manager_Service
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov rdi, rax
test rax, rax
jne 0x1400de1f7
mov qword [rsp + 0x50], rbx
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
mov qword [rsp + 0x30], rbx
mov dword [rsp + 0x28], ebx
lea rax, [rsp + 0x50]
mov qword [rsp + 0x20], rax
mov r9d, 0x409
mov r8d, edi
xor edx, edx
mov ecx, 0x1300
call qword [sym.imp.KERNEL32.dll_FormatMessageW]
test eax, eax
je 0x1400de1ad
mov rax, qword [rsp + 0x50]
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], edi
lea r9, str._t_t_tOpenService_Error
lea r8, str.ApiName:__s__ErrorCode:__d_:__s
mov edx, 6
lea rcx, [rsp + 0x40]
call fcn.140007780
mov rcx, qword [rsp + 0x50]
test rcx, rcx
je 0x1400de1bd
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rcx, r12
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
test esi, esi
jne 0x1400de38f
xor r9d, r9d
lea r8, str.return___08x
lea edx, [rsi + 2]
lea rcx, [rsp + 0x40]
call fcn.140007780
nop
lea rcx, [rsp + 0x40]
call fcn.140007730
xor eax, eax
jmp 0x1400de528
lea rdx, [rsp + 0x60]
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
jne 0x1400de2be
mov qword [rsp + 0x50], rbx
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
mov qword [rsp + 0x30], rbx
mov dword [rsp + 0x28], ebx
lea rax, [rsp + 0x50]
mov qword [rsp + 0x20], rax
mov r9d, 0x409
mov r8d, esi
xor edx, edx
mov ecx, 0x1300
call qword [sym.imp.KERNEL32.dll_FormatMessageW]
test eax, eax
je 0x1400de272
mov rax, qword [rsp + 0x50]
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], esi
lea r9, str._t_t_tQueryServiceStatus
lea r8, str.ApiName:__s__ErrorCode:__d_:__s
mov edx, 6
lea rcx, [rsp + 0x40]
call fcn.140007780
mov rcx, qword [rsp + 0x50]
test rcx, rcx
je 0x1400de282
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rcx, r12
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
xor r9d, r9d
lea r8, str.return___08x
lea edx, [r9 + 2]
lea rcx, [rsp + 0x40]
call fcn.140007780
nop
lea rcx, [rsp + 0x40]
call fcn.140007730
xor eax, eax
jmp 0x1400de528
mov eax, dword [rsp + 0x64]
test esi, esi
je 0x1400de40a
cmp eax, 4
je 0x1400de40a
xor r8d, r8d
xor edx, edx
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_StartServiceW]
lea rcx, [rsp + 0x40]
test eax, eax
jne 0x1400de30d
lea rdx, str._t_t_tStartService_Error
call fcn.140029dc0
mov rcx, r12
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x1400de38f
lea r8, [0x14030bdf0]
mov edx, 7
call fcn.140007780
xor ecx, ecx
call fcn.140249aec
mov rsi, rax
xor ecx, ecx
call fcn.140249aec
sub rax, rsi
cmp rax, 0x1e
jge 0x1400de38f
nop dword [rax + rax]
mov rcx, qword [0x1403b9758]
mov rax, qword [rcx]
call qword [rax + 0x20]
mov r8, qword [rax]
lea rdx, str.Canon_Output_Manager_Service
mov rcx, rax
call qword [r8 + 0x1f0]
cmp eax, 4
je 0x1400de383
mov ecx, 0x3e8
call qword [sym.imp.KERNEL32.dll_Sleep]
xor ecx, ecx
call fcn.140249aec
sub rax, rsi
cmp rax, 0x1e
jl 0x1400de340
jmp 0x1400de38f
lea r8, str._t_t_tDOMSService___SERVICE_RUNNING
jmp 0x1400de4dc
mov word [rbp - 0x80], bx
xor edx, edx
mov r8d, 0x7fe
lea rcx, [rbp - 0x7e]
call fcn.14024b970
mov rcx, qword [0x1403b9750]
mov rax, qword [rcx]
call qword [rax + 0x48]
mov r9, qword [rax]
lea r8, [rbp - 0x80]
lea rdx, str.DOMSNAME
mov rcx, rax
call qword [r9 + 0x18]
mov rcx, qword [0x1403b9770]
mov rax, qword [rcx]
lea r9, [rbp - 0x80]
lea r8, [rbp - 0x80]
mov edx, 0xa2
call qword [rax + 0x18]
xor r9d, r9d
lea r8, str.return___08x
lea edx, [r9 + 2]
lea rcx, [rsp + 0x40]
call fcn.140007780
nop
lea rcx, [rsp + 0x40]
call fcn.140007730
xor eax, eax
jmp 0x1400de528
cmp eax, 1
je 0x1400de4f0
lea r8, [rsp + 0x60]
mov edx, 1
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_ControlService]
cmp eax, 1
je 0x1400de478
lea rdx, str._t_t_tControlService
lea rcx, [rsp + 0x40]
call fcn.140029dc0
mov rcx, r12
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
xor r9d, r9d
lea r8, str.return___08x
lea edx, [r9 + 2]
lea rcx, [rsp + 0x40]
call fcn.140007780
nop
lea rcx, [rsp + 0x40]
call fcn.140007730
xor eax, eax
jmp 0x1400de528
xor ecx, ecx
call fcn.140249aec
mov rsi, rax
xor ecx, ecx
call fcn.140249aec
sub rax, rsi
cmp rax, 0x1e
jge 0x1400de4f0
mov rcx, qword [0x1403b9758]
mov rax, qword [rcx]
call qword [rax + 0x20]
mov r8, qword [rax]
lea rdx, str.Canon_Output_Manager_Service
mov rcx, rax
call qword [r8 + 0x1f0]
cmp eax, 1
je 0x1400de4d5
mov ecx, 0x3e8
call qword [sym.imp.KERNEL32.dll_Sleep]
xor ecx, ecx
call fcn.140249aec
sub rax, rsi
cmp rax, 0x1e
jl 0x1400de492
jmp 0x1400de4f0
lea r8, str._t_t_tDOMSService___SERVICE_STOPPED
mov edx, 7
lea rcx, [rsp + 0x40]
call fcn.140007780
mov ebx, 1
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, r12
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov r9d, ebx
lea r8, str.return___d
mov edx, 2
lea rcx, [rsp + 0x40]
call fcn.140007780
nop
lea rcx, [rsp + 0x40]
call fcn.140007730
mov eax, ebx
mov rcx, qword [rbp + 0x780]
xor rcx, rsp
call fcn.140245660
lea r11, [rsp + 0x890]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x30]
mov rsp, r11
pop r12
pop rdi
pop rbp
ret