Function at 0x40fac6
Capabilities:
Delete service
Stop service

Disassembly:
push 0x34
mov eax, 0x43e2e2
call fcn.0043bc87
mov edi, ecx
call fcn.0040f6e2
test eax, eax
jne 0x40fae3
inc eax
jmp 0x40fd48
mov ecx, edi
call fcn.0040e650
push 0xf003f
push 0
push 0
mov dword [ebp - 0x1c], eax
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov dword [ebp - 0x24], ebx
call esi
test ebx, ebx
mov dword [ebp - 0x10], eax
jne 0x40fb89
lea ecx, [ebp - 0x14]
call fcn.00419470
push dword [ebp - 0x10]
and dword [ebp - 4], ebx
lea eax, [ebp - 0x18]
push eax
call fcn.0041a530
pop ecx
pop ecx
mov ecx, eax
mov byte [ebp - 4], 1
call fcn.004195a0
push eax
push dword [ebp - 0x10]
lea eax, [ebp - 0x14]
push str.Unable_to_open_service_control_manager._System_error:___d___s
push eax
call fcn.0041b950
add esp, 0x10
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], bl
call fcn.00419480
lea ecx, [ebp - 0x14]
call fcn.004195a0
push eax
push 1
push 0x179
push str..NBService.cpp
push 0x4593c0
call fcn.0040e4bd
or dword [ebp - 4], 0xffffffff
add esp, 0x14
lea ecx, [ebp - 0x14]
call fcn.00419480
xor eax, eax
jmp 0x40fd48
push 0x10020
add edi, 0x30
push edi
push ebx
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov dword [ebp - 0x14], eax
call esi
cmp dword [ebp - 0x14], 0
mov edi, eax
jne 0x40fc07
push ebx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
lea ecx, [ebp - 0x14]
call fcn.00419470
lea eax, [ebp - 0x18]
push edi
push eax
mov dword [ebp - 4], 2
call fcn.0041a530
pop ecx
pop ecx
mov ecx, eax
mov byte [ebp - 4], 3
call fcn.004195a0
push eax
push edi
lea eax, [ebp - 0x14]
push str.Unable_to_open_service._System_error:___d___s
push eax
call fcn.0041b950
add esp, 0x10
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 2
call fcn.00419480
lea ecx, [ebp - 0x14]
call fcn.004195a0
push eax
push 1
push 0x184
jmp 0x40fb64
and dword [ebp - 0x40], 0
push 6
xor eax, eax
cmp dword [ebp - 0x1c], eax
pop ecx
lea edi, [ebp - 0x3c]
rep stosd dword es:[edi], eax
mov ebx, str..NBService.cpp
mov edi, 0x4593c0
je 0x40fcaf
lea eax, [ebp - 0x40]
push eax
push 1
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
jne 0x40fcaf
call esi
lea ecx, [ebp - 0x18]
mov dword [ebp - 0x10], eax
call fcn.00419470
push dword [ebp - 0x10]
lea eax, [ebp - 0x20]
push eax
mov dword [ebp - 4], 4
call fcn.0041a530
pop ecx
pop ecx
mov ecx, eax
mov byte [ebp - 4], 5
call fcn.004195a0
push eax
push dword [ebp - 0x10]
lea eax, [ebp - 0x18]
push str.Service_control_message_has_failed._System_error:___d___s
push eax
call fcn.0041b950
add esp, 0x10
lea ecx, [ebp - 0x20]
mov byte [ebp - 4], 4
call fcn.00419480
lea ecx, [ebp - 0x18]
call fcn.004195a0
push eax
push 1
push 0x18e
push ebx
push edi
call fcn.0040e4bd
or dword [ebp - 4], 0xffffffff
add esp, 0x14
lea ecx, [ebp - 0x18]
call fcn.00419480
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_DeleteService]
mov dword [ebp - 0x18], eax
call esi
push dword [ebp - 0x14]
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov dword [ebp - 0x10], eax
call esi
push dword [ebp - 0x24]
call esi
cmp dword [ebp - 0x18], 0
jne 0x40fd45
lea ecx, [ebp - 0x1c]
call fcn.00419470
push dword [ebp - 0x10]
lea eax, [ebp - 0x24]
push eax
mov dword [ebp - 4], 6
call fcn.0041a530
pop ecx
pop ecx
mov ecx, eax
mov byte [ebp - 4], 7
call fcn.004195a0
push eax
push dword [ebp - 0x10]
lea eax, [ebp - 0x1c]
push str.Unable_to_delete_the_service._System_error:___d___s
push eax
call fcn.0041b950
add esp, 0x10
lea ecx, [ebp - 0x24]
mov byte [ebp - 4], 6
call fcn.00419480
lea ecx, [ebp - 0x1c]
call fcn.004195a0
push eax
push 1
push 0x19b
push ebx
push edi
call fcn.0040e4bd
or dword [ebp - 4], 0xffffffff
add esp, 0x14
lea ecx, [ebp - 0x1c]
call fcn.00419480
mov eax, dword [ebp - 0x18]
call fcn.0043bd5f
ret