Function at 0x40d2b0
Capabilities:
Enumerate services

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x56e950
mov eax, dword fs:[0]
push eax
sub esp, 0x60
mov eax, dword [0x5d2fec]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x4c], esi
push 0x5b03d4
push 0x3ee
push dword [0x5dd61c]
call dword [sym.imp.USER32.dll_GetDlgItem]
push eax
call dword [sym.imp.USER32.dll_SetWindowTextW]
push 0xf003f
push 0
push 0
mov dword [ebp - 0x44], 0
mov dword [ebp - 0x14], 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov ebx, eax
test ebx, ebx
je 0x40d6be
push 0
test esi, esi
mov eax, 0x30
mov esi, dword [sym.imp.ADVAPI32.dll_EnumServicesStatusW]
mov edi, 0xb
cmove edi, eax
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x44]
push eax
push 0
push 0
push 3
push edi
push ebx
call esi
push dword [ebp - 0x44]
call fcn.004179bf
add esp, 4
mov dword [ebp - 0x58], eax
lea ecx, [ebp - 0x14]
push 0
push ecx
lea ecx, [ebp - 0x44]
push ecx
push dword [ebp - 0x44]
push eax
push 3
push edi
push ebx
call esi
cmp dword [ebp - 0x14], 0
mov dword [ebp - 0x54], 0
jbe 0x40d6b3
mov ebx, dword [ebp - 0x58]
mov dword [ebp - 0x50], ebx
lea ecx, [ebp - 0x40]
call fcn.0040c890
mov dword [ebp - 4], 0
mov edx, dword [ebx]
test edx, edx
jne 0x40d39f
xor ecx, ecx
jmp 0x40d3b3
mov ecx, edx
lea esi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40d3a4
sub ecx, esi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x40]
call fcn.00406bd0
mov edi, dword [ebp - 0x4c]
lea eax, [ebp - 0x40]
push ecx
mov ecx, esp
lea esi, [ebp - 0x24]
push eax
mov dword [ebp - 0x48], ecx
call fcn.004069a0
mov edx, esi
test edi, edi
je 0x40d454
lea ecx, [ebp - 0x5c]
call fcn.00401fd0
add esp, 4
mov byte [ebp - 4], 1
mov ecx, dword [eax]
mov esi, dword [ebp - 0x3c]
add esi, 0xfffffff0
lea edx, [ecx - 0x10]
cmp edx, esi
je 0x40d44b
cmp dword [esi + 0xc], 0
lea edi, [esi + 0xc]
jl 0x40d43c
mov eax, dword [edx]
cmp eax, dword [esi]
jne 0x40d43c
push edx
call fcn.00406c80
add esp, 4
mov ebx, eax
or ecx, 0xffffffff
lock xadd dword [edi], ecx
dec ecx
test ecx, ecx
jg 0x40d424
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov edi, dword [ebp - 0x4c]
lea eax, [ebx + 0x10]
mov ebx, dword [ebp - 0x50]
mov byte [ebp - 4], 0
mov edx, dword [ebp - 0x5c]
mov dword [ebp - 0x3c], eax
jmp 0x40d4c1
push dword [ecx - 0xc]
push ecx
lea ecx, [ebp - 0x3c]
call fcn.00406bd0
mov edi, dword [ebp - 0x4c]
mov byte [ebp - 4], 0
mov edx, dword [ebp - 0x5c]
jmp 0x40d4c1
lea ecx, [ebp - 0x60]
call fcn.004021c0
add esp, 4
mov byte [ebp - 4], 2
mov ecx, dword [eax]
mov esi, dword [ebp - 0x3c]
add esi, 0xfffffff0
lea edx, [ecx - 0x10]
cmp edx, esi
je 0x40d4ba
cmp dword [esi + 0xc], 0
lea edi, [esi + 0xc]
jl 0x40d4ab
mov eax, dword [edx]
cmp eax, dword [esi]
jne 0x40d4ab
push edx
call fcn.00406c80
add esp, 4
mov ebx, eax
or ecx, 0xffffffff
lock xadd dword [edi], ecx
dec ecx
test ecx, ecx
jg 0x40d4a0
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
lea eax, [ebx + 0x10]
mov ebx, dword [ebp - 0x50]
mov dword [ebp - 0x3c], eax
jmp 0x40d4b7
push dword [ecx - 0xc]
push ecx
lea ecx, [ebp - 0x3c]
call fcn.00406bd0
mov edi, dword [ebp - 0x4c]
mov byte [ebp - 4], 0
mov edx, dword [ebp - 0x60]
or eax, 0xffffffff
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x40d4d9
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [ebp - 0x3c]
mov ecx, 0x5af8f0
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x40d507
test dx, dx
je 0x40d503
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x40d507
add eax, 4
add ecx, 4
test dx, dx
jne 0x40d4e1
xor eax, eax
jmp 0x40d50c
sbb eax, eax
or eax, 1
test eax, eax
sete al
test al, al
jne 0x40d684
push ecx
lea eax, [ebp - 0x3c]
mov ecx, esp
push eax
mov dword [ebp - 0x48], ecx
call fcn.004069a0
test edi, edi
je 0x40d54d
lea ecx, [ebp - 0x64]
call fcn.00402f60
add esp, 4
push eax
lea ecx, [ebp - 0x3c]
mov byte [ebp - 4], 3
call fcn.00406cf0
mov byte [ebp - 4], 0
mov edx, dword [ebp - 0x64]
jmp 0x40d56c
lea ecx, [ebp - 0x68]
call fcn.00402d60
add esp, 4
push eax
lea ecx, [ebp - 0x3c]
mov byte [ebp - 4], 4
call fcn.00406cf0
mov byte [ebp - 4], 0
mov edx, dword [ebp - 0x68]
or eax, 0xffffffff
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x40d584
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
lea ecx, [ebp - 0x40]
call fcn.004136a0
push 2
push 0x5afa74
lea ecx, [ebp - 0x2c]
call fcn.00406bd0
test edi, edi
je 0x40d5ae
push 2
push 0x5afa7c
lea ecx, [ebp - 0x2c]
call fcn.00406bd0
mov edx, dword [ebx + 4]
test edx, edx
jne 0x40d5b9
xor ecx, ecx
jmp 0x40d5cf
mov ecx, edx
lea esi, [ecx + 2]
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40d5c0
sub ecx, esi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x1c]
call fcn.00406bd0
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0x6c]
push str.HKEY_LOCAL_MACHINESYSTEMCurrentControlSet_services_
push eax
call fcn.00406490
add esp, 0xc
mov byte [ebp - 4], 5
mov ecx, dword [eax]
mov esi, dword [ebp - 0x20]
add esi, 0xfffffff0
lea edx, [ecx - 0x10]
cmp edx, esi
je 0x40d646
cmp dword [esi + 0xc], 0
lea edi, [esi + 0xc]
jl 0x40d63a
mov eax, dword [edx]
cmp eax, dword [esi]
jne 0x40d63a
push edx
call fcn.00406c80
add esp, 4
mov ebx, eax
or ecx, 0xffffffff
lock xadd dword [edi], ecx
dec ecx
test ecx, ecx
jg 0x40d62f
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
lea eax, [ebx + 0x10]
mov ebx, dword [ebp - 0x50]
mov dword [ebp - 0x20], eax
jmp 0x40d646
push dword [ecx - 0xc]
push ecx
lea ecx, [ebp - 0x20]
call fcn.00406bd0
mov byte [ebp - 4], 0
or eax, 0xffffffff
mov edx, dword [ebp - 0x6c]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x40d665
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
sub esp, 0x2c
lea eax, [ebp - 0x40]
mov ecx, esp
push eax
call fcn.0040d1a0
call fcn.0040f000
add esp, 0x2c
cmp dword [0x5dd608], 0
jne 0x40d6ab
lea ecx, [ebp - 0x40]
mov dword [ebp - 4], 0xffffffff
call fcn.0040ca30
mov esi, dword [ebp - 0x54]
add ebx, 0x24
inc esi
mov dword [ebp - 0x50], ebx
mov dword [ebp - 0x54], esi
cmp esi, dword [ebp - 0x14]
jb 0x40d386
jmp 0x40d6b3
lea ecx, [ebp - 0x40]
call fcn.0040ca30
push dword [ebp - 0x58]
call fcn.004179c8
add esp, 4
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0054e73a
mov esp, ebp
pop ebp
ret