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

Disassembly:
mov rax, rsp
push rsi
push rdi
push r12
sub rsp, 0x60
mov qword [rsp + 0x30], 0xfffffffffffffffe
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rbp
mov rsi, rcx
mov rax, qword [rcx]
mov rbx, qword [rax + 0x178]
xor r12d, r12d
test rbx, rbx
je 0x14005603d
mov rax, qword [rbx]
cmp dword [rax + 0x174], 3
jl 0x14005603d
call fcn.14009d5e8
mov r11, rax
mov ecx, r12d
test rax, rax
setne cl
test ecx, ecx
jne 0x140055fc5
mov ecx, 0x80004005
call fcn.1400034f0
int3
mov rax, qword [rax]
mov rcx, r11
call qword [rax + reloc.OLEAUT32.dll_SafeArrayGetElement]
add rax, 0x18
mov qword [rsp + 0x80], rax
lea rax, [0x1400fb278]
mov qword [rsp + 0x20], rax
lea r9, str.RestartPrintSpooler
lea r8, str.CPrinterFunc
lea rdx, str.__public___s::_s__s_
lea rcx, [rsp + 0x80]
call fcn.14000a800
lea rdx, [rsp + 0x80]
mov rcx, rbx
call fcn.14002f200
nop
mov rdx, qword [rsp + 0x80]
add rdx, 0xffffffffffffffe8
or eax, 0xffffffff
lock xadd dword [rdx + 0x10], eax
add eax, 0xffffffff
test eax, eax
jg 0x14005603d
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
xor edx, edx
xor ecx, ecx
mov r8d, 0x20000000
call qword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov rbp, rax
test rax, rax
jne 0x14005607e
mov dword [rsp + 0x20], r12d
lea r9, [0x1400fb428]
lea r8, str.RestartPrintSpooler
lea rdx, str.CPrinterFunc
mov rcx, qword [rsi]
call fcn.140080e70
xor eax, eax
jmp 0x14005632e
mov r8d, 0x34
lea rdx, str.Spooler
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov rdi, rax
test rax, rax
jne 0x1400560ce
mov rcx, rbp
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov dword [rsp + 0x20], r12d
lea r9, [0x1400fb428]
lea r8, str.RestartPrintSpooler
lea rdx, str.CPrinterFunc
mov rcx, qword [rsi]
call fcn.140080e70
xor eax, eax
jmp 0x14005632e
lea rdx, [rsp + 0x38]
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
jne 0x14005611b
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rbp
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov dword [rsp + 0x20], r12d
lea r9, [0x1400fb428]
lea r8, str.RestartPrintSpooler
lea rdx, str.CPrinterFunc
mov rcx, qword [rsi]
call fcn.140080e70
xor eax, eax
jmp 0x14005632e
cmp dword [rsp + 0x3c], 4
jne 0x140056219
lea r8, [rsp + 0x38]
mov edx, 1
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
jne 0x140056178
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rbp
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov dword [rsp + 0x20], r12d
lea r9, [0x1400fb428]
lea r8, str.RestartPrintSpooler
lea rdx, str.CPrinterFunc
mov rcx, qword [rsi]
call fcn.140080e70
xor eax, eax
jmp 0x14005632e
mov ebx, r12d
nop
nop
lea rdx, [rsp + 0x38]
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
je 0x1400561de
cmp ebx, 0x14
ja 0x1400561de
mov ecx, 0x3e8
call qword [sym.imp.KERNEL32.dll_Sleep]
add ebx, 1
call fcn.1400a0754
test rax, rax
je 0x1400561bd
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + pe_nt_image_headers64]
jmp 0x1400561c0
mov rax, r12
xor r9d, r9d
xor r8d, r8d
mov edx, 0x2b3d
mov rcx, qword [rax + 0x40]
call qword [sym.imp.USER32.dll_SendMessageW]
cmp dword [rsp + 0x3c], 1
je 0x140056219
jmp 0x140056180
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rbp
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov dword [rsp + 0x20], r12d
lea r9, [0x1400fb428]
lea r8, str.RestartPrintSpooler
lea rdx, str.CPrinterFunc
mov rcx, qword [rsi]
call fcn.140080e70
xor eax, eax
jmp 0x14005632e
xor r8d, r8d
xor edx, edx
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_StartServiceW]
test eax, eax
jne 0x140056266
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rbp
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov dword [rsp + 0x20], r12d
lea r9, [0x1400fb428]
lea r8, str.RestartPrintSpooler
lea rdx, str.CPrinterFunc
mov rcx, qword [rsi]
call fcn.140080e70
xor eax, eax
jmp 0x14005632e
mov ebx, r12d
nop
nop
lea rdx, [rsp + 0x38]
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
je 0x1400562f8
cmp ebx, 0x14
ja 0x1400562f8
mov ecx, 0x3e8
call qword [sym.imp.KERNEL32.dll_Sleep]
add ebx, 1
call fcn.1400a0754
test rax, rax
je 0x1400562ad
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + pe_nt_image_headers64]
jmp 0x1400562b0
mov rax, r12
xor r9d, r9d
xor r8d, r8d
mov edx, 0x2b3d
mov rcx, qword [rax + 0x40]
call qword [sym.imp.USER32.dll_SendMessageW]
cmp dword [rsp + 0x3c], 4
jne 0x140056270
mov dword [rsp + 0x20], 1
lea r9, [0x1400fb428]
lea r8, str.RestartPrintSpooler
lea rdx, str.CPrinterFunc
mov rcx, qword [rsi]
call fcn.140080e70
mov eax, 1
jmp 0x14005632e
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rbp
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov dword [rsp + 0x20], r12d
lea r9, [0x1400fb428]
lea r8, str.RestartPrintSpooler
lea rdx, str.CPrinterFunc
mov rcx, qword [rsi]
call fcn.140080e70
xor eax, eax
lea r11, [rsp + 0x60]
mov rbx, qword [r11 + 0x28]
mov rbp, qword [r11 + 0x30]
mov rsp, r11
pop r12
pop rdi
pop rsi
ret