Function at 0x100050d0
Capabilities:
Delete registry value
Delete service
Get system information on windows
Query service status
Stop service

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10181420
mov eax, dword fs:[0]
push eax
sub esp, 0x44
mov eax, dword [0x101fd178]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edx, dword [ebp + 8]
xor eax, eax
mov ecx, edx
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 7
mov word [ebp - 0x28], ax
lea esi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x10005115
sub ecx, esi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x28]
call fcn.10003a60
push 0xf003f
push 0
push 0
mov dword [ebp - 4], 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov esi, dword [sym.imp.ADVAPI32.dll_OpenServiceW]
test eax, eax
je 0x1000518c
cmp dword [ebp - 0x14], 8
lea ecx, [ebp - 0x28]
push 0xf01ff
cmovae ecx, dword [ebp - 0x28]
push ecx
push eax
call esi
mov esi, eax
test esi, esi
je 0x10005186
lea eax, [ebp - 0x44]
push eax
push esi
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
cmp dword [ebp - 0x40], 1
je 0x10005186
lea eax, [ebp - 0x44]
push eax
push 1
push esi
call dword [sym.imp.ADVAPI32.dll_ControlService]
mov esi, dword [sym.imp.ADVAPI32.dll_OpenServiceW]
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
test eax, eax
je 0x100051d6
cmp dword [ebp - 0x14], 8
lea ecx, [ebp - 0x28]
push 0xf01ff
cmovae ecx, dword [ebp - 0x28]
push ecx
push eax
call esi
mov esi, eax
test esi, esi
je 0x100051d6
lea eax, [ebp - 0x44]
push eax
push esi
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
push esi
call dword [sym.imp.ADVAPI32.dll_DeleteService]
test eax, eax
je 0x100051d6
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
lea eax, [ebp - 0x4c]
push eax
call dword [sym.imp.KERNEL32.dll_GetNativeSystemInfo]
mov ax, word [ebp - 0x4c]
cmp ax, 9
je 0x10005202
cmp ax, 6
je 0x10005202
lea eax, [ebp - 0x50]
push eax
push 0xf003f
push 0
push str.SOFTWAREMicrosoftWindows_NTCurrentVersionSvchost
jmp 0x10005212
lea eax, [ebp - 0x50]
push eax
push 0xf003f
push 0
push str.SOFTWAREWow6432NodeMicrosoftWindows_NTCurrentVersionSvchost
push reloc.WS2_32.dll_bind
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x10005299
lea eax, [ebp - 0x28]
push eax
lea ecx, [ebp - 0x40]
call fcn.10004550
push str.Group
lea ecx, [ebp - 0x40]
mov byte [ebp - 4], 1
call fcn.10003970
cmp dword [ebp - 0x2c], 8
lea eax, [ebp - 0x40]
cmovae eax, dword [ebp - 0x40]
push eax
push dword [ebp - 0x50]
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
push dword [ebp - 0x50]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov edx, dword [ebp - 0x2c]
cmp edx, 8
jb 0x10005292
mov ecx, dword [ebp - 0x40]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x10005288
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x100052ef
push edx
push ecx
call fcn.1006e63c
add esp, 8
mov esi, 1
jmp 0x1000529b
xor esi, esi
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x100052d1
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x100052c7
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x100052f4
push edx
push ecx
call fcn.1006e63c
add esp, 8
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.1006e62b
mov esp, ebp
pop ebp
ret 4
call fcn.1008a259
call fcn.1008a259
int3