Function at 0x104b7cb
Capabilities:
Delete registry key
Query or enumerate registry value

Disassembly:
push 0x18
mov eax, 0x10593ae
call fcn.01021eb9
xor ebx, ebx
mov dword [ebp - 4], ebx
lea ecx, [ebp - 0x18]
mov dword [ebp - 0x10], ebx
call fcn.010151da
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x14]
call fcn.010151da
mov byte [ebp - 4], 2
mov edi, dword [ebp + 0x10]
cmp edi, ebx
je 0x104b9c6
cmp dword [ebp + 0x14], ebx
je 0x104b9c6
mov esi, SysReAllocString
push esi
push ebx
push ebx
mov dword [edi], ebx
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov dword [ebp - 0x24], eax
cmp eax, ebx
jne 0x104b829
xor esi, esi
jmp 0x104b980
push esi
lea ecx, [ebp + 8]
call fcn.01015002
push eax
push dword [ebp - 0x24]
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov dword [ebp - 0x20], eax
cmp eax, ebx
jne 0x104b960
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x424
jne 0x104b95c
mov eax, dword [ebp + 0xc]
push 0x1012368
lea ecx, [ebp + 0xc]
mov dword [eax], 1
call fcn.010161a7
mov byte [ebp - 4], 3
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp + 8]
push eax
lea eax, [ebp + 0xc]
push eax
call fcn.010360f6
mov byte [ebp - 4], 2
lea ecx, [ebp + 0xc]
call fcn.01015174
push dword [0x10646a4]
lea ecx, [ebp - 0x1c]
call fcn.010161a7
mov byte [ebp - 4], 4
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x18]
push eax
call fcn.010360f6
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x1c]
call fcn.01015174
lea eax, [ebp - 0x10]
push eax
push 0x2001f
push ebx
lea ecx, [ebp - 0x14]
call fcn.01015002
push eax
mov esi, reloc.OLEAUT32.dll_SysReAllocString
push esi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x104b95c
push dword [ebp + 0x14]
mov edi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push ebx
push ebx
push ebx
push dword [0x10646a8]
push dword [ebp - 0x10]
call edi
test eax, eax
jne 0x104b95c
mov eax, dword [ebp + 0x14]
push dword [eax]
call fcn.01054617
pop ecx
mov ecx, dword [ebp + 0x10]
mov dword [ecx], eax
cmp eax, ebx
je 0x104b95c
push dword [ebp + 0x14]
push eax
push ebx
push ebx
push dword [0x10646a8]
push dword [ebp - 0x10]
call edi
test eax, eax
jne 0x104b95c
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [ebp - 0x14]
mov dword [ebp - 0x10], ebx
call fcn.01015002
mov edi, dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
push eax
push esi
call edi
test eax, eax
jne 0x104b95c
lea ecx, [ebp - 0x18]
call fcn.01015002
push eax
push esi
call edi
mov esi, eax
neg esi
sbb esi, esi
inc esi
jmp 0x104b968
xor esi, esi
jmp 0x104b968
mov eax, dword [ebp + 0xc]
xor esi, esi
inc esi
mov dword [eax], ebx
mov edi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
cmp dword [ebp - 0x20], ebx
je 0x104b978
push dword [ebp - 0x20]
call edi
push dword [ebp - 0x24]
call edi
mov edi, dword [ebp + 0x10]
cmp dword [ebp - 0x10], ebx
je 0x104b98e
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp esi, ebx
jne 0x104b99f
mov edi, dword [edi]
cmp edi, ebx
je 0x104b99f
push edi
call fcn.01021179
pop ecx
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x14]
call fcn.01015174
mov byte [ebp - 4], bl
lea ecx, [ebp - 0x18]
call fcn.01015174
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.01015174
mov eax, esi
jmp 0x104b9eb
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x14]
call fcn.01015174
mov byte [ebp - 4], bl
lea ecx, [ebp - 0x18]
call fcn.01015174
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.01015174
xor eax, eax
call fcn.01021fa5
ret 0x10