Function at 0x140005680
Capabilities:
Create service
Delete service
Query service status
Start service
Stop service

Disassembly:
mov rax, rsp
push rbp
lea rbp, [rax - 0x1c8]
sub rsp, 0x2c0
mov qword [rsp + 0x70], 0xfffffffffffffffe
mov qword [rax + 8], rbx
mov qword [rax + 0x18], rdi
mov rax, qword [0x1400f8010]
xor rax, rsp
mov qword [rbp + 0x1b0], rax
mov rbx, rdx
cmp ecx, 1
jle 0x140005a78
mov rdx, qword [rdx + 8]
movzx eax, word [rdx]
sub ax, 0x2d
mov ecx, 0xfffd
test cx, ax
jne 0x140005a78
add rdx, 2
lea rcx, str.install
call fcn.140087a44
test eax, eax
jne 0x14000583b
mov r8d, 0x104
lea rdx, [rbp - 0x60]
xor ecx, ecx
call qword [sym.imp.api_ms_win_core_libraryloader_l1_2_0.dll_GetModuleFileNameW]
test eax, eax
jne 0x140005720
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov edx, eax
lea rcx, str.GetModuleFileName_failed_w_err_0x_08lx_n
call fcn.140001430
jmp 0x140005b17
xor edx, edx
xor ecx, ecx
lea r8d, [rdx + 3]
call qword [sym.imp.api_ms_win_service_management_l1_1_0.dll_OpenSCManagerW]
mov rdi, rax
test rax, rax
jne 0x14000574f
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov edx, eax
lea rcx, str.OpenSCManager_failed_w_err_0x_08lx_n
call fcn.140001430
jmp 0x140005b17
xor eax, eax
mov qword [rsp + 0x60], rax
mov qword [rsp + 0x58], rax
lea rcx, [0x1400c9a98]
mov qword [rsp + 0x50], rcx
mov qword [rsp + 0x48], rax
mov qword [rsp + 0x40], rax
lea rax, [rbp - 0x60]
mov qword [rsp + 0x38], rax
mov dword [rsp + 0x30], 1
mov dword [rsp + 0x28], 3
mov dword [rsp + 0x20], reloc.WS2_32.dll_recv
mov r9d, setsockopt
lea r8, [0x1400c9ae0]
lea rdx, str.ArmouryCrateControlInterface
mov rcx, rdi
call qword [sym.imp.api_ms_win_service_management_l1_1_0.dll_CreateServiceW]
mov rbx, rax
test rax, rax
jne 0x1400057cd
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov edx, eax
lea rcx, str.CreateService_failed_w_err_0x_08lx_n
call fcn.140001430
jmp 0x14000581b
lea rdx, str.ArmouryCrateControlInterface
lea rcx, str._s_is_installed._n
call fcn.140001430
xor r8d, r8d
xor edx, edx
mov rcx, rbx
call qword [sym.imp.api_ms_win_service_management_l1_1_0.dll_StartServiceW]
test eax, eax
jne 0x140005808
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov edx, eax
lea rcx, str.StartService_failed_w_err_0x_08lx_n
call fcn.140001430
jmp 0x14000581b
lea rcx, str._s_is_started._n
lea rdx, str.ArmouryCrateControlInterface
call fcn.140001430
mov rcx, rdi
call qword [sym.imp.api_ms_win_service_management_l1_1_0.dll_CloseServiceHandle]
test rbx, rbx
je 0x140005b17
mov rcx, rbx
call qword [sym.imp.api_ms_win_service_management_l1_1_0.dll_CloseServiceHandle]
jmp 0x140005b17
mov rdx, qword [rbx + 8]
add rdx, 2
lea rcx, str.remove
call fcn.140087a44
test eax, eax
jne 0x14000598c
xor eax, eax
mov qword [rsp + 0x78], rax
mov qword [rbp - 0x80], rax
mov qword [rbp - 0x78], rax
mov dword [rbp - 0x70], eax
xor edx, edx
xor ecx, ecx
lea r8d, [rax + 1]
call qword [sym.imp.api_ms_win_service_management_l1_1_0.dll_OpenSCManagerW]
mov rdi, rax
test rax, rax
je 0x140005736
mov r8d, 0x10024
lea rdx, str.ArmouryCrateControlInterface
mov rcx, rax
call qword [sym.imp.api_ms_win_service_management_l1_1_0.dll_OpenServiceW]
mov rbx, rax
test rax, rax
jne 0x1400058ba
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov edx, eax
lea rcx, str.OpenService_failed_w_err_0x_08lx_n
call fcn.140001430
jmp 0x14000581b
lea r8, [rsp + 0x78]
mov edx, 1
mov rcx, rbx
call qword [sym.imp.api_ms_win_service_winsvc_l1_1_0.dll_ControlService]
test eax, eax
je 0x14000595a
lea rdx, str.ArmouryCrateControlInterface
lea rcx, str.Stopping__s.
call fcn.140001430
mov ecx, 0x3e8
call qword [sym.imp.api_ms_win_core_synch_l1_2_0.dll_Sleep]
lea rdx, [rsp + 0x78]
mov rcx, rbx
call qword [sym.imp.api_ms_win_service_winsvc_l1_1_0.dll_QueryServiceStatus]
test eax, eax
je 0x140005937
mov eax, dword [rsp + 0x7c]
cmp eax, 3
jne 0x14000593b
lea rcx, [0x1400cb7a4]
call fcn.140001430
mov ecx, 0x3e8
call qword [sym.imp.api_ms_win_core_synch_l1_2_0.dll_Sleep]
lea rdx, [rsp + 0x78]
mov rcx, rbx
call qword [sym.imp.api_ms_win_service_winsvc_l1_1_0.dll_QueryServiceStatus]
test eax, eax
jne 0x140005905
mov eax, dword [rsp + 0x7c]
lea rdx, str.ArmouryCrateControlInterface
cmp eax, 1
lea rcx, str._n_s_is_stopped._n
je 0x140005955
lea rcx, str._n_s_failed_to_stop._n
call fcn.140001430
mov rcx, rbx
call qword [sym.imp.api_ms_win_service_management_l1_1_0.dll_DeleteService]
test eax, eax
jne 0x140005980
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov edx, eax
lea rcx, str.DeleteService_failed_w_err_0x_08lx_n
call fcn.140001430
jmp 0x14000581b
lea rcx, str._s_is_removed._n
jmp 0x14000580f
mov rdx, qword [rbx + 8]
add rdx, 2
lea rcx, str.console
call fcn.140087a44
test eax, eax
jne 0x140005a00
xor edx, edx
mov r8d, 0xa8
lea rcx, [rbp - 0x60]
call fcn.140080170
lea rcx, [rbp - 0x60]
call fcn.140032670
nop
mov byte [rbp - 0x18], 1
lea rcx, [rbp - 0x60]
mov rax, qword [rbp - 0x60]
call qword [rax + 0x38]
mov r8b, 4
lea rdx, str.Starting_Rpc_Server..
lea rcx, [rbp - 0x60]
mov rax, qword [rbp - 0x60]
call qword [rax + 0x48]
call fcn.14002eea0
mov ebx, eax
test eax, eax
jne 0x140005b69
lea rcx, [rbp - 0x60]
call fcn.1400327f0
jmp 0x140005b17
mov rdx, qword [rbx + 8]
add rdx, 2
lea rcx, str.InvokerPRAID:
call fcn.140087a44
test eax, eax
jne 0x140005ae7
xor edx, edx
mov r8d, 0xa8
lea rcx, [rbp - 0x60]
call fcn.140080170
lea rcx, [rbp - 0x60]
call fcn.140032670
nop
mov byte [rbp - 0x18], 1
lea rcx, [rbp - 0x60]
mov rax, qword [rbp - 0x60]
call qword [rax + 0x38]
mov r8b, 4
lea rdx, str.Starting_Rpc_Server..
lea rcx, [rbp - 0x60]
mov rax, qword [rbp - 0x60]
call qword [rax + 0x48]
call fcn.14002eea0
mov ebx, eax
test eax, eax
jne 0x140005b3d
lea rcx, [rbp - 0x60]
call fcn.1400327f0
jmp 0x140005b17
xor edx, edx
mov r8d, 0xa8
lea rcx, [rbp - 0x60]
call fcn.140080170
lea rcx, [rbp - 0x60]
call fcn.140032670
lea rax, [rbp - 0x60]
mov qword [0x1401033f8], rax
mov rax, qword [rbp - 0x58]
mov qword [rsp + 0x78], rax
lea rax, [0x140033bd0]
mov qword [rbp - 0x80], rax
xor eax, eax
mov qword [rbp - 0x78], rax
mov qword [rbp - 0x70], rax
lea rcx, [rsp + 0x78]
call qword [sym.imp.api_ms_win_service_core_l1_1_0.dll_StartServiceCtrlDispatcherW]
test eax, eax
jne 0x140005ade
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov edx, eax
lea rcx, str.Service_failed_to_run_w_err_0x_08lx_n
call fcn.140001430
lea rcx, [rbp - 0x60]
call fcn.1400327f0
lea rcx, str.Parameters:_n
call fcn.140001430
lea rcx, str.__install__to_install_the_service._n
call fcn.140001430
lea rcx, str.__remove___to_remove_the_service._n
call fcn.140001430
lea rcx, str.__console__to_run_in_console_mode._n
call fcn.140001430
xor eax, eax
mov rcx, qword [rbp + 0x1b0]
xor rcx, rsp
call fcn.14003d6b0
lea r11, [rsp + 0x2c0]
mov rbx, qword [r11 + 0x10]
mov rdi, qword [r11 + 0x20]
mov rsp, r11
pop rbp
ret
mov edx, ebx
lea rcx, str.RpcServerConnect_returned:_0x_x_n
call fcn.1400325e0
mov r8b, 4
lea rdx, str.Starting_Rpc_Server..
lea rcx, [rbp - 0x60]
mov r9, qword [rbp - 0x60]
call qword [r9 + 0x48]
mov ecx, ebx
call fcn.14008bacc
nop
mov edx, ebx
lea rcx, str.RpcServerConnect_returned:_0x_x_n
call fcn.1400325e0
mov r8b, 4
lea rdx, str.Starting_Rpc_Server..
lea rcx, [rbp - 0x60]
mov r9, qword [rbp - 0x60]
call qword [r9 + 0x48]
mov ecx, ebx
call fcn.14008bacc
int3