Function at 0x40c8b6
Capabilities:
Query service status

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4c
mov eax, dword [0x426fa0]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov eax, ecx
push edi
lea esi, [eax + 0xec]
push esi
mov dword [ebp - 0x38], eax
call fcn.0041d26c
push esi
push 0x4029d8
push 2
call fcn.0040ced0
call fcn.0041099f
push 0x80000000
xor edi, edi
push edi
push edi
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov dword [ebp - 0x4c], eax
test eax, eax
jne 0x40c92b
push esi
call fcn.0041d26c
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x30], eax
lea eax, [ebp - 0x30]
push eax
push esi
push 0x402a78
push 2
call fcn.0040cf3b
call fcn.0041099f
jmp 0x40cb1d
push 4
push 0x402b54
push eax
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov dword [ebp - 0x30], eax
test eax, eax
jne 0x40c96a
push esi
call fcn.0041d26c
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x30], eax
lea eax, [ebp - 0x30]
push eax
push esi
push 0x402b68
push 2
call fcn.0040cfac
call fcn.0041099f
jmp 0x40cb14
push ebx
mov dword [ebp - 0x40], edi
mov dword [ebp - 0x34], edi
xor eax, eax
push 0xa
lea edi, [ebp - 0x3c]
stosd dword es:[edi], eax
mov edi, dword [ebp - 0x38]
pop ebx
lea eax, [ebp - 0x40]
push eax
mov ecx, edi
call fcn.0040ccad
lea eax, [ebp - 0x40]
push eax
mov ecx, edi
call fcn.0040ccda
test al, al
jne 0x40caf1
push 8
pop ecx
xor edx, edx
xor eax, eax
mov dword [ebp - 0x28], edx
lea edi, [ebp - 0x24]
rep stosd dword es:[edi], eax
mov edi, dword [ebp - 0x30]
lea eax, [ebp - 0x48]
push eax
push 0x24
lea eax, [ebp - 0x28]
push eax
push edx
push edi
mov dword [ebp - 0x48], edx
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatusEx]
test eax, eax
je 0x40cacf
mov eax, dword [ebp - 0x34]
push 0x3c
xor edx, edx
pop ecx
div ecx
mov eax, edx
mov dword [ebp - 0x2c], eax
test eax, eax
jne 0x40ca19
push esi
call fcn.0041d26c
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x28]
push eax
push esi
push 0x402de0
push 2
call fcn.0040d0f9
call fcn.0041099f
test dword [ebp - 0x24], 1
jne 0x40ca30
test dword [ebp - 0x20], 1
jne 0x40ca30
push 0xa
pop ebx
jmp 0x40ca5c
push esi
test ebx, ebx
je 0x40cab0
dec ebx
call fcn.0041d26c
mov eax, ebx
imul eax, eax, 0x3e8
mov dword [ebp - 0x44], eax
lea eax, [ebp - 0x44]
push eax
push esi
push 0x402f80
push 2
call fcn.0040d19d
call fcn.0041099f
cmp dword [ebp - 0x2c], 0
jne 0x40ca8a
cmp ebx, 0xa
jb 0x40ca8a
push esi
call fcn.0041d26c
lea eax, [ebp - 0x2c]
push eax
push esi
push 0x4030f8
push 2
mov dword [ebp - 0x2c], 0xea60
call fcn.0040d27f
call fcn.0041099f
inc dword [ebp - 0x34]
push 1
push 0x3e8
call dword [sym.imp.KERNEL32.dll_SleepEx]
mov ecx, dword [ebp - 0x38]
lea eax, [ebp - 0x40]
push eax
call fcn.0040ccda
test al, al
je 0x40c99b
jmp 0x40caf4
call fcn.0041d26c
lea eax, [ebp - 0x2c]
push eax
push esi
push 0x403040
push 2
mov dword [ebp - 0x2c], 0x2710
call fcn.0040d20e
jmp 0x40cb07
push esi
call fcn.0041d26c
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x2c], eax
lea eax, [ebp - 0x2c]
push eax
push esi
push 0x402cf8
push 2
call fcn.0040d088
jmp 0x40cb07
mov edi, dword [ebp - 0x30]
push esi
call fcn.0041d26c
push esi
push 0x402c40
push 2
call fcn.0040d01d
call fcn.0041099f
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop ebx
push dword [ebp - 0x4c]
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push esi
call fcn.0041d26c
push esi
push 0x403180
push 2
call fcn.0040d2f0
call fcn.0041099f
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.004122f2
leave
ret