Function at 0x1049e90
Capabilities:
Enumerate services

Disassembly:
push 0x54
mov eax, 0x105f30e
call fcn.0104dc9c
mov dword [ebp - 0x54], ecx
xor edi, edi
push 0x80000000
push 0x101531c
push edi
mov dword [ebp - 0x14], edi
mov dword [ebp - 0x24], edi
mov dword [ebp - 0x18], edi
mov dword [ebp - 0x30], edi
mov dword [ebp - 0x38], edi
mov dword [ebp - 0x2c], edi
mov dword [ebp - 0x1c], edi
mov dword [ebp - 4], edi
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov dword [ebp - 0x34], eax
cmp eax, edi
je 0x104a34a
cmp eax, 0xffffffff
je 0x104a34a
mov esi, dword [sym.imp.ADVAPI32.dll_EnumServicesStatusW]
lea ecx, [ebp - 0x38]
push ecx
lea ecx, [ebp - 0x30]
push ecx
lea ecx, [ebp - 0x18]
push ecx
push edi
push edi
push 3
push 0xb
push eax
call esi
cmp eax, edi
jne 0x1049f44
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebx
cmp eax, 0xea
je 0x1049f44
call ebx
cmp eax, edi
jle 0x1049f1c
and eax, 0xffff
or eax, 0x80070000
cmp eax, edi
mov dword [ebp - 0x14], eax
jl 0x1049f2a
mov dword [ebp - 0x14], 0x80004005
push 0x10152e4
push 0x10152c4
call ebx
push eax
call fcn.01048d15
add esp, 0xc
jmp 0x104a0d5
push dword [ebp - 0x18]
call sub.msvcrt.dll_void____cdecl_operator_new___unsigned_int_
pop ecx
mov dword [ebp - 0x2c], eax
cmp eax, edi
jne 0x1049f78
push 0x101529c
mov eax, 0x8007000e
push 0x101527c
push eax
mov dword [ebp - 0x14], eax
call fcn.01048c52
add esp, 0xc
or dword [ebp - 4], 0xffffffff
jmp 0x104a0c6
lea ecx, [ebp - 0x38]
push ecx
lea ecx, [ebp - 0x30]
push ecx
lea ecx, [ebp - 0x18]
push ecx
push dword [ebp - 0x18]
push eax
push 3
push 0xb
push dword [ebp - 0x34]
call esi
cmp eax, edi
jne 0x1049fcd
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
cmp eax, edi
jle 0x1049fab
and eax, 0xffff
or eax, 0x80070000
cmp eax, edi
mov dword [ebp - 0x14], eax
jl 0x1049fb9
mov dword [ebp - 0x14], 0x80004005
push 0x10152e4
push 0x101525c
call esi
push eax
call fcn.01048d15
jmp 0x1049f6c
mov dword [ebp - 0x28], edi
mov eax, dword [ebp - 0x28]
cmp eax, dword [ebp - 0x30]
jae 0x104a0b3
mov esi, eax
imul esi, esi, 0x24
add esi, dword [ebp - 0x2c]
lea ecx, [ebp - 0x60]
call fcn.010498eb
mov byte [ebp - 4], 1
cmp dword [ebp - 0x24], edi
je 0x1049ffe
push dword [ebp - 0x24]
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push 0x80000000
push dword [esi]
push dword [ebp - 0x34]
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov dword [ebp - 0x24], eax
cmp eax, edi
jne 0x104a03a
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [esi]
push 0x1002428
push 0x1015234
push 0x4000000
call fcn.01048e9b
add esp, 0x14
jmp 0x104a33a
mov ebx, dword [sym.imp.ADVAPI32.dll_QueryServiceConfigW]
lea eax, [ebp - 0x18]
push eax
push edi
push edi
push dword [ebp - 0x24]
call ebx
cmp eax, edi
jne 0x104a06f
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
je 0x104a06f
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [esi]
push 0x1002428
push 0x1015208
jmp 0x104a028
cmp dword [ebp - 0x1c], edi
je 0x104a080
push dword [ebp - 0x1c]
call sub.msvcrt.dll_void___cdecl_operator_delete___void__
pop ecx
mov dword [ebp - 0x1c], edi
push dword [ebp - 0x18]
call sub.msvcrt.dll_void____cdecl_operator_new___unsigned_int_
pop ecx
mov dword [ebp - 0x1c], eax
cmp eax, edi
jne 0x104a0e7
push 0x10151e8
mov eax, 0x8007000e
push 0x10151c8
push eax
mov dword [ebp - 0x14], eax
call fcn.01048c52
add esp, 0xc
lea ecx, [ebp - 0x60]
call fcn.0103cbee
or dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x1c], 0
je 0x104a0c6
push dword [ebp - 0x1c]
call sub.msvcrt.dll_void___cdecl_operator_delete___void__
pop ecx
cmp dword [ebp - 0x2c], 0
je 0x104a0d5
push dword [ebp - 0x2c]
call sub.msvcrt.dll_void___cdecl_operator_delete___void__
pop ecx
push dword [ebp - 0x34]
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, dword [ebp - 0x14]
call fcn.0104dd50
ret
lea eax, [ebp - 0x18]
push eax
push dword [ebp - 0x18]
push dword [ebp - 0x1c]
push dword [ebp - 0x24]
call ebx
cmp eax, edi
jne 0x104a112
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [esi]
push 0x1002428
push 0x101518c
jmp 0x104a028
push dword [esi]
lea ecx, [ebp - 0x60]
call fcn.01030b1b
mov eax, dword [ebp - 0x1c]
push dword [eax + 0xc]
lea ecx, [ebp - 0x5c]
call fcn.01030b1b
mov eax, dword [ebp - 0x5c]
cmp dword [eax - 0xc], edi
je 0x104a33a
mov dword [ebp - 0x3c], edi
push 4
lea eax, [ebp - 0x40]
push eax
lea ecx, [ebp - 0x5c]
mov byte [ebp - 4], 2
call fcn.010340a7
push 0x1015180
mov ecx, eax
mov byte [ebp - 4], 3
call fcn.01035dcf
mov ecx, dword [ebp - 0x40]
cmp eax, edi
sete bl
add ecx, 0xfffffff0
mov byte [ebp - 4], 2
call fcn.0102fb3e
test bl, bl
je 0x104a19d
push 4
lea eax, [ebp - 0x44]
push eax
lea ecx, [ebp - 0x5c]
call fcn.010386c7
push eax
lea ecx, [ebp - 0x5c]
mov byte [ebp - 4], 4
call fcn.01030ac4
mov ecx, dword [ebp - 0x44]
add ecx, 0xfffffff0
mov byte [ebp - 4], 2
call fcn.0102fb3e
push 0xc
lea eax, [ebp - 0x48]
push eax
lea ecx, [ebp - 0x5c]
call fcn.010340a7
mov eax, dword [eax]
push 0x1015164
push eax
call dword [sym.imp.msvcrt.dll__wcsicmp]
pop ecx
mov ebx, eax
pop ecx
mov ecx, dword [ebp - 0x48]
neg ebx
sbb bl, bl
add ecx, 0xfffffff0
inc bl
call fcn.0102fb3e
test bl, bl
je 0x104a26f
push 0x1066af4
lea ecx, [ebp - 0x20]
call fcn.010442ec
push 0x101514c
lea ecx, [ebp - 0x20]
mov byte [ebp - 4], 5
call fcn.01049abb
cmp eax, edi
jne 0x104a209
mov ecx, dword [ebp - 0x20]
add ecx, 0xfffffff0
call fcn.0102fb3e
push edi
jmp 0x104a330
push 0x5c
lea ecx, [ebp - 0x20]
call fcn.01030b8e
push 0x5c
lea ecx, [ebp - 0x20]
call fcn.01030944
push 0xc
lea eax, [ebp - 0x50]
push eax
lea ecx, [ebp - 0x5c]
call fcn.010386c7
push eax
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x4c]
push eax
mov byte [ebp - 4], 6
call fcn.01049b4d
push eax
lea ecx, [ebp - 0x5c]
mov byte [ebp - 4], 7
call fcn.01030ac4
mov ecx, dword [ebp - 0x4c]
add ecx, 0xfffffff0
call fcn.0102fb3e
mov ecx, dword [ebp - 0x50]
add ecx, 0xfffffff0
call fcn.0102fb3e
mov ecx, dword [ebp - 0x20]
add ecx, 0xfffffff0
mov byte [ebp - 4], 2
call fcn.0102fb3e
push edi
push edi
push edi
push edi
push dword [ebp - 0x5c]
push edi
call dword [sym.imp.KERNEL32.dll_SearchPathW]
cmp eax, edi
jne 0x104a2a7
push dword [ebp - 0x60]
call dword [sym.imp.SHLWAPI.dll_PathFindFileNameW]
push eax
push 0x1002428
push 0x101511c
push 0x4000000
call fcn.01048e9b
add esp, 0x10
jmp 0x104a203
lea esi, [eax + 1]
push esi
lea ecx, [ebp - 0x3c]
call fcn.01033530
mov ebx, dword [ebp - 0x3c]
cmp ebx, edi
jne 0x104a2e5
push 0x1010880
mov eax, 0x8007000e
push 0x10150fc
push eax
mov dword [ebp - 0x14], eax
call fcn.01048c52
add esp, 0xc
push edi
mov byte [ebp - 4], 1
call sub.msvcrt.dll_void___cdecl_operator_delete___void__
pop ecx
jmp 0x104a0ab
push edi
push ebx
push esi
push edi
push dword [ebp - 0x5c]
push edi
call dword [sym.imp.KERNEL32.dll_SearchPathW]
cmp eax, edi
jne 0x104a31a
push dword [ebp - 0x60]
call dword [sym.imp.SHLWAPI.dll_PathFindFileNameW]
push eax
push 0x1002428
push 0x101511c
push 0x4000000
call fcn.01048e9b
add esp, 0x10
jmp 0x104a32f
push ebx
lea ecx, [ebp - 0x5c]
call fcn.01030b1b
mov ecx, dword [ebp - 0x54]
lea eax, [ebp - 0x60]
push eax
call fcn.01049e07
push ebx
mov byte [ebp - 4], 1
call sub.msvcrt.dll_void___cdecl_operator_delete___void__
pop ecx
lea ecx, [ebp - 0x60]
call fcn.0103cbee
inc dword [ebp - 0x28]
jmp 0x1049fd0
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
cmp eax, edi
jle 0x104a360
and eax, 0xffff
or eax, 0x80070000
cmp eax, edi
mov dword [ebp - 0x14], eax
jl 0x104a36e
mov dword [ebp - 0x14], 0x80004005
push 0x10150d8
push 0x10150b8
call esi
jmp 0x1049f36