Function at 0x415b70
Capabilities:
Check for time delay via gettickcount
Query service status
Stop service

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x46878d
mov eax, dword fs:[0]
push eax
sub esp, 0xf0
mov eax, dword [0x4a3a10]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
mov dword [ebp - 0x8c], eax
test eax, eax
jne 0x415c59
xorps xmm0, xmm0
mov dword [ebp - 0x18], eax
push 0x30
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x14], 0xf
movups xmmword [ebp - 0x28], xmm0
call fcn.00410e00
movups xmm0, xmmword [str.Service_Control_Manager_have_NULL_handle]
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x18], 0x28
mov dword [ebp - 0x14], 0x2f
movups xmmword [eax], xmm0
movups xmm0, xmmword [0x46eefc]
movups xmmword [eax + 0x10], xmm0
movq xmm0, qword [0x46ef0c]
movq qword [eax + 0x20], xmm0
mov byte [eax + 0x28], 0
mov dword [ebp - 4], 0
lea eax, [ebp - 0x28]
push eax
call fcn.00411f60
mov ecx, dword [ebp - 0x14]
add esp, 4
mov byte [ebp - 0x7e], al
cmp ecx, 0x10
jb 0x4163f1
mov edx, dword [ebp - 0x28]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x415c47
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x416508
push ecx
push edx
call fcn.0044781c
mov al, byte [ebp - 0x7e]
add esp, 8
jmp 0x4163f1
test edi, edi
jne 0x415cb0
xorps xmm0, xmm0
mov dword [ebp - 0x18], edi
push 0x20
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x14], 0xf
movups xmmword [ebp - 0x28], xmm0
call fcn.00410e00
movups xmm0, xmmword [str.Service_have_NULL_handle]
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x18], 0x18
mov dword [ebp - 0x14], 0x1f
movups xmmword [eax], xmm0
movq xmm0, qword [0x46ef28]
movq qword [eax + 0x10], xmm0
mov byte [eax + 0x18], 0
mov dword [ebp - 4], 1
jmp 0x415c0a
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [ebp - 0x88], eax
lea eax, [ebp - 0x84]
push eax
push 0x24
lea eax, [ebp - 0x7c]
push eax
push 0
push edi
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatusEx]
cmp eax, 1
je 0x415d5d
xorps xmm0, xmm0
mov dword [ebp - 0x18], 0
push 0x50
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x14], 0xf
movups xmmword [ebp - 0x28], xmm0
call fcn.00410e00
movups xmm0, xmmword [str.Cannot_query_service_status_when_we_check_the_service_is_not_already_stopped]
mov ecx, eax
mov dword [ebp - 0x18], 0x4c
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x14], 0x4f
movups xmmword [ecx], xmm0
movups xmm0, xmmword [0x46f2c8]
movups xmmword [ecx + 0x10], xmm0
movups xmm0, xmmword [0x46f2d8]
movups xmmword [ecx + 0x20], xmm0
movups xmm0, xmmword [0x46f2e8]
movups xmmword [ecx + 0x30], xmm0
movq xmm0, qword [0x46f2f8]
movq qword [ecx + 0x40], xmm0
mov eax, dword [0x46f300]
mov dword [ecx + 0x48], eax
mov byte [ecx + 0x4c], 0
mov dword [ebp - 4], 2
jmp 0x415c0a
cmp dword [ebp - 0x78], 1
jne 0x415e18
call fcn.0042edd0
mov esi, eax
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0
mov ecx, dword [esi + 0x2c]
cmp ecx, 2
mov al, byte [esi + 0x90]
setle byte [ebp - 0x7e]
mov byte [ebp - 0x7d], al
jle 0x415d99
test al, al
je 0x4163ef
sub esp, 8
lea ecx, [esi + 8]
mov eax, esp
push 2
sub esp, 8
mov dword [eax], str.Service_now_stopped
mov dword [eax + 4], 0x13
mov edx, esp
cmp dword [esi + 0x1c], 0x10
jb 0x415dbe
mov ecx, dword [esi + 8]
movq xmm0, qword [ebp - 0x1c]
sub esp, 0xc
mov dword [edx], ecx
lea ecx, [ebp - 0xc4]
mov eax, dword [esi + 0x18]
mov dword [edx + 4], eax
mov eax, esp
movq qword [eax], xmm0
mov dword [eax + 8], 0
call fcn.0040fc00
cmp byte [ebp - 0x7e], 0
je 0x415dfa
mov eax, dword [esi]
lea ecx, [ebp - 0xc4]
push ecx
mov ecx, esi
call dword [eax + 8]
cmp byte [ebp - 0x7d], 0
je 0x4163ef
lea eax, [ebp - 0xc4]
push eax
lea ecx, [esi + 0x60]
call fcn.00413930
jmp 0x4163ef
call fcn.0042edd0
push dword [ebp - 0x78]
mov esi, eax
lea eax, [ebp - 0x40]
push eax
call fcn.004151c0
add esp, 8
push eax
sub esp, 8
mov dword [ebp - 4], 3
mov eax, esp
mov ecx, esi
mov dword [eax], str.Service_state_before_signal_sending:_
mov dword [eax + 4], 0x27
call fcn.0040a780
lea ecx, [ebp - 0x40]
mov dword [ebp - 4], 0xffffffff
call fcn.0040fdb0
cmp dword [ebp - 0x78], 3
jne 0x415f84
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0
call fcn.0042edd0
mov esi, eax
mov ecx, dword [esi + 0x2c]
cmp ecx, 2
mov al, byte [esi + 0x90]
setle byte [ebp - 0x7d]
mov byte [ebp - 0x7e], al
jle 0x415e96
test al, al
je 0x415f0c
sub esp, 8
lea ecx, [esi + 8]
mov eax, esp
push 2
sub esp, 8
mov dword [eax], str.Service_stop_pending...
mov dword [eax + 4], 0x17
mov edx, esp
cmp dword [esi + 0x1c], 0x10
jb 0x415ebb
mov ecx, dword [esi + 8]
movq xmm0, qword [ebp - 0x1c]
sub esp, 0xc
mov dword [edx], ecx
lea ecx, [ebp - 0xc4]
mov eax, dword [esi + 0x18]
mov dword [edx + 4], eax
mov eax, esp
movq qword [eax], xmm0
mov dword [eax + 8], 0
call fcn.0040fc00
cmp byte [ebp - 0x7d], 0
je 0x415ef7
mov eax, dword [esi]
lea ecx, [ebp - 0xc4]
push ecx
mov ecx, esi
call dword [eax + 8]
cmp byte [ebp - 0x7e], 0
je 0x415f0c
lea eax, [ebp - 0xc4]
lea ecx, [esi + 0x60]
push eax
call fcn.00413930
mov eax, 0xcccccccd
mul dword [ebp - 0x64]
shr edx, 3
cmp edx, 0x3e8
jae 0x415f26
mov edx, 0x3e8
jmp 0x415f34
cmp edx, 0x2710
mov eax, 0x2710
cmova edx, eax
push edx
call dword [sym.imp.KERNEL32.dll_Sleep]
lea eax, [ebp - 0x84]
push eax
push 0x24
lea eax, [ebp - 0x7c]
push eax
push 0
push edi
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatusEx]
cmp eax, 1
jne 0x4161ad
cmp dword [ebp - 0x78], eax
je 0x4160fc
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [ebp - 0x88]
cmp eax, 0x7530
ja 0x416051
cmp dword [ebp - 0x78], 3
je 0x415e76
push edi
push dword [ebp - 0x8c]
call fcn.004155a0
add esp, 8
lea eax, [ebp - 0x7c]
push eax
push 1
push edi
call dword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
jne 0x416261
xorps xmm0, xmm0
mov dword [ebp - 0x18], eax
push 0x30
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x14], 0xf
movups xmmword [ebp - 0x28], xmm0
call fcn.00410e00
movups xmm0, xmmword [str.Cannot_send_a_stop_updater_to_the_service]
mov ecx, eax
mov dword [ebp - 0x18], 0x29
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x14], 0x2f
movups xmmword [ecx], xmm0
movups xmm0, xmmword [0x46f3e8]
movups xmmword [ecx + 0x10], xmm0
movq xmm0, qword [0x46f3f8]
movq qword [ecx + 0x20], xmm0
mov al, byte [0x46f400]
mov byte [ecx + 0x28], al
mov byte [ecx + 0x29], 0
mov dword [ebp - 4], 5
lea eax, [ebp - 0x28]
push eax
call fcn.00411f60
mov ecx, dword [ebp - 0x14]
add esp, 4
mov byte [ebp - 0x7d], al
cmp ecx, 0x10
jb 0x4163f1
mov edx, dword [ebp - 0x28]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x41624f
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x41624f
jmp 0x416508
call fcn.0042edd0
mov esi, eax
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0
mov ecx, dword [esi + 0x2c]
cmp ecx, 4
mov al, byte [esi + 0x90]
setle byte [ebp - 0x7d]
mov byte [ebp - 0x7e], al
jle 0x41607f
test al, al
je 0x4160f5
sub esp, 8
lea ecx, [esi + 8]
mov eax, esp
push 4
sub esp, 8
mov dword [eax], str.Service_stop_timed_out
mov dword [eax + 4], 0x16
mov edx, esp
cmp dword [esi + 0x1c], 0x10
jb 0x4160a4
mov ecx, dword [esi + 8]
movq xmm0, qword [ebp - 0x1c]
sub esp, 0xc
mov dword [edx], ecx
lea ecx, [ebp - 0xfc]
mov eax, dword [esi + 0x18]
mov dword [edx + 4], eax
mov eax, esp
movq qword [eax], xmm0
mov dword [eax + 8], 0
call fcn.0040fc00
cmp byte [ebp - 0x7d], 0
je 0x4160e0
mov eax, dword [esi]
lea ecx, [ebp - 0xfc]
push ecx
mov ecx, esi
call dword [eax + 8]
cmp byte [ebp - 0x7e], 0
je 0x4160f5
lea eax, [ebp - 0xfc]
push eax
lea ecx, [esi + 0x60]
call fcn.00413930
xor al, al
jmp 0x4163f1
call fcn.0042edd0
mov esi, eax
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0
mov ecx, dword [esi + 0x2c]
cmp ecx, 2
mov al, byte [esi + 0x90]
setle byte [ebp - 0x7d]
mov byte [ebp - 0x7e], al
jle 0x41612e
test al, al
je 0x4163ef
sub esp, 8
lea ecx, [esi + 8]
mov eax, esp
push 2
sub esp, 8
mov dword [eax], str.Service_stopped_successfully_from_pending_state
mov dword [eax + 4], 0x2f
mov edx, esp
cmp dword [esi + 0x1c], 0x10
jb 0x416153
mov ecx, dword [esi + 8]
movq xmm0, qword [ebp - 0x1c]
sub esp, 0xc
mov dword [edx], ecx
lea ecx, [ebp - 0xfc]
mov eax, dword [esi + 0x18]
mov dword [edx + 4], eax
mov eax, esp
movq qword [eax], xmm0
mov dword [eax + 8], 0
call fcn.0040fc00
cmp byte [ebp - 0x7d], 0
je 0x41618f
mov eax, dword [esi]
lea ecx, [ebp - 0xfc]
push ecx
mov ecx, esi
call dword [eax + 8]
cmp byte [ebp - 0x7e], 0
je 0x4163ef
lea eax, [ebp - 0xfc]
push eax
lea ecx, [esi + 0x60]
call fcn.00413930
jmp 0x4163ef
xorps xmm0, xmm0
mov dword [ebp - 0x30], 0
push 0x40
lea ecx, [ebp - 0x40]
mov dword [ebp - 0x2c], 0xf
movups xmmword [ebp - 0x40], xmm0
call fcn.00410e00
movups xmm0, xmmword [str.Cannot_query_service_status_in_stop_pending_state]
mov ecx, eax
mov dword [ebp - 0x30], 0x31
mov dword [ebp - 0x40], ecx
mov dword [ebp - 0x2c], 0x3f
movups xmmword [ecx], xmm0
movups xmm0, xmmword [0x46f36c]
movups xmmword [ecx + 0x10], xmm0
movups xmm0, xmmword [0x46f37c]
movups xmmword [ecx + 0x20], xmm0
mov al, byte [0x46f38c]
mov byte [ecx + 0x30], al
mov byte [ecx + 0x31], 0
mov dword [ebp - 4], 4
lea eax, [ebp - 0x40]
push eax
call fcn.00411f60
mov ecx, dword [ebp - 0x2c]
add esp, 4
mov byte [ebp - 0x7d], al
cmp ecx, 0x10
jb 0x4163f1
mov edx, dword [ebp - 0x40]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x41624f
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x416508
push ecx
push edx
call fcn.0044781c
mov al, byte [ebp - 0x7d]
add esp, 8
jmp 0x4163f1
lea eax, [ebp - 0x7c]
push eax
push edi
call fcn.004120d0
add esp, 8
test al, al
jne 0x4162f8
xorps xmm0, xmm0
mov dword [ebp - 0x18], 0
push 0x50
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x14], 0xf
movups xmmword [ebp - 0x28], xmm0
call fcn.00410e00
movups xmm0, xmmword [str.Cannot_query_service_status_when_we_wait_while_the_service_is_not_stopped]
mov ecx, eax
mov dword [ebp - 0x18], 0x49
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x14], 0x4f
movups xmmword [ecx], xmm0
movups xmm0, xmmword [0x46f418]
movups xmmword [ecx + 0x10], xmm0
movups xmm0, xmmword [0x46f428]
movups xmmword [ecx + 0x20], xmm0
movups xmm0, xmmword [0x46f438]
movups xmmword [ecx + 0x30], xmm0
movq xmm0, qword [0x46f448]
movq qword [ecx + 0x40], xmm0
mov al, byte [0x46f450]
mov byte [ecx + 0x48], al
mov byte [ecx + 0x49], 0
mov dword [ebp - 4], 6
jmp 0x41600b
call fcn.0042edd0
push dword [ebp - 0x78]
mov esi, eax
lea eax, [ebp - 0x28]
push eax
call fcn.004151c0
add esp, 8
push eax
sub esp, 8
mov dword [ebp - 4], 7
mov eax, esp
mov ecx, esi
mov dword [eax], str.Service_state_after_signal_sending:_
mov dword [eax + 4], 0x26
call fcn.0040a780
lea ecx, [ebp - 0x28]
mov dword [ebp - 4], 0xffffffff
call fcn.0040fdb0
cmp dword [ebp - 0x78], 1
je 0x41638e
push dword [ebp - 0x64]
call dword [sym.imp.KERNEL32.dll_Sleep]
lea eax, [ebp - 0x8c]
push eax
push 0x24
lea eax, [ebp - 0x7c]
push eax
push 0
push edi
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatusEx]
cmp eax, 1
jne 0x41646c
cmp dword [ebp - 0x78], eax
je 0x41638e
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [ebp - 0x88]
cmp eax, 0x7530
ja 0x41640c
cmp dword [ebp - 0x78], 1
jne 0x416344
lea eax, [ebp - 0x7c]
push eax
push edi
call fcn.004120d0
call fcn.0042edd0
push dword [ebp - 0x78]
mov esi, eax
lea eax, [ebp - 0x58]
push eax
call fcn.004151c0
add esp, 0x10
push eax
sub esp, 8
mov dword [ebp - 4], 0xa
mov eax, esp
mov ecx, esi
mov dword [eax], str.Service_final_State:_
mov dword [eax + 4], 0x17
call fcn.0040a780
lea ecx, [ebp - 0x58]
mov dword [ebp - 4], 0xffffffff
call fcn.0040fdb0
call fcn.0042edd0
push str.Service_stopped_successfully
mov ecx, eax
call fcn.0040a6d0
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00447a97
mov esp, ebp
pop ebp
ret
xorps xmm0, xmm0
mov dword [ebp - 0x30], 0
push 0x40
lea ecx, [ebp - 0x40]
mov dword [ebp - 0x2c], 0xf
movups xmmword [ebp - 0x40], xmm0
call fcn.00410e00
movups xmm0, xmmword [str.Expired_timeout_while_the_service_is_not_stopped]
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x30], 0x30
mov dword [ebp - 0x2c], 0x3f
movups xmmword [eax], xmm0
movups xmm0, xmmword [0x46f48c]
movups xmmword [eax + 0x10], xmm0
movups xmm0, xmmword [0x46f49c]
movups xmmword [eax + 0x20], xmm0
mov byte [eax + 0x30], 0
mov dword [ebp - 4], 9
jmp 0x416212
xorps xmm0, xmm0
mov dword [ebp - 0x30], 0
push 0x50
lea ecx, [ebp - 0x40]
mov dword [ebp - 0x2c], 0xf
movups xmmword [ebp - 0x40], xmm0
call fcn.00410e00
movups xmm0, xmmword [str.Cannot_query_service_status_when_we_wait_while_the_service_is_not_stopped]
mov ecx, eax
mov dword [ebp - 0x30], 0x49
mov dword [ebp - 0x40], ecx
mov dword [ebp - 0x2c], 0x4f
movups xmmword [ecx], xmm0
movups xmm0, xmmword [0x46f418]
movups xmmword [ecx + 0x10], xmm0
movups xmm0, xmmword [0x46f428]
movups xmmword [ecx + 0x20], xmm0
movups xmm0, xmmword [0x46f438]
movups xmmword [ecx + 0x30], xmm0
movq xmm0, qword [0x46f448]
movq qword [ecx + 0x40], xmm0
mov al, byte [0x46f450]
mov byte [ecx + 0x48], al
mov byte [ecx + 0x49], 0
lea eax, [ebp - 0x40]
mov dword [ebp - 4], 8
push eax
call fcn.00411f60
add esp, 4
mov byte [ebp - 0x7d], al
lea ecx, [ebp - 0x40]
call fcn.0040fdb0
mov al, byte [ebp - 0x7d]
jmp 0x4163f1
call fcn.0044c8cf
int3