Function at 0x1002e85
Capabilities:
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
xor ebx, ebx
push ebx
push ebx
push ebx
lea eax, [ebp - 0x10]
push eax
push ebx
push ebx
lea eax, [ebp - 0x14]
push eax
push ebx
push ebx
push ebx
push ebx
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryInfoKeyW]
cmp eax, ebx
jne 0x10030eb
inc dword [ebp - 0x10]
push edi
push 2
push dword [ebp - 0x10]
call dword [sym.imp.msvcrt.dll_calloc]
mov edi, eax
cmp edi, ebx
pop ecx
pop ecx
jne 0x1002ed1
push 8
pop eax
jmp 0x10030ea
mov dword [ebp - 0xc], ebx
push esi
mov eax, dword [ebp - 0x10]
push ebx
push ebx
push ebx
push ebx
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x18]
push eax
push edi
push dword [ebp - 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegEnumValueW]
mov esi, eax
cmp esi, ebx
jne 0x1002f08
push dword [ebp + 0x18]
push edi
push dword [ebp + 0x10]
push edi
push dword [ebp + 8]
call fcn.01002cb6
mov esi, eax
inc dword [ebp - 0xc]
cmp esi, ebx
je 0x1002ed5
push edi
call dword [sym.imp.msvcrt.dll_free]
cmp esi, 0x103
pop ecx
jne 0x1002f21
xor esi, esi
cmp dword [ebp + 0x1c], ebx
je 0x10030e7
cmp esi, ebx
jne 0x10030e7
inc dword [ebp - 0x14]
push 2
push dword [ebp - 0x14]
call dword [sym.imp.msvcrt.dll_calloc]
cmp eax, ebx
pop ecx
pop ecx
mov dword [ebp - 8], eax
jne 0x1002f51
push 8
pop eax
jmp 0x10030e9
mov esi, dword [sym.imp.msvcrt.dll_wcslen]
mov edi, dword [sym.imp.msvcrt.dll_wcscat]
mov dword [ebp - 0xc], ebx
mov eax, dword [ebp - 0x14]
push ebx
push ebx
push ebx
push ebx
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x18]
push eax
push dword [ebp - 8]
push dword [ebp - 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
cmp eax, ebx
mov dword [ebp - 4], eax
jne 0x10030ab
lea eax, [ebp - 0x20]
push eax
push 0x20019
push ebx
push dword [ebp - 8]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
cmp eax, ebx
mov dword [ebp - 4], eax
jne 0x10030ab
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0x24]
push eax
push ebx
push 0xf003f
push ebx
push ebx
push ebx
push dword [ebp - 8]
push dword [ebp + 0x10]
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
cmp eax, ebx
mov dword [ebp - 4], eax
jne 0x10030ab
push 2
push dword [ebp - 8]
call esi
push dword [ebp + 0xc]
mov ebx, eax
call esi
pop ecx
pop ecx
lea eax, [ebx + eax + 3]
push eax
call dword [sym.imp.msvcrt.dll_calloc]
mov ebx, eax
test ebx, ebx
pop ecx
pop ecx
mov dword [ebp - 0x1c], ebx
je 0x10030c3
push dword [ebp + 0xc]
call esi
test eax, eax
pop ecx
jbe 0x100301a
push dword [ebp + 0xc]
push ebx
call dword [sym.imp.msvcrt.dll_wcscpy]
push 0x100125c
push ebx
call edi
add esp, 0x10
push dword [ebp - 8]
push ebx
call edi
pop ecx
pop ecx
push 2
push dword [ebp - 8]
call esi
push dword [ebp + 0x14]
mov ebx, eax
call esi
pop ecx
pop ecx
lea eax, [ebx + eax + 3]
push eax
call dword [sym.imp.msvcrt.dll_calloc]
mov ebx, eax
test ebx, ebx
pop ecx
pop ecx
mov dword [ebp - 0x28], ebx
je 0x10030b9
push dword [ebp + 0x14]
call esi
test eax, eax
pop ecx
jbe 0x1003067
push dword [ebp + 0x14]
push ebx
call dword [sym.imp.msvcrt.dll_wcscpy]
push 0x100125c
push ebx
call edi
add esp, 0x10
push dword [ebp - 8]
push ebx
call edi
pop ecx
pop ecx
push dword [ebp + 0x1c]
push dword [ebp + 0x18]
push ebx
push dword [ebp - 0x24]
push dword [ebp - 0x1c]
push dword [ebp - 0x20]
call fcn.01002e85
push dword [ebp - 0x20]
mov ebx, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [ebp - 4], eax
call ebx
push dword [ebp - 0x24]
call ebx
push dword [ebp - 0x1c]
mov ebx, dword [sym.imp.msvcrt.dll_free]
call ebx
push dword [ebp - 0x28]
call ebx
pop ecx
pop ecx
xor ebx, ebx
inc dword [ebp - 0xc]
cmp dword [ebp - 4], ebx
je 0x1002f60
jmp 0x10030cc
push dword [ebp - 0x1c]
call dword [sym.imp.msvcrt.dll_free]
pop ecx
mov dword [ebp - 4], 8
xor ebx, ebx
push dword [ebp - 8]
call dword [sym.imp.msvcrt.dll_free]
cmp dword [ebp - 4], 0x103
pop ecx
jne 0x10030e2
mov dword [ebp - 4], ebx
mov eax, dword [ebp - 4]
jmp 0x10030e9
mov eax, esi
pop esi
pop edi
pop ebx
leave
ret 0x18