Function at 0x104d881
Capabilities:
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
push esi
push edi
xor edi, edi
mov dword [ebp - 4], edi
mov dword [ebp - 8], edi
mov dword [ebp - 0xc], 0x80004005
cmp dword [ebp + 8], edi
je 0x104da79
cmp dword [ebp + 0x10], edi
je 0x104da79
mov esi, dword [ebp + 0xc]
inc esi
xor ecx, ecx
push 2
pop edx
mov eax, esi
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call sub.msvcrt.dll_void____cdecl_operator_new___unsigned_int_
mov ebx, eax
pop ecx
mov dword [ebp - 0x10], ebx
cmp ebx, edi
je 0x104da79
push dword [ebp + 8]
push esi
push ebx
call fcn.01035811
mov esi, dword [sym.imp.msvcrt.dll_wcschr]
push 0x2c
push ebx
call esi
mov ebx, eax
pop ecx
pop ecx
cmp ebx, edi
je 0x104da6b
xor eax, eax
mov word [ebx], ax
inc ebx
push 0x20
pop eax
inc ebx
cmp ax, word [ebx]
je 0x104d8f6
push 0x2c
push ebx
call esi
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x104d96a
xor eax, eax
mov word [edi], ax
inc edi
push 0x20
pop eax
inc edi
cmp ax, word [edi]
je 0x104d912
push 0x2c
push edi
call esi
pop ecx
pop ecx
mov dword [ebp - 4], eax
test eax, eax
je 0x104d953
xor ecx, ecx
mov word [eax], cx
inc eax
push 0x20
inc eax
pop ecx
mov dword [ebp - 4], eax
cmp cx, word [eax]
jne 0x104d953
xor ecx, ecx
mov word [eax], cx
inc eax
push 0x20
inc eax
pop ecx
cmp cx, word [eax]
je 0x104d941
mov dword [ebp - 4], eax
mov eax, edi
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
test cx, cx
jne 0x104d958
sub eax, edx
sar eax, 1
jne 0x104d96a
xor edi, edi
push 0x80000001
push dword [ebp - 0x10]
call fcn.01057a69
lea ecx, [ebp - 8]
push ecx
xor esi, esi
inc esi
push esi
push 0
push ebx
push eax
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x104da6b
xor ecx, ecx
push 2
pop edx
mov eax, 0x104
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call sub.msvcrt.dll_void____cdecl_operator_new___unsigned_int_
mov ebx, eax
pop ecx
mov dword [ebp + 0xc], 0x208
test ebx, ebx
je 0x104da62
lea eax, [ebp + 0xc]
push eax
push ebx
lea eax, [ebp + 8]
push eax
push 0
push edi
push dword [ebp - 8]
mov dword [ebp + 8], esi
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
call esi
test eax, eax
jne 0x104da57
cmp dword [ebp + 8], 1
je 0x104da32
cmp dword [ebp + 8], 2
je 0x104da32
push 4
pop eax
cmp dword [ebp + 8], eax
jne 0x104da57
and dword [ebp - 4], 0
mov dword [ebp + 0xc], eax
lea eax, [ebp + 0xc]
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp + 8]
push eax
push 0
push edi
push dword [ebp - 8]
call esi
test eax, eax
jne 0x104da57
push dword [ebp - 4]
push 0x1007cc0
push 0x104
push ebx
call fcn.0103590d
add esp, 0x10
test eax, eax
jl 0x104da57
mov eax, dword [ebp + 0x10]
and dword [ebp - 0xc], 0
mov dword [eax], ebx
jmp 0x104da62
and dword [ebp - 0xc], 0
cmp dword [ebp - 4], 0
je 0x104da50
push ebx
call fcn.01055e3d
push dword [ebp - 4]
push 0x104
push ebx
call fcn.01035886
mov eax, dword [ebp + 0x10]
mov dword [eax], ebx
xor ebx, ebx
test ebx, ebx
je 0x104da62
push ebx
call sub.msvcrt.dll_void___cdecl_operator_delete___void__
pop ecx
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push dword [ebp - 0x10]
call sub.msvcrt.dll_void___cdecl_operator_delete___void__
mov eax, dword [ebp - 0xc]
pop ecx
jmp 0x104da7e
mov eax, 0x8007000e
pop edi
pop esi
pop ebx
leave
ret 0xc