Function at 0x4114f4
Capabilities:
Enumerate services

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
push ebx
push esi
push edi
xor eax, eax
mov ebx, ecx
push 5
push str.ServicesActive
mov esi, eax
mov dword [ebp - 0x14], ebx
push eax
mov dword [ebp - 0x10], eax
mov dword [ebp - 0xc], eax
mov dword [ebp - 4], eax
mov dword [ebp - 0x18], esi
mov dword [ebp - 0x24], eax
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov edi, eax
test edi, edi
je 0x4115da
lea eax, [ebx + 0x28]
mov dword [ebp - 0x28], 1
mov dword [ebp - 0x20], eax
xor ecx, ecx
lea eax, [ebp - 0xc]
push ecx
push eax
lea eax, [ebp - 4]
mov dword [ebp - 0xc], ecx
push eax
lea eax, [ebp - 0x10]
push eax
push ecx
push ecx
push 3
push 0x30
push ecx
push edi
call dword [sym.imp.ADVAPI32.dll_EnumServicesStatusExW]
mov esi, dword [ebp - 0x10]
mov ecx, esi
call fcn.00406f77
push 0
mov ebx, eax
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x10]
push eax
push esi
push ebx
push 3
push 0x30
push 0
push edi
call dword [sym.imp.ADVAPI32.dll_EnumServicesStatusExW]
test eax, eax
jne 0x411594
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xea
jne 0x4115d7
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
xor edi, edi
cmp dword [ebp - 4], edi
jbe 0x4115d7
mov esi, ebx
cmp dword [esi], 0
je 0x4115d7
push dword [esi]
lea ecx, [ebp - 8]
call fcn.0040460a
push dword [ebp - 0x20]
lea ecx, [ebp - 8]
call fcn.00404276
test eax, eax
jne 0x4115ed
mov ecx, dword [ebp - 8]
call fcn.00406f1d
and dword [ebp - 8], 0
add esi, 0x2c
inc edi
cmp edi, dword [ebp - 4]
jb 0x4115a4
mov esi, dword [ebp - 0x18]
and dword [ebp - 0x28], 0
mov ecx, esi
call fcn.00406f1d
mov eax, dword [ebp - 0x28]
pop edi
pop esi
pop ebx
leave
ret
imul esi, edi, 0x2c
lea ecx, [ebp - 0x1c]
push dword [esi + ebx]
call fcn.0040460a
push eax
lea ecx, [ebp - 0x18]
call fcn.004043c7
mov ecx, dword [ebp - 0x1c]
call fcn.00406f1d
mov eax, dword [esi + ebx + 0x24]
mov esi, dword [ebp - 0x14]
mov ecx, dword [ebp - 8]
and dword [ebp - 0x1c], 0
mov dword [esi + 0x2c], eax
call fcn.00406f1d
and dword [ebp - 8], 0
mov eax, dword [esi + 0x2c]
test eax, eax
jne 0x41166e
xor esi, esi
inc esi
cmp dword [ebp - 0x24], esi
je 0x4115d7
mov edi, dword [ebp - 0x20]
push 2
push edi
call fcn.00410df8
push edi
call fcn.00410e64
push ebx
mov dword [ebp - 0x24], esi
call fcn.00401014
pop ecx
push 5
push str.ServicesActive
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov edi, eax
test edi, edi
jne 0x41153a
jmp 0x4115d7
mov ecx, dword [ebp - 4]
xor edi, edi
mov esi, dword [ebp - 0x18]
mov dword [ebp - 0x24], edi
test ecx, ecx
je 0x4115de
cmp dword [ebx], 0
je 0x4115de
cmp dword [ebx + 0x24], eax
jne 0x4116d4
push dword [ebx]
lea ecx, [ebp - 8]
call fcn.0040460a
push esi
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_lstrcmpW]
test eax, eax
je 0x4116bf
mov edi, dword [ebp - 0x14]
push ecx
mov ecx, esp
push dword [ebx]
call fcn.0040460a
lea ecx, [edi + 0x44]
call fcn.00402a5c
mov edi, dword [ebp - 0x24]
mov ecx, dword [ebp - 8]
call fcn.00406f1d
mov eax, dword [ebp - 0x14]
and dword [ebp - 8], 0
mov ecx, dword [ebp - 4]
mov eax, dword [eax + 0x2c]
inc edi
add ebx, 0x2c
mov dword [ebp - 0x24], edi
cmp edi, ecx
jb 0x411681
jmp 0x4115de