Function at 0x454c70
Capabilities:
Delete service

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
mov ebx, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 8]
test esi, esi
je 0x454fa5
test ebx, ebx
je 0x454fa5
push esi
push str.Inst_UninstallService:_Attempting_to_uninstall_service:__s
push 2
call fcn.00446b80
add esp, 0xc
cmp dword [ebx], 0
je 0x454cb2
push str.Inst_UninstallService:_Callers_parameter_already_indicates_reboot_required
push 2
call fcn.00446b80
add esp, 8
push str.Inst_UninstallService:_Attempting_to_stop_service_to_be_uninstalled
push 2
call fcn.00446b80
push 0
push esi
call fcn.004543f0
add esp, 0x10
push 0xf003f
push str.ServicesActive
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov ebx, eax
mov dword [ebp - 4], ebx
test ebx, ebx
jne 0x454d69
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
je 0x454d37
cmp eax, 0x57
je 0x454d24
cmp eax, 0x429
je 0x454d11
push str.Inst_UninstallService:_Service_Manager_open_failed
push eax
push 1
call fcn.00447040
add esp, 0xc
jmp 0x454d52
push str.Inst_UninstallService:_Service_Manager_open_failed:_ERROR_DATABASE_DOES_NOT_EXIST
push 1
call fcn.00446b80
push str.Inst_UninstallService:_Service_Manager_open_failed:_system_config_appears_to_be_corrupt
jmp 0x454d48
push str.Inst_UninstallService:_Service_Manager_open_failed:_ERROR_INVALID_PARAMETER
push 1
call fcn.00446b80
push str.Inst_UninstallService:_Service_Manager_open_failed:_system_config_appears_to_be_corrupt
jmp 0x454d48
push str.Inst_UninstallService:_Service_Manager_open_failed:_ERROR_ACCESS_DENIED
push 1
call fcn.00446b80
push str.Inst_UninstallService:_Service_Manager_open_failed:_you_must_be_an_administrator
push 1
call fcn.00446b80
add esp, 0x10
push str.Inst_UninstallService:_service_uninstall_failed
push 1
call fcn.00446b80
add esp, 8
xor eax, eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push edi
push str.Inst_UninstallService:_Service_Manager_successfully_opened
push 0x10
call fcn.00446b80
add esp, 8
push 0x10000
push esi
push ebx
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov edi, eax
test edi, edi
jne 0x454e53
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor esi, esi
cmp eax, 0x7b
ja 0x454e08
je 0x454de9
mov ecx, eax
sub ecx, 5
je 0x454dca
sub ecx, 1
jne 0x454e0f
push str.Inst_UninstallService:_Service_could_not_be_opened:_ERROR_INVALID_HANDLE
push 1
call fcn.00446b80
add esp, 8
push ebx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push str.Inst_UninstallService:_Service_could_not_be_opened:_ERROR_ACCESS_DENIED
push 1
call fcn.00446b80
add esp, 8
push ebx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push str.Inst_UninstallService:_Service_could_not_be_opened:_ERROR_INVALID_NAME
push 1
call fcn.00446b80
add esp, 8
push ebx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp eax, 0x424
je 0x454e2f
push str.Inst_UninstallService:_Service_could_not_be_opened
push eax
push 1
call fcn.00447040
add esp, 0xc
push ebx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push str.Inst_UninstallService:_Service_could_not_be_opened:_ERROR_SERVICE_DOES_NOT_EXIST
push 4
call fcn.00446b80
add esp, 8
mov esi, 1
push ebx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push str.Inst_UninstallService:_Service_successfully_opened
push 0x10
call fcn.00446b80
add esp, 8
push edi
call dword [sym.imp.ADVAPI32.dll_DeleteService]
mov dword [ebp - 8], eax
test eax, eax
jne 0x454eef
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
xor esi, esi
sub ecx, 5
je 0x454ed4
sub ecx, 1
je 0x454ecd
sub ecx, 0x42a
je 0x454ea8
push str.Inst_UninstallService:_Service_could_not_be_deleted
push eax
push 1
call fcn.00447040
add esp, 0xc
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x454f86
push str.Inst_UninstallService:_Service_already_deleted:_ERROR_SERVICE_MARKED_FOR_DELETE
push 2
call fcn.00446b80
mov eax, dword [ebp + 0xc]
add esp, 8
mov esi, 1
push edi
mov dword [eax], esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x454f86
push str.Inst_UninstallService:_Service_could_not_be_deleted:_ERROR_INVALID_HANDLE
jmp 0x454ed9
push str.Inst_UninstallService:_Service_could_not_be_deleted:_ERROR_ACCESS_DENIED
push 1
call fcn.00446b80
add esp, 8
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x454f86
push esi
push str.Inst_UninstallService:_Service_was_deleted:__s
push 2
mov ebx, 0x28
call fcn.00446b80
add esp, 0xc
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push esi
push str.Inst_UninstallService:_Checking_if_reboot_required_for:__s
push 0x20
call fcn.00446b80
add esp, 0xc
push 0x10000
push esi
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov edi, eax
test edi, edi
je 0x454f71
push str.Inst_UninstallService:_Service_still_present__might_check_again
push 2
call fcn.00446b80
add esp, 8
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push 0xfa
xor edi, edi
call dword [sym.imp.KERNEL32.dll_Sleep]
mov eax, ebx
dec ebx
test eax, eax
jne 0x454f04
push str.Inst_UninstallService:_Service_still_present__presuming_reboot_required
push 2
call fcn.00446b80
mov eax, dword [ebp + 0xc]
mov dword [eax], 1
jmp 0x454f7d
push str.Inst_UninstallService:_Service_no_longer_present__presuming_no_need_for_reboot
push 2
call fcn.00446b80
mov esi, dword [ebp - 8]
add esp, 8
mov ebx, dword [ebp - 4]
push ebx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push str.Inst_UninstallService:_returning
push 0x10
call fcn.00446b80
add esp, 8
mov eax, esi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push ebx
push esi
push str.Inst_UninstallService:_invalid_parameter:_0x_08x_0x_08x
push 1
call fcn.00446b80
add esp, 0x10
xor eax, eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret