Function at 0x4e6e7c
Capabilities:
Enumerate services
Query service configuration

Disassembly:
push ebp
mov ebp, esp
push eax
mov eax, 0x24
add esp, 0xfffff004
push eax
dec eax
jne 0x4e6e85
mov eax, dword [ebp - 4]
add esp, 0xffffff8c
push ebx
push esi
push edi
xor eax, eax
mov dword [ebp - 0x24078], eax
mov dword [ebp - 0x24074], eax
mov dword [ebp - 4], eax
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], eax
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x14], eax
xor eax, eax
push ebp
push 0x4e729d
push dword fs:[eax]
mov dword fs:[eax], esp
xor eax, eax
mov dword [ebp - 0x20], eax
push 0xf003f
push 0x4e72ac
push 0
call sub.advapi32.dll_OpenSCManagerA
mov dword [ebp - 0x24], eax
cmp dword [ebp - 0x24], 0
jae 0x4e6efd
mov eax, dword [0x4ef268]
mov eax, dword [eax]
mov ecx, 0x4e72c4
mov edx, 0x4e72fc
call fcn.004d7798
jmp 0x4e7272
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x18]
push eax
push 0x24
lea eax, [ebp - 0x24070]
push eax
push 3
push 0x30
mov eax, dword [ebp - 0x24]
push eax
call sub.advapi32.dll_EnumServicesStatusA
mov ebx, eax
cmp ebx, 1
sbb eax, eax
inc eax
test al, al
jne 0x4e7269
call sub.kernel32.dll_GetLastError
cmp eax, 0xea
jne 0x4e7269
mov eax, dword [ebp - 0x18]
add eax, 0x24
lea edx, [ebp - 0x20]
push edx
lea edx, [ebp - 0x1c]
push edx
lea edx, [ebp - 0x18]
push edx
push eax
lea eax, [ebp - 0x2404c]
push eax
push 3
push 0x30
mov eax, dword [ebp - 0x24]
push eax
call sub.advapi32.dll_EnumServicesStatusA
mov eax, dword [0x4ef268]
mov eax, dword [eax]
mov ecx, 0x4e7314
mov edx, 0x4e72fc
call fcn.004d7798
mov eax, dword [ebp - 0x1c]
dec eax
test eax, eax
jb 0x4e7269
inc eax
mov dword [ebp - 0x28], eax
lea ebx, [ebp - 0x2404c]
push 1
mov eax, dword [ebx]
push eax
mov eax, dword [ebp - 0x24]
push eax
call sub.advapi32.dll_OpenServiceA
mov edi, eax
test edi, edi
je 0x4e725d
lea eax, [ebp - 0x18]
push eax
push 0
push 0
push edi
call sub.advapi32.dll_QueryServiceConfigA
mov eax, dword [ebp - 0x18]
call fcn.00402f4c
mov esi, eax
lea eax, [ebp - 0x18]
push eax
mov eax, dword [ebp - 0x18]
push eax
push esi
push edi
call sub.advapi32.dll_QueryServiceConfigA
mov eax, dword [esi + 4]
cmp eax, 4
ja case.default.0x4e6fd9
jmp dword [eax*4 + 0x4e6fe0]
lea eax, [ebp - 4]
mov edx, 0x4e7324
call fcn.00404cd8
jmp 0x4e704c
lea eax, [ebp - 4]
mov edx, 0x4e7334
call fcn.00404cd8
jmp 0x4e704c
lea eax, [ebp - 4]
mov edx, 0x4e7344
call fcn.00404cd8
jmp 0x4e704c
lea eax, [ebp - 4]
mov edx, 0x4e7354
call fcn.00404cd8
jmp 0x4e704c
lea eax, [ebp - 4]
mov edx, 0x4e7364
call fcn.00404cd8
jmp 0x4e704c
lea eax, [ebp - 4]
mov edx, 0x4e7374
call fcn.00404cd8
lea eax, [ebp - 0xc]
mov edx, dword [esi + 0xc]
call fcn.00404e38
lea eax, [ebp - 0x14]
mov edx, dword [esi + 0x1c]
call fcn.00404e38
mov eax, dword [ebp - 0x14]
mov edx, 0x4e7384
call fcn.00405068
jne 0x4e7080
lea eax, [ebp - 0x14]
mov edx, 0x4e73a8
call fcn.00404cd8
jmp 0x4e70ba
mov eax, dword [ebp - 0x14]
mov edx, 0x4e73bc
call fcn.00405068
jne 0x4e709e
lea eax, [ebp - 0x14]
mov edx, 0x4e73d0
call fcn.00404cd8
jmp 0x4e70ba
mov eax, dword [ebp - 0x14]
mov edx, 0x4e73e4
call fcn.00405068
jne 0x4e70ba
lea eax, [ebp - 0x14]
mov edx, 0x4e7408
call fcn.00404cd8
mov eax, esi
call fcn.00402f68
push edi
call sub.advapi32.dll_CloseServiceHandle
mov eax, dword [ebx + 0xc]
cmp eax, 7
ja case.0x4e70d3.0
jmp dword [eax*4 + 0x4e70da]
lea eax, [ebp - 8]
mov edx, 0x4e741c
call fcn.00404cd8
jmp 0x4e7170
lea eax, [ebp - 8]
mov edx, 0x4e742c
call fcn.00404cd8
jmp 0x4e7170
lea eax, [ebp - 8]
mov edx, 0x4e742c
call fcn.00404cd8
jmp 0x4e7170
lea eax, [ebp - 8]
mov edx, 0x4e743c
call fcn.00404cd8
jmp 0x4e7170
lea eax, [ebp - 8]
mov edx, 0x4e744c
call fcn.00404cd8
jmp 0x4e7170
lea eax, [ebp - 8]
mov edx, 0x4e745c
call fcn.00404cd8
jmp 0x4e7170
lea eax, [ebp - 8]
mov edx, 0x4e746c
call fcn.00404cd8
jmp 0x4e7170
lea eax, [ebp - 8]
mov edx, 0x4e747c
call fcn.00404cd8
mov eax, dword [0x4ef5e0]
mov eax, dword [eax]
mov edx, 0x4e7490
call fcn.00405068
jne 0x4e718d
lea eax, [ebp - 0x10]
call fcn.00404c40
jmp 0x4e71a8
lea eax, [ebp - 0x24074]
mov edx, dword [ebx]
call fcn.00404e38
mov eax, dword [ebp - 0x24074]
lea edx, [ebp - 0x10]
call fcn.004e6d70
mov eax, dword [0x4ef268]
mov eax, dword [eax]
mov ecx, 0x4e74a0
mov edx, 0x4e72fc
call fcn.004d7798
lea eax, [ebp - 0x24078]
mov edx, dword [ebx + 4]
call fcn.00404e38
mov ecx, dword [ebp - 0x24078]
mov eax, dword [0x4ef268]
mov eax, dword [eax]
mov edx, 0x4e72fc
call fcn.004d7798
mov eax, dword [0x4ef268]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x10]
mov edx, 0x4e72fc
call fcn.004d7798
mov eax, dword [0x4ef268]
mov eax, dword [eax]
mov ecx, dword [ebp - 8]
mov edx, 0x4e72fc
call fcn.004d7798
mov eax, dword [0x4ef268]
mov eax, dword [eax]
mov ecx, dword [ebp - 4]
mov edx, 0x4e72fc
call fcn.004d7798
mov eax, dword [0x4ef268]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x14]
mov edx, 0x4e72fc
call fcn.004d7798
mov eax, dword [0x4ef268]
mov eax, dword [eax]
mov ecx, dword [ebp - 0xc]
mov edx, 0x4e72fc
call fcn.004d7798
mov eax, dword [0x4ef268]
mov eax, dword [eax]
mov ecx, 0x4e74b0
mov edx, 0x4e72fc
call fcn.004d7798
add ebx, 0x24
dec dword [ebp - 0x28]
jne 0x4e6f92
mov eax, dword [ebp - 0x24]
push eax
call sub.advapi32.dll_CloseServiceHandle
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4e72a4
lea eax, [ebp - 0x24078]
mov edx, 2
call fcn.00404c64
lea eax, [ebp - 0x14]
mov edx, 5
call fcn.00404c64
ret