Function at 0x140004034
Capabilities:
Accept command line arguments
Check mutex on windows
Query service status

Disassembly:
mov rax, rsp
push r13
push r14
push r15
sub rsp, 0xb0
mov qword [rax - 0x50], 0xfffffffffffffffe
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
mov qword [rax + 0x20], r12
mov rax, qword [0x140031f88]
xor rax, rsp
mov qword [rsp + 0xa8], rax
xor r9d, r9d
xor r8d, r8d
lea r15d, [r9 + 1]
mov edx, r15d
xor ecx, ecx
call qword [sym.imp.api_ms_win_core_heap_l1_1_0.dll_HeapSetInformation]
nop dword [rax + rax]
call qword [sym.imp.wbemcomn.dll_public:_static_int___cdecl_CStaticCritSec::anyFailure_void_]
nop dword [rax + rax]
xor ebx, ebx
test eax, eax
je 0x1400040a3
lea eax, [rbx + 8]
jmp 0x1400045d3
lea r12, [0x140031110]
mov rcx, r12
call fcn.140005204
mov edi, eax
test eax, eax
js 0x1400045d1
mov eax, dword [0x140021d54]
mov dword [rsp + 0xa0], eax
movzx eax, word [0x140021d58]
mov word [rsp + 0xa4], ax
mov rcx, r12
call fcn.1400052f8
mov edi, eax
mov dword [rsp + 0x30], eax
test eax, eax
js 0x1400045d1
call qword [sym.imp.api_ms_win_core_processenvironment_l1_1_0.dll_GetCommandLineW]
nop dword [rax + rax]
test rax, rax
mov rsi, rax
je 0x140004155
cmp word [rax], bx
je 0x140004155
lea rax, [rsp + 0xa0]
movzx ecx, word [rax]
test cx, cx
je 0x140004130
cmp word [rsi], cx
je 0x140004141
mov rcx, rax
call qword [sym.imp.api_ms_win_core_string_l2_1_0.dll_CharNextW]
nop dword [rax + rax]
test rax, rax
jne 0x14000410f
mov rcx, rsi
call qword [sym.imp.api_ms_win_core_string_l2_1_0.dll_CharNextW]
nop dword [rax + rax]
jmp 0x1400040fa
mov rcx, rsi
call qword [sym.imp.api_ms_win_core_string_l2_1_0.dll_CharNextW]
nop dword [rax + rax]
mov rsi, rax
jmp 0x140004158
mov rsi, rbx
mov r14d, r15d
or r13d, 0xffffffff
test rsi, rsi
je 0x140004289
test r14d, r14d
je 0x14000459a
mov dword [rsp + 0x28], r13d
lea rax, str.UnregServer
mov qword [rsp + 0x20], rax
mov r9d, r13d
mov r8, rsi
mov edx, r15d
mov ecx, 0x7f
call qword [sym.imp.api_ms_win_core_string_l1_1_0.dll_CompareStringW]
nop dword [rax + rax]
cmp eax, 2
jne 0x1400041ca
call fcn.140005d98
mov edi, eax
mov dword [rsp + 0x30], eax
test eax, eax
js 0x140004222
mov r8d, r15d
xor edx, edx
mov rcx, qword [0x140031160]
call fcn.140006990
xor ecx, ecx
call fcn.140003c68
jmp 0x140004222
mov dword [rsp + 0x28], r13d
lea rax, str.RegServer
mov qword [rsp + 0x20], rax
mov r9d, r13d
mov r8, rsi
mov edx, r15d
mov ecx, 0x7f
call qword [sym.imp.api_ms_win_core_string_l1_1_0.dll_CompareStringW]
nop dword [rax + rax]
cmp eax, 2
jne 0x140004225
call fcn.140005a40
mov edi, eax
mov dword [rsp + 0x30], eax
test eax, eax
js 0x140004222
mov ecx, r15d
call fcn.140003c68
mov r8d, r13d
xor edx, edx
mov rcx, qword [0x140031160]
call fcn.140006990
mov r14d, ebx
cmp word [rsi], bx
je 0x14000426a
lea rax, [rsp + 0xa0]
movzx ecx, word [rax]
test cx, cx
je 0x140004253
cmp word [rsi], cx
je 0x140004272
mov rcx, rax
call qword [sym.imp.api_ms_win_core_string_l2_1_0.dll_CharNextW]
nop dword [rax + rax]
test rax, rax
jne 0x140004232
mov rcx, rsi
call qword [sym.imp.api_ms_win_core_string_l2_1_0.dll_CharNextW]
nop dword [rax + rax]
mov rsi, rax
test rax, rax
jne 0x140004225
mov rsi, rbx
jmp 0x14000415f
mov rcx, rsi
call qword [sym.imp.api_ms_win_core_string_l2_1_0.dll_CharNextW]
nop dword [rax + rax]
mov rsi, rax
jmp 0x14000415f
test r14d, r14d
je 0x14000459a
mov rdx, r12
lea rcx, [rsp + 0x38]
call fcn.140005840
cmp qword [0x140031140], rbx
jne 0x14000457f
mov rcx, qword [0x140031150]
test rcx, rcx
je 0x14000457f
lea r8, str.GlobalWmiApSrv
xor edx, edx
mov rcx, qword [rcx + 8]
call qword [sym.imp.api_ms_win_core_synch_l1_1_0.dll_CreateMutexW]
nop dword [rax + rax]
mov qword [0x140031140], rax
test rax, rax
je 0x14000457f
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
nop dword [rax + rax]
mov rcx, qword [rsp + 0x38]
cmp eax, 0xb7
je 0x140004584
test rcx, rcx
je 0x140004312
call qword [sym.imp.api_ms_win_core_synch_l1_1_0.dll_LeaveCriticalSection]
nop dword [rax + rax]
lea rdx, [0x140032648]
lea rcx, [rsp + 0x40]
call fcn.140005840
mov qword [0x140032620], rbx
mov dword [0x140032628], 0x10
mov dword [0x14003262c], r15d
mov dword [0x140032630], r15d
xorps xmm0, xmm0
movups xmmword [0x140032634], xmm0
mov rcx, qword [rsp + 0x40]
test rcx, rcx
je 0x140004362
call qword [sym.imp.api_ms_win_core_synch_l1_1_0.dll_LeaveCriticalSection]
nop dword [rax + rax]
xor edx, edx
xor ecx, ecx
mov r8d, 0xf003f
call qword [sym.imp.api_ms_win_service_management_l1_1_0.dll_OpenSCManagerW]
nop dword [rax + rax]
mov r15, rax
mov qword [rsp + 0x48], rax
test rax, rax
je 0x140004546
mov r8d, 5
lea r12, str.WmiApSrv
mov rdx, r12
mov rcx, rax
call qword [sym.imp.api_ms_win_service_management_l1_1_0.dll_OpenServiceW]
nop dword [rax + rax]
mov r14, rax
mov qword [rsp + 0x50], rax
test rax, rax
je 0x14000450d
mov rsi, rbx
mov qword [rsp + 0x40], rbx
mov dword [rsp + 0x38], ebx
lea r9, [rsp + 0x38]
xor r8d, r8d
xor edx, edx
mov rcx, rax
call qword [sym.imp.api_ms_win_service_management_l2_1_0.dll_QueryServiceConfigW]
nop dword [rax + rax]
test eax, eax
jne 0x140004442
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
nop dword [rax + rax]
cmp eax, 0x7a
jne 0x140004442
mov edx, dword [rsp + 0x38]
lea ecx, [rax - 0x3a]
call qword [sym.imp.api_ms_win_core_heap_l2_1_0.dll_LocalAlloc]
nop dword [rax + rax]
mov rsi, rax
mov qword [rsp + 0x40], rax
test rax, rax
je 0x140004442
lea r9, [rsp + 0x38]
mov r8d, dword [rsp + 0x38]
mov rdx, rax
mov rcx, r14
call qword [sym.imp.api_ms_win_service_management_l2_1_0.dll_QueryServiceConfigW]
nop dword [rax + rax]
test eax, eax
je 0x140004442
mov ecx, ebx
cmp dword [rsi + 4], 3
sete cl
mov dword [0x1400311a0], ecx
jmp 0x140004460
mov rcx, rsi
call qword [sym.imp.api_ms_win_core_heap_l2_1_0.dll_LocalFree]
nop dword [rax + rax]
lea rdx, [rsp + 0x80]
mov rcx, r14
call qword [sym.imp.api_ms_win_service_winsvc_l1_1_0.dll_QueryServiceStatus]
nop dword [rax + rax]
test eax, eax
je 0x1400044f1
cmp dword [rsp + 0x84], 4
je 0x1400044ea
mov qword [rsp + 0x58], r12
lea rax, [0x1400058f0]
mov qword [rsp + 0x60], rax
mov qword [rsp + 0x68], rbx
mov qword [rsp + 0x70], rbx
lea rcx, [rsp + 0x58]
call qword [sym.imp.api_ms_win_service_core_l1_1_0.dll_StartServiceCtrlDispatcherW]
nop dword [rax + rax]
test eax, eax
jne 0x140004530
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
nop dword [rax + rax]
movzx ecx, ax
or ecx, 0x80070000
test eax, eax
cmovle ecx, eax
mov edi, 0x80070015
test ecx, ecx
cmovs edi, ecx
jmp 0x140004530
mov edi, 0x800700b7
jmp 0x140004530
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
nop dword [rax + rax]
movzx edi, ax
or edi, 0x80070000
test eax, eax
cmovle edi, eax
jmp 0x140004530
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
nop dword [rax + rax]
movzx edi, ax
or edi, 0x80070000
test eax, eax
cmovle edi, eax
test edi, edi
js 0x140004569
mov edi, 0x80004005
test r14, r14
je 0x140004569
mov rcx, r14
call qword [sym.imp.api_ms_win_service_management_l1_1_0.dll_CloseServiceHandle]
nop dword [rax + rax]
jmp 0x140004569
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
nop dword [rax + rax]
movzx edi, ax
or edi, 0x80070000
test eax, eax
cmovle edi, eax
test edi, edi
js 0x14000459a
mov edi, 0x80004005
test r15, r15
je 0x14000459a
mov rcx, r15
call qword [sym.imp.api_ms_win_service_management_l1_1_0.dll_CloseServiceHandle]
nop dword [rax + rax]
jmp 0x14000459a
mov rcx, qword [rsp + 0x38]
test rcx, rcx
je 0x140004595
call qword [sym.imp.api_ms_win_core_synch_l1_1_0.dll_LeaveCriticalSection]
nop dword [rax + rax]
mov edi, 0x800700b7
jmp 0x1400045a0
test edi, edi
js 0x1400045d1
lea rdx, [0x140032648]
lea rcx, [rsp + 0x48]
call fcn.140005840
mov rcx, qword [rsp + 0x48]
test rcx, rcx
je 0x1400045cb
call qword [sym.imp.api_ms_win_core_synch_l1_1_0.dll_LeaveCriticalSection]
nop dword [rax + rax]
mov edi, dword [0x140032634]
mov eax, edi
mov rcx, qword [rsp + 0xa8]
xor rcx, rsp
call fcn.14001af60
lea r11, [rsp + 0xb0]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rdi, qword [r11 + 0x30]
mov r12, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop r13
ret