Function at 0x14003c590
Capabilities:
Delete service

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x30
neg dword [rsp + 0x88]
mov edi, r9d
mov eax, dword [0x140263bb0]
mov r15, r8
sbb ebp, ebp
mov r12, rdx
add ebp, 3
mov rbx, rcx
cmp eax, 0xffffffff
jne 0x14003c5cf
call fcn.14003d7c0
cmp eax, 2
mov r13d, 0x2f80
mov ecx, reloc.WS2_32.dll_recv
mov r14d, pe_nt_image_headers64
cmovg r14d, ecx
cmp qword [0x140279320], 0
je 0x14003c66c
lea rcx, [rsp + 0x58]
mov rdx, rbx
sub rcx, 8
call fcn.1400296d0
mov rcx, qword [0x140279320]
mov r8d, 4
mov rdx, qword [rax]
call qword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov rcx, rax
call fcn.1401712b0
test rax, rax
je 0x14003c66c
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
movsxd rcx, eax
call fcn.140171260
test rax, rax
jne 0x14003c64c
lea rdx, str.Failed_close_service_handle:__m
mov ecx, 0x5b0003
call fcn.14002d450
test edi, edi
jne 0x14003c674
mov r8, rbx
lea rdx, str.Service__s_already_existed
mov ecx, 0x5b0003
call fcn.14002d450
or eax, 0xffffffff
jmp 0x14003c858
test edi, edi
je 0x14003c74c
or edi, 0xffffffff
mov qword [rsp + 0x60], rsi
cmp qword [0x140279320], 0
je 0x14003c718
lea rcx, [rsp + 0x58]
mov rdx, rbx
sub rcx, 8
call fcn.1400296d0
mov rcx, qword [0x140279320]
mov r8d, 0x10000
mov rdx, qword [rax]
call qword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov rcx, rax
call fcn.1401712b0
mov rsi, rax
test rax, rax
je 0x14003c718
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_DeleteService]
movsxd rcx, eax
call fcn.140171260
test rax, rax
jne 0x14003c6ed
mov r8, rbx
lea rdx, str.Failed_deleting_service__s:__m
mov ecx, 0x5b0003
call fcn.14002d450
jmp 0x14003c6ef
xor edi, edi
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
movsxd rcx, eax
call fcn.140171260
test rax, rax
jne 0x14003c73f
lea rdx, str.Failed_close_service_handle:__m
mov ecx, 0x5b0003
call fcn.14002d450
jmp 0x14003c73f
mov rax, qword gs:[0x58]
mov rcx, qword [rax]
mov rax, qword [r13 + rcx]
test rax, rax
jne 0x14003c733
call fcn.1401762d4
mov ecx, dword [rax]
sub ecx, 0x424
neg ecx
sbb edi, edi
mov rsi, qword [rsp + 0x60]
test edi, edi
jne 0x14003c664
mov qword [rsp + 0x28], r15
mov r9d, r14d
mov r8d, 0xf01ff
mov dword [rsp + 0x20], ebp
mov rdx, r12
mov rcx, rbx
call fcn.14003d300
mov rcx, rax
call fcn.1401712b0
test rax, rax
jne 0x14003c82f
mov r8, rbx
lea rdx, str.Failed_creating_service__s:__m
mov ecx, 0x5b0003
call fcn.14002d450
mov edi, dword [rsp + 0x80]
test edi, edi
je 0x14003c816
mov rax, qword gs:[0x58]
mov rcx, qword [rax]
mov rax, qword [r13 + rcx]
test rax, rax
jne 0x14003c7b4
call fcn.1401762d4
cmp dword [rax], 0x430
jne 0x14003c816
mov r8d, edi
lea rdx, str.Trying_again_in__d_ms
mov ecx, 0x5b0003
call fcn.14002d450
mov ecx, edi
call qword [sym.imp.KERNEL32.dll_Sleep]
mov r9d, r14d
mov qword [rsp + 0x28], r15
mov r8d, 0xf01ff
mov dword [rsp + 0x20], ebp
mov rdx, r12
mov rcx, rbx
call fcn.14003d300
mov rcx, rax
call fcn.1401712b0
test rax, rax
jne 0x14003c82f
mov r8, rbx
lea rdx, str.Failed_creating_service__s_after_timeout:__m
mov ecx, 0x5b0003
call fcn.14002d450
mov r8, rbx
lea rdx, str.Service__s_could_not_be_recreated
mov ecx, 0x5b0003
call fcn.14002d450
or eax, 0xffffffff
jmp 0x14003c858
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
movsxd rcx, eax
call fcn.140171260
test rax, rax
jne 0x14003c856
lea rdx, str.Failed_close_service_handle:__m
mov ecx, 0x5b0003
call fcn.14002d450
xor eax, eax
mov rbx, qword [rsp + 0x68]
mov rbp, qword [rsp + 0x70]
add rsp, 0x30
pop r15
pop r14
pop r13
pop r12
pop rdi
ret