Function at 0x100497ec
Capabilities:
Enumerate services

Disassembly:
push 0x34
mov eax, 0x1009f9d0
call fcn.10094b6a
mov edi, dword [ebp + 8]
xor ebx, ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x20], ebx
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0x1c], ebx
call fcn.1006295d
push 4
push ebx
push ebx
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov dword [ebp - 0x30], eax
cmp eax, ebx
jne 0x1004983e
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, dword [ebp + 0xc]
push 0x1000c89c
push 5
mov ecx, eax
call fcn.1002a420
jmp 0x100499c8
mov edi, dword [sym.imp.ADVAPI32.dll_EnumServicesStatusExW]
push ebx
lea ecx, [ebp - 0x20]
push ecx
lea ecx, [ebp - 0x18]
push ecx
lea ecx, [ebp - 0x14]
push ecx
push dword [ebp - 0x14]
push ebx
push 1
push 0x30
push ebx
push eax
jmp 0x100498a6
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
mov dword [ebp - 0x1c], esi
cmp esi, 0xea
jne 0x100498ae
mov dword [ebp - 0x1c], ebx
cmp dword [ebp - 0x10], ebx
je 0x10049881
push dword [ebp - 0x10]
call fcn.100878b8
pop ecx
push dword [ebp - 0x14]
call fcn.100878a8
pop ecx
push ebx
lea ecx, [ebp - 0x20]
push ecx
lea ecx, [ebp - 0x18]
push ecx
lea ecx, [ebp - 0x14]
push ecx
push dword [ebp - 0x14]
mov dword [ebp - 0x10], eax
push eax
push 1
push 0x30
push ebx
push dword [ebp - 0x30]
call edi
test eax, eax
je 0x1004985d
jmp 0x100498c7
mov edi, dword [ebp + 0xc]
push 0x1000c8b8
push 5
mov ecx, esi
call fcn.1002a420
cmp esi, ebx
jne 0x100499ae
mov dword [ebp + 0xc], ebx
cmp dword [ebp - 0x18], ebx
jbe 0x100499ae
mov edi, dword [ebp - 0x10]
mov dword [ebp - 0x2c], edi
mov edx, dword [ebp + 8]
mov eax, dword [edx + 8]
mov ecx, dword [edi + 0x24]
xor esi, esi
mov dword [ebp - 0x34], ecx
cmp eax, ebx
jle 0x100498f9
mov edx, dword [edx]
cmp dword [edx], ecx
je 0x100498fc
inc esi
add edx, 4
cmp esi, eax
jl 0x100498ed
or esi, 0xffffffff
cmp esi, 0xffffffff
je 0x10049942
push dword [edi]
lea eax, [ebp - 0x24]
push eax
call fcn.1005f361
mov dword [ebp - 4], ebx
cmp esi, ebx
jl 0x100499d0
mov eax, dword [ebp + 8]
cmp esi, dword [eax + 8]
jge 0x100499d0
imul esi, esi, 0xc
add esi, dword [eax + 4]
lea ebx, [ebp - 0x24]
call fcn.100600d0
or dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x24]
add eax, 0xfffffff0
call fcn.10084b37
jmp 0x10049997
mov dword [ebp - 0x40], ebx
mov dword [ebp - 0x3c], ebx
mov dword [ebp - 0x38], ebx
mov dword [ebp - 4], 1
push dword [edi]
lea eax, [ebp - 0x28]
push eax
call fcn.1005f361
lea ebx, [ebp - 0x28]
lea esi, [ebp - 0x40]
mov byte [ebp - 4], 2
call fcn.100600d0
mov byte [ebp - 4], 1
mov eax, dword [ebp - 0x28]
add eax, 0xfffffff0
call fcn.10084b37
lea eax, [ebp - 0x34]
mov edi, esi
mov esi, dword [ebp + 8]
push eax
call fcn.100628e3
or dword [ebp - 4], 0xffffffff
mov esi, edi
call fcn.10072bbb
mov edi, dword [ebp - 0x2c]
inc dword [ebp + 0xc]
mov eax, dword [ebp + 0xc]
add edi, 0x2c
xor ebx, ebx
mov dword [ebp - 0x2c], edi
cmp eax, dword [ebp - 0x18]
jb 0x100498d9
cmp dword [ebp - 0x10], ebx
je 0x100499bc
push dword [ebp - 0x10]
call fcn.100878b8
pop ecx
push dword [ebp - 0x30]
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, dword [ebp - 0x1c]
call fcn.10094c56
ret 8
call fcn.10083247
int3