Function at 0x10048fb0
Capabilities:
Query service status
Stop service

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x13c
mov eax, dword [0x1017455c]
xor eax, esp
mov dword [esp + 0x138], eax
push ebx
mov ebx, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 8]
push edi
push 0xff
lea eax, [esp + 0x45]
push 0
push eax
mov dword [esp + 0x1c], esi
mov byte [esp + 0x4c], 0
call fcn.10116880
add esp, 0xc
push 1
push esi
call fcn.1003bf60
add esp, 8
test eax, eax
jne 0x1004901b
mov eax, 1
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x138]
xor ecx, esp
call fcn.1010d699
mov esp, ebp
pop ebp
ret 0xc
mov ecx, esi
call fcn.1003a8b0
test eax, eax
jne 0x1004904a
xor edi, edi
mov ecx, esi
call fcn.1004b160
test eax, eax
jne 0x1004904a
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x138]
xor ecx, esp
call fcn.1010d699
mov esp, ebp
pop ebp
ret 0xc
push 1
push 0
push 0
mov dword [esp + 0x20], 0x12c
mov dword [esp + 0x24], 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov dword [esp + 0x20], eax
test eax, eax
je 0x100491ee
push 0xf01ff
push esi
push eax
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov edi, eax
mov dword [esp + 0x1c], edi
test edi, edi
je 0x100491b4
push esi
mov ecx, edi
call fcn.10048e10
lea ecx, [esp + 0x24]
push ecx
push 1
push edi
call dword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
je 0x1004916f
cmp dword [ebp + 0x10], 0
je 0x100491a0
test ebx, ebx
je 0x100490c6
push 0
push esi
push str.Stopping__s_n
call ebx
add esp, 0xc
lea edx, [esp + 0x24]
push edx
push edi
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
je 0x10049110
cmp dword [esp + 0x28], 3
jne 0x10049110
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
sub dword [esp + 0x14], 1
je 0x100490fe
lea eax, [esp + 0x24]
push eax
push edi
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
jne 0x100490d6
jmp 0x10049110
test ebx, ebx
je 0x10049110
push 0
push 0
push str.CmdStopService_timed_out__n
call ebx
add esp, 0xc
mov eax, 1
cmp dword [esp + 0x28], eax
jne 0x10049147
mov dword [esp + 0x18], eax
test ebx, ebx
je 0x100491a0
push 0
push esi
push str._s_stopped._n
call ebx
add esp, 0xc
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, dword [esp + 0x20]
push eax
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x10049218
test ebx, ebx
je 0x100491a0
push 0
push esi
push str._s_failed_to_stop._n
call ebx
add esp, 0xc
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, dword [esp + 0x20]
push eax
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x10049218
test ebx, ebx
je 0x100491a0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0x100
mov edi, eax
lea esi, [esp + 0x44]
call fcn.10049ce0
mov ecx, dword [esp + 0x14]
add esp, 4
push eax
push ecx
push str.ControlService_Failed:__s___s___n
call ebx
mov edi, dword [esp + 0x28]
add esp, 0xc
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, dword [esp + 0x20]
push eax
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x10049218
test ebx, ebx
je 0x100491e1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0x100
mov edi, eax
lea esi, [esp + 0x44]
call fcn.10049ce0
mov edx, dword [esp + 0x14]
add esp, 4
push eax
push edx
push str.Open_service_failed:__s___s___n
call ebx
add esp, 0xc
mov eax, dword [esp + 0x20]
push eax
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x10049218
test ebx, ebx
je 0x10049218
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0
push 0x100
mov edi, eax
lea esi, [esp + 0x48]
call fcn.10049ce0
add esp, 4
push eax
push str.OpenSCManager_failed:_s__n
call ebx
add esp, 0xc
mov ecx, dword [esp + 0x144]
mov eax, dword [esp + 0x18]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.1010d699
mov esp, ebp
pop ebp
ret 0xc