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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x54a764
mov eax, dword fs:[0]
push eax
sub esp, 0x18c
mov eax, dword [0x595c60]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov edi, ecx
mov eax, dword [0x59e598]
mov dword [ebp - 0x64], edi
test al, 1
jne 0x4d7487
or eax, 1
mov dword [0x59e598], eax
mov dword [ebp - 4], 0
call fcn.004a08c0
push 0x54e860
call fcn.0050765d
add esp, 4
mov dword [ebp - 4], 0xffffffff
mov eax, dword [0x596f88]
test byte [eax + 0x1c], 2
je 0x4d749c
cmp byte [eax + 0x19], 6
jb 0x4d749c
mov al, 1
jmp 0x4d749e
xor al, al
cmp byte [0x59e5a8], 0
jne 0x4d74b8
cmp byte [0x59e5a9], 0
jne 0x4d74b8
test al, al
je 0x4d75f1
sub esp, 8
mov dword [ebp - 4], 1
lea ecx, [ebp - 0x100]
call fcn.0047b550
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 2
call fcn.004a0cb0
mov edx, eax
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x100]
call fcn.0047eed0
mov edx, str..Service.cpp
mov ecx, eax
call fcn.0047f130
mov edx, 0x56a378
mov ecx, eax
call fcn.0047f130
push 0x145
mov ecx, eax
call fcn.0047b1b0
mov edx, 0x56a378
mov ecx, eax
call fcn.0047f130
mov edx, 0x56a46c
mov ecx, eax
call fcn.0047f130
mov edx, str.Service::StopService
mov ecx, eax
call fcn.0047f130
mov byte [ebp - 4], 2
cmp dword [ebp - 0x18], 0x10
jb 0x4d754c
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x4d754c
push eax
call fcn.005074d4
add esp, 4
lea eax, [ebp - 0x2c]
push eax
lea ecx, [ebp - 0x100]
call fcn.0047b6a0
mov esi, eax
mov byte [ebp - 4], 4
cmp dword [esi + 0x14], 0x10
jb 0x4d7569
mov esi, dword [esi]
mov eax, dword [0x59e598]
test al, 1
jne 0x4d7594
or eax, 1
mov dword [0x59e598], eax
mov byte [ebp - 4], 5
call fcn.004a08c0
push 0x54e860
call fcn.0050765d
add esp, 4
mov byte [ebp - 4], 4
push esi
push 6
mov ecx, 0x59e5a8
call fcn.004a0b40
cmp dword [ebp - 0x18], 0x10
jb 0x4d75b7
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x4d75b7
push eax
call fcn.005074d4
add esp, 4
lea ecx, [ebp - 0xb0]
mov byte [ebp - 4], 1
call fcn.0047b620
lea eax, [ebp - 0xb0]
mov dword [ebp - 0xb0], 0x56a6f8
push eax
call fcn.0052889f
add esp, 4
jmp 0x4d75ea
mov dword [ebp - 4], 0xffffffff
mov ecx, edi
call fcn.004d8580
mov dword [ebp - 0x64], eax
test eax, eax
je 0x4d77a5
mov eax, dword [0x59e598]
test al, 1
jne 0x4d7634
or eax, 1
mov dword [0x59e598], eax
mov dword [ebp - 4], 7
call fcn.004a08c0
push 0x54e860
call fcn.0050765d
add esp, 4
mov dword [ebp - 4], 0xffffffff
mov eax, dword [0x596f88]
test byte [eax + 0x1c], 2
je 0x4d7649
cmp byte [eax + 0x19], 2
jb 0x4d7649
mov al, 1
jmp 0x4d764b
xor al, al
cmp byte [0x59e5a8], 0
jne 0x4d7665
cmp byte [0x59e5a9], 0
jne 0x4d7665
test al, al
je 0x4d7780
sub esp, 8
mov dword [ebp - 4], 8
lea ecx, [ebp - 0x100]
call fcn.0047b550
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 9
call fcn.004a0cb0
mov edx, eax
mov byte [ebp - 4], 0xa
lea ecx, [ebp - 0x100]
call fcn.0047eed0
mov edx, str..Service.cpp
mov ecx, eax
call fcn.0047f130
mov edx, 0x56a378
mov ecx, eax
call fcn.0047f130
push 0x14c
mov ecx, eax
call fcn.0047b1b0
mov edx, 0x56a378
mov ecx, eax
call fcn.0047f130
mov edx, str.Failed_to_Disable_Lockdown.
mov ecx, eax
call fcn.0047f130
mov byte [ebp - 4], 9
cmp dword [ebp - 0x18], 0x10
jb 0x4d76ed
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x4d76ed
push eax
call fcn.005074d4
add esp, 4
lea eax, [ebp - 0x2c]
push eax
lea ecx, [ebp - 0x100]
call fcn.0047b6a0
mov esi, eax
mov byte [ebp - 4], 0xb
cmp dword [esi + 0x14], 0x10
jb 0x4d770a
mov esi, dword [esi]
mov eax, dword [0x59e598]
test al, 1
jne 0x4d7735
or eax, 1
mov dword [0x59e598], eax
mov byte [ebp - 4], 0xc
call fcn.004a08c0
push 0x54e860
call fcn.0050765d
add esp, 4
mov byte [ebp - 4], 0xb
push esi
push 2
mov ecx, 0x59e5a8
call fcn.004a0b40
cmp dword [ebp - 0x18], 0x10
jb 0x4d7758
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x4d7758
push eax
call fcn.005074d4
add esp, 4
lea ecx, [ebp - 0xb0]
mov byte [ebp - 4], 8
call fcn.0047b620
lea eax, [ebp - 0xb0]
mov dword [ebp - 0xb0], 0x56a6f8
push eax
call fcn.0052889f
add esp, 4
mov eax, dword [ebp - 0x64]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.00506c7d
mov esp, ebp
pop ebp
ret
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov dword [edi + 0x4c], eax
test eax, eax
je 0x4d7a9e
cmp dword [edi + 0x80], 8
lea ecx, [edi + 0x6c]
jb 0x4d77cd
mov ecx, dword [ecx]
push 0xf01ff
push ecx
push eax
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov dword [edi + 0x50], eax
test eax, eax
je 0x4d792f
mov ebx, dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
lea ecx, [ebp - 0x48]
push ecx
push eax
call ebx
cmp dword [ebp - 0x44], 1
je 0x4d7a45
lea eax, [ebp - 0x48]
push eax
push 0xda
push dword [edi + 0x50]
call dword [sym.imp.ADVAPI32.dll_ControlService]
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov esi, eax
cmp dword [ebp - 0x44], 1
je 0x4d7a45
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, esi
cmp eax, 0x7530
jbe 0x4d7916
push 2
push ecx
call fcn.004a0950
add esp, 4
mov ecx, eax
call fcn.004a0b00
test al, al
je 0x4d7906
sub esp, 8
mov dword [ebp - 4], 0xe
lea ecx, [ebp - 0x100]
call fcn.0047b550
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 0xf
call fcn.004a0cb0
mov edx, eax
mov byte [ebp - 4], 0x10
lea ecx, [ebp - 0x100]
call fcn.0047eed0
mov edx, str..Service.cpp
mov ecx, eax
call fcn.0047f130
mov edx, 0x56a378
mov ecx, eax
call fcn.0047f130
push 0x170
mov ecx, eax
call fcn.0047b1b0
mov edx, 0x56a378
mov ecx, eax
call fcn.0047f130
mov edx, str.Failed_to_stop_the_service._Timed_Out.
mov ecx, eax
call fcn.0047f130
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 0xf
call fcn.0047ac60
lea eax, [ebp - 0x2c]
push eax
lea ecx, [ebp - 0x100]
call fcn.0047b6a0
mov esi, eax
mov byte [ebp - 4], 0x11
cmp dword [esi + 0x14], 0x10
jb 0x4d78e4
mov esi, dword [esi]
call fcn.004a0950
push esi
push 2
mov ecx, eax
call fcn.004a0b40
lea ecx, [ebp - 0x2c]
call fcn.0047ac60
lea ecx, [ebp - 0x100]
call fcn.004790d0
mov eax, 0x41d
jmp 0x4d7783
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
lea eax, [ebp - 0x48]
push eax
push dword [edi + 0x50]
call ebx
jmp 0x4d7816
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x64], eax
call fcn.004a0950
mov ecx, dword [0x596f88]
test byte [ecx + 0x1c], 2
je 0x4d7953
cmp byte [ecx + 0x19], 2
jb 0x4d7953
mov cl, 1
jmp 0x4d7955
xor cl, cl
cmp byte [eax], 0
jne 0x4d7968
cmp byte [eax + 1], 0
jne 0x4d7968
test cl, cl
je 0x4d7a45
sub esp, 8
mov dword [ebp - 4], 0x13
lea ecx, [ebp - 0x100]
call fcn.0047b550
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 0x14
call fcn.004a0cb0
mov edx, eax
mov byte [ebp - 4], 0x15
lea ecx, [ebp - 0x100]
call fcn.0047eed0
mov edx, str..Service.cpp
mov ecx, eax
call fcn.0047f130
mov edx, 0x56a378
mov ecx, eax
call fcn.0047f130
push 0x17c
mov ecx, eax
call fcn.0047b1b0
mov edx, 0x56a378
mov ecx, eax
call fcn.0047f130
mov edx, str.Failed_to_open_service._Service_Uninstall_Failed.
mov ecx, eax
call fcn.0047f130
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 0x14
call fcn.0047ac60
lea eax, [ebp - 0x60]
push eax
lea ecx, [ebp - 0x100]
call fcn.0047b6a0
mov esi, eax
mov byte [ebp - 4], 0x16
cmp dword [esi + 0x14], 0x10
jb 0x4d79ff
mov esi, dword [esi]
call fcn.004a0950
push esi
push 2
mov ecx, eax
call fcn.004a0b40
lea ecx, [ebp - 0x60]
call fcn.0047ac60
mov byte [ebp - 4], 0x13
lea ecx, [ebp - 0xb0]
call fcn.0047b620
lea eax, [ebp - 0xb0]
mov dword [ebp - 0xb0], 0x56a6f8
push eax
call fcn.0052889f
add esp, 4
mov dword [ebp - 4], 0xffffffff
mov eax, dword [0x59e598]
test al, 1
jne 0x4d7a75
or dword [0x59e598], 1
mov dword [ebp - 4], 0x1e
call fcn.004a08c0
push 0x54e860
call fcn.0050765d
add esp, 4
mov dword [ebp - 4], 0xffffffff
mov ecx, dword [0x596f88]
test byte [ecx + 0x1c], 2
je 0x4d7be2
cmp byte [ecx + 0x19], 6
jb 0x4d7be2
mov al, 1
jmp 0x4d7be4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x64], eax
mov eax, dword [0x59e598]
test al, 1
jne 0x4d7ad7
or dword [0x59e598], 1
mov dword [ebp - 4], 0x18
call fcn.004a08c0
push 0x54e860
call fcn.0050765d
add esp, 4
mov dword [ebp - 4], 0xffffffff
mov ecx, dword [0x596f88]
test byte [ecx + 0x1c], 2
je 0x4d7aed
cmp byte [ecx + 0x19], 2
jb 0x4d7aed
mov al, 1
jmp 0x4d7aef
xor al, al
cmp byte [0x59e5a8], 0
jne 0x4d7b09
cmp byte [0x59e5a9], 0
jne 0x4d7b09
test al, al
je 0x4d7a45
sub esp, 8
mov dword [ebp - 4], 0x19
lea ecx, [ebp - 0x100]
call fcn.0047b550
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 0x1a
call fcn.004a0cb0
mov edx, eax
mov byte [ebp - 4], 0x1b
lea ecx, [ebp - 0x100]
call fcn.0047eed0
mov edx, str..Service.cpp
mov ecx, eax
call fcn.0047f130
mov edx, 0x56a378
mov ecx, eax
call fcn.0047f130
push 0x182
mov ecx, eax
call fcn.0047b1b0
mov edx, 0x56a378
mov ecx, eax
call fcn.0047f130
mov edx, str.Failed_to_open_SCManager._Service_Uninstall_Failed.
mov ecx, eax
call fcn.0047f130
mov byte [ebp - 4], 0x1a
cmp dword [ebp - 0x18], 0x10
jb 0x4d7b91
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x4d7b91
push eax
call fcn.005074d4
add esp, 4
lea eax, [ebp - 0x2c]
push eax
lea ecx, [ebp - 0x100]
call fcn.0047b6a0
mov esi, eax
mov byte [ebp - 4], 0x1c
cmp dword [esi + 0x14], 0x10
jb 0x4d7bae
mov esi, dword [esi]
call fcn.004a0950
push esi
push 2
mov ecx, eax
call fcn.004a0b40
cmp dword [ebp - 0x18], 0x10
jb 0x4d7bd3
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x4d7bd3
push eax
call fcn.005074d4
add esp, 4
mov byte [ebp - 4], 0x19
jmp 0x4d7a1a
xor al, al
cmp byte [0x59e5a8], 0
jne 0x4d7bfe
cmp byte [0x59e5a9], 0
jne 0x4d7bfe
test al, al
je 0x4d7780
sub esp, 8
mov dword [ebp - 4], 0x1f
lea ecx, [ebp - 0x198]
call fcn.0047b550
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 0x20
call fcn.004a0cb0
mov edx, eax
mov byte [ebp - 4], 0x21
lea ecx, [ebp - 0x198]
call fcn.0047eed0
mov edx, str..Service.cpp
mov ecx, eax
call fcn.0047f130
mov edx, 0x56a378
mov ecx, eax
call fcn.0047f130
push 0x185
mov ecx, eax
call fcn.0047b1b0
mov edx, 0x56a378
mov ecx, eax
call fcn.0047f130
mov edx, 0x56a498
mov ecx, eax
call fcn.0047f130
mov edx, str.Service::StopService
mov ecx, eax
call fcn.0047f130
mov byte [ebp - 4], 0x20
cmp dword [ebp - 0x18], 0x10
jb 0x4d7c92
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x4d7c92
push eax
call fcn.005074d4
add esp, 4
lea eax, [ebp - 0x2c]
push eax
lea ecx, [ebp - 0x198]
call fcn.0047b6a0
mov esi, eax
mov byte [ebp - 4], 0x22
cmp dword [esi + 0x14], 0x10
jb 0x4d7caf
mov esi, dword [esi]
mov eax, dword [0x59e598]
test al, 1
jne 0x4d7cda
or eax, 1
mov dword [0x59e598], eax
mov byte [ebp - 4], 0x23
call fcn.004a08c0
push 0x54e860
call fcn.0050765d
add esp, 4
mov byte [ebp - 4], 0x22
push esi
push 6
mov ecx, 0x59e5a8
call fcn.004a0b40
cmp dword [ebp - 0x18], 0x10
jb 0x4d7cfd
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x4d7cfd
push eax
call fcn.005074d4
add esp, 4
lea ecx, [ebp - 0x148]
mov dword [ebp - 0x18], 0xf
mov dword [ebp - 0x1c], 0
mov byte [ebp - 0x2c], 0
mov byte [ebp - 4], 0x1f
call fcn.0047b620
lea eax, [ebp - 0x148]
mov dword [ebp - 0x148], 0x56a6f8
push eax
call fcn.0052889f
add esp, 4
jmp 0x4d7780