Function at 0x410e60
Capabilities:
Enumerate services
Query service configuration

Disassembly:
sub esp, 0x494
push ebp
push esi
push edi
xor ebp, ebp
push 4
push ebp
mov esi, ecx
push ebp
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov edi, eax
cmp edi, ebp
mov dword [esp + 0x24], edi
jne 0x410e8d
pop edi
pop esi
xor eax, eax
pop ebp
add esp, 0x494
ret
push ebx
mov bl, byte [esi + 0x11]
neg bl
lea eax, [esp + 0x24]
lea ecx, [esp + 0x1c]
sbb ebx, ebx
push eax
lea edx, [esp + 0x1c]
push ecx
and ebx, 0xb
push edx
lea eax, [esp + 0x8c]
push 0x24
add ebx, 0x30
push eax
push 3
push ebx
push edi
mov dword [esp + 0x44], ebp
call dword [sym.imp.ADVAPI32.dll_EnumServicesStatusA]
test eax, eax
jne 0x41123b
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xea
jne 0x41123b
mov ecx, dword [esp + 0x18]
lea esi, [ecx + 0x24]
lea edx, [esi + esi*8]
shl edx, 2
push edx
call sub.MFC42.DLL_operatornew
add esp, 4
mov ebp, eax
lea eax, [esp + 0x24]
lea ecx, [esp + 0x1c]
push eax
lea edx, [esp + 0x1c]
push ecx
push edx
push esi
push ebp
push 3
push ebx
push edi
call dword [sym.imp.ADVAPI32.dll_EnumServicesStatusA]
push 0x400
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov byte [eax], 0x81
mov ecx, dword [esp + 0x1c]
test ecx, ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], 1
mov dword [esp + 0x20], 0
jbe 0x41122b
mov ebx, dword [sym.imp.KERNEL32.dll_lstrlenA]
mov eax, dword [ebp]
push 1
push eax
push edi
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
lea ecx, [esp + 0x18]
lea edx, [esp + 0xa4]
push ecx
push 0x400
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_QueryServiceConfigA]
test eax, eax
je case.default.0x410f89
mov ecx, 7
xor eax, eax
lea edi, [esp + 0x2c]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov eax, dword [esp + 0xa8]
cmp eax, 4
ja case.default.0x410f89
jmp dword [eax*4 + 0x411250]
lea edx, [esp + 0x2c]
mov edi, str.BOOT_START
jmp 0x410fc5
lea edx, [esp + 0x2c]
mov edi, str.SYSTEM_START
jmp 0x410fc5
lea edx, [esp + 0x2c]
mov edi, str.AUTO_START
jmp 0x410fc5
lea edx, [esp + 0x2c]
mov edi, str.DEMAND_START
jmp 0x410fc5
lea edx, [esp + 0x2c]
mov edi, str.DISABLED
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, 0xc
xor eax, eax
lea edi, [esp + 0x4c]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov eax, dword [ebp + 0xc]
dec eax
cmp eax, 6
ja case.default.0x410ffa
jmp dword [eax*4 + 0x411264]
lea edx, [esp + 0x4c]
mov edi, str.STOPPED
jmp 0x411041
lea edx, [esp + 0x4c]
mov edi, str.START_PENDING
jmp 0x411041
lea edx, [esp + 0x4c]
mov edi, str.STOP_PENDING
jmp 0x411041
lea edx, [esp + 0x4c]
mov edi, str.RUNNING
jmp 0x411041
lea edx, [esp + 0x4c]
mov edi, str.CONTINUE_PENDING
jmp 0x411041
lea edx, [esp + 0x4c]
mov edi, str.PAUSE_PENDING
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0xb0]
push ecx
call ebx
mov edx, dword [ebp]
mov esi, eax
push edx
call ebx
add esi, eax
mov eax, dword [esp + 0xbc]
push eax
call ebx
lea ecx, [esp + 0x4c]
add esi, eax
push ecx
call ebx
lea edx, [esp + 0x2c]
add esi, eax
push edx
call ebx
add esi, eax
mov eax, dword [ebp + 4]
push eax
call ebx
mov edi, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
lea esi, [esi + eax + 6]
push edi
add esi, ecx
call dword [0x419dc4]
cmp eax, esi
jae 0x4110bd
push 0x42
push esi
push edi
call dword [sym.imp.KERNEL32.dll_LocalReAlloc]
mov dword [esp + 0x14], eax
mov edx, dword [ebp]
push edx
call ebx
mov edx, dword [esp + 0x10]
mov esi, dword [ebp]
mov ecx, eax
mov eax, dword [esp + 0x14]
lea edi, [eax + edx]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp]
push ecx
call ebx
mov edx, dword [esp + 0x10]
lea edi, [edx + eax + 1]
mov eax, dword [ebp + 4]
push eax
mov dword [esp + 0x14], edi
call ebx
mov edx, dword [esp + 0x14]
mov esi, dword [ebp + 4]
mov ecx, eax
add edi, edx
inc ecx
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp + 4]
push ecx
call ebx
mov edx, dword [esp + 0x10]
lea edi, [edx + eax + 1]
mov eax, dword [esp + 0xb0]
push eax
mov dword [esp + 0x14], edi
call ebx
mov edx, dword [esp + 0x14]
mov esi, dword [esp + 0xb0]
mov ecx, eax
add edi, edx
inc ecx
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0xb0]
push ecx
call ebx
mov edx, dword [esp + 0x10]
lea edi, [edx + eax + 1]
lea eax, [esp + 0x2c]
push eax
mov dword [esp + 0x14], edi
call ebx
mov edx, dword [esp + 0x14]
mov ecx, eax
inc ecx
lea esi, [esp + 0x2c]
mov eax, ecx
add edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x2c]
push ecx
call ebx
mov edx, dword [esp + 0x10]
lea edi, [edx + eax + 1]
lea eax, [esp + 0x4c]
mov dword [esp + 0x10], edi
push eax
call ebx
mov edx, dword [esp + 0x14]
mov ecx, eax
inc ecx
lea esi, [esp + 0x4c]
mov eax, ecx
add edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x4c]
push ecx
call ebx
mov edx, dword [esp + 0x10]
lea edi, [edx + eax + 1]
mov eax, dword [esp + 0xbc]
push eax
mov dword [esp + 0x14], edi
call ebx
mov edx, dword [esp + 0x14]
mov esi, dword [esp + 0xbc]
mov ecx, eax
add edi, edx
inc ecx
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0xbc]
push ecx
call ebx
mov edx, dword [esp + 0x10]
mov ecx, dword [esp + 0x1c]
mov edi, dword [esp + 0x28]
add ebp, 0x24
lea eax, [edx + eax + 1]
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x20]
inc eax
cmp eax, ecx
mov dword [esp + 0x20], eax
jb 0x410f44
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
push 0x42
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_LocalReAlloc]
mov ebp, eax
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop ebx
pop edi
mov eax, ebp
pop esi
pop ebp
add esp, 0x494
ret