Function at 0x1004dcb
Capabilities:
Query or enumerate registry key

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x40
push ebx
push esi
push edi
push dword [ebp + 0x18]
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.01004b1a
xor ebx, ebx
cmp dword [ebp + 0x1c], ebx
je 0x10051e8
cmp eax, ebx
jne 0x10051e8
push ebx
push ebx
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryInfoKeyW]
push ebx
push ebx
push ebx
push ebx
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 8]
push eax
push ebx
push ebx
push ebx
push dword [ebp + 8]
call esi
cmp eax, ebx
jne 0x10051e8
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0xc]
push eax
push ebx
push ebx
push ebx
push dword [ebp + 0x10]
call esi
cmp eax, ebx
mov dword [ebp - 4], eax
jne 0x10051e8
mov eax, dword [ebp - 8]
inc dword [ebp - 0x14]
imul eax, dword [ebp - 0x14]
mov edi, dword [sym.imp.msvcrt.dll_calloc]
push 2
push eax
call edi
cmp eax, ebx
pop ecx
pop ecx
mov dword [ebp - 0x20], eax
jne 0x1004e6c
mov dword [ebp - 4], 8
jmp 0x10051b8
push 4
push dword [ebp - 8]
call edi
cmp eax, ebx
pop ecx
pop ecx
mov dword [ebp - 0x10], eax
je 0x1004f07
xor esi, esi
cmp dword [ebp - 8], ebx
jbe 0x1004edd
cmp dword [ebp - 4], ebx
jne 0x1004ec7
mov edx, dword [ebp - 0x20]
mov eax, dword [ebp - 0x10]
mov ecx, esi
imul ecx, dword [ebp - 0x14]
push ebx
push ebx
lea ecx, [edx + ecx*2]
lea eax, [eax + esi*4]
mov dword [eax], ecx
mov ecx, dword [ebp - 0x14]
push ebx
push ebx
mov dword [ebp - 0x28], ecx
lea ecx, [ebp - 0x28]
push ecx
push dword [eax]
push esi
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
inc esi
cmp esi, dword [ebp - 8]
mov dword [ebp - 4], eax
jb 0x1004e87
cmp eax, ebx
je 0x1004edd
push dword [ebp - 0x20]
mov esi, dword [sym.imp.msvcrt.dll_free]
call esi
push dword [ebp - 0x10]
call esi
pop ecx
jmp 0x10051e4
mov eax, dword [ebp - 0xc]
inc dword [ebp - 0x18]
imul eax, dword [ebp - 0x18]
push 2
push eax
call edi
cmp eax, ebx
pop ecx
pop ecx
mov dword [ebp - 0x24], eax
je 0x1004f07
push 4
push dword [ebp - 0xc]
call edi
mov edi, eax
cmp edi, ebx
pop ecx
pop ecx
mov dword [ebp - 0x1c], edi
jne 0x1004f13
mov dword [ebp - 4], 8
jmp 0x10051ae
xor esi, esi
cmp dword [ebp - 0xc], ebx
jbe 0x1004f76
cmp dword [ebp - 4], ebx
jne 0x1004f56
mov ecx, dword [ebp - 0x24]
mov eax, esi
imul eax, dword [ebp - 0x18]
push ebx
push ebx
lea eax, [ecx + eax*2]
mov dword [edi + esi*4], eax
mov eax, dword [ebp - 0x18]
push ebx
push ebx
mov dword [ebp - 0x28], eax
lea eax, [ebp - 0x28]
push eax
push dword [edi + esi*4]
push esi
push dword [ebp + 0x10]
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
inc esi
cmp esi, dword [ebp - 0xc]
mov dword [ebp - 4], eax
jb 0x1004f1a
cmp eax, ebx
je 0x1004f76
push dword [ebp - 0x20]
mov esi, dword [sym.imp.msvcrt.dll_free]
call esi
push dword [ebp - 0x10]
call esi
push dword [ebp - 0x24]
call esi
push edi
call esi
add esp, 0x10
jmp 0x10051e5
cmp dword [ebp - 8], ebx
mov dword [ebp - 0x30], ebx
jbe 0x1005130
mov esi, dword [ebp - 0x10]
mov edi, dword [sym.imp.msvcrt.dll_wcscat]
cmp dword [ebp - 4], ebx
jne 0x1005130
cmp dword [esi], ebx
je 0x100511e
xor eax, eax
cmp dword [ebp - 0xc], ebx
mov dword [ebp - 0x2c], eax
jbe 0x100511e
mov ecx, dword [ebp - 0x1c]
mov eax, dword [ecx + eax*4]
cmp eax, ebx
je 0x1004fc3
push eax
push dword [esi]
call dword [sym.imp.msvcrt.dll__wcsicmp]
test eax, eax
pop ecx
pop ecx
je 0x1004fd4
mov eax, dword [ebp - 0x2c]
inc eax
cmp eax, dword [ebp - 0xc]
mov dword [ebp - 0x2c], eax
jb 0x1004faa
jmp 0x100511e
cmp dword [ebp + 0x18], 2
je 0x1004fe0
cmp dword [ebp + 0x18], 3
jne 0x1004ff9
push ebx
push dword [esi]
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.010044dc
cmp eax, ebx
mov dword [ebp - 4], eax
jne 0x100511e
lea eax, [ebp - 0x34]
push eax
push 0x20019
push ebx
push dword [esi]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
cmp eax, ebx
mov dword [ebp - 4], eax
jne 0x100511e
lea eax, [ebp - 0x38]
push eax
push 0x20019
push ebx
push dword [esi]
push dword [ebp + 0x10]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
cmp eax, ebx
mov dword [ebp - 4], eax
jne 0x100511e
mov ebx, dword [sym.imp.msvcrt.dll_wcslen]
push 2
push dword [ebp + 0xc]
call ebx
push dword [esi]
mov dword [ebp - 0x3c], eax
call ebx
pop ecx
pop ecx
mov ecx, dword [ebp - 0x3c]
lea eax, [ecx + eax + 2]
push eax
call dword [sym.imp.msvcrt.dll_calloc]
mov ebx, eax
test ebx, ebx
pop ecx
pop ecx
mov dword [ebp - 0x3c], ebx
je 0x10051f9
push dword [ebp + 0xc]
push ebx
call dword [sym.imp.msvcrt.dll_wcscpy]
push 0x100125c
push ebx
call edi
push dword [esi]
push ebx
call edi
mov ebx, dword [sym.imp.msvcrt.dll_wcslen]
add esp, 0x18
push 2
push dword [ebp + 0x14]
call ebx
push dword [esi]
mov dword [ebp - 4], eax
call ebx
pop ecx
pop ecx
mov ecx, dword [ebp - 4]
lea eax, [ecx + eax + 2]
push eax
call dword [sym.imp.msvcrt.dll_calloc]
mov ebx, eax
test ebx, ebx
pop ecx
pop ecx
mov dword [ebp - 0x40], ebx
je 0x10051ef
push dword [ebp + 0x14]
push ebx
call dword [sym.imp.msvcrt.dll_wcscpy]
push 0x100125c
push ebx
call edi
push dword [esi]
push ebx
call edi
add esp, 0x18
push dword [ebp + 0x1c]
push dword [ebp + 0x18]
push dword [ebp + 0x14]
push dword [ebp - 0x38]
push dword [ebp + 0xc]
push dword [ebp - 0x34]
call fcn.01004dcb
push dword [ebp - 0x3c]
mov ebx, dword [sym.imp.msvcrt.dll_free]
mov dword [ebp - 4], eax
call ebx
push dword [ebp - 0x40]
call ebx
mov ebx, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop ecx
pop ecx
push dword [ebp - 0x34]
call ebx
push dword [ebp - 0x38]
call ebx
and dword [esi], 0
mov eax, dword [ebp - 0x2c]
mov ecx, dword [ebp - 0x1c]
and dword [ecx + eax*4], 0
xor ebx, ebx
inc dword [ebp - 0x30]
mov eax, dword [ebp - 0x30]
add esi, 4
cmp eax, dword [ebp - 8]
jb 0x1004f8b
xor edi, edi
xor esi, esi
inc edi
cmp dword [ebp - 8], ebx
jbe 0x1005170
cmp dword [ebp - 4], ebx
jne 0x1005170
mov eax, dword [ebp - 0x10]
mov eax, dword [eax + esi*4]
cmp eax, ebx
je 0x100516a
cmp dword [ebp + 0x18], edi
je 0x1005154
cmp dword [ebp + 0x18], 3
jne 0x1005164
push edi
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.010044dc
mov dword [ebp - 4], eax
mov dword [0x1008040], edi
inc esi
cmp esi, dword [ebp - 8]
jb 0x100513a
xor esi, esi
cmp dword [ebp - 0xc], ebx
jbe 0x10051ae
cmp dword [ebp - 4], ebx
jne 0x10051ae
mov eax, dword [ebp - 0x1c]
mov eax, dword [eax + esi*4]
cmp eax, ebx
je 0x10051a8
cmp dword [ebp + 0x18], edi
je 0x1005191
cmp dword [ebp + 0x18], 3
jne 0x10051a2
push 2
push eax
push dword [ebp + 0x14]
push dword [ebp + 0x10]
call fcn.010044dc
mov dword [ebp - 4], eax
mov dword [0x1008040], edi
inc esi
cmp esi, dword [ebp - 0xc]
jb 0x1005177
push dword [ebp - 0x20]
call dword [sym.imp.msvcrt.dll_free]
pop ecx
cmp dword [ebp - 0x10], ebx
je 0x10051c7
push dword [ebp - 0x10]
call dword [sym.imp.msvcrt.dll_free]
pop ecx
cmp dword [ebp - 0x24], ebx
je 0x10051d6
push dword [ebp - 0x24]
call dword [sym.imp.msvcrt.dll_free]
pop ecx
cmp dword [ebp - 0x1c], ebx
je 0x10051e5
push dword [ebp - 0x1c]
call dword [sym.imp.msvcrt.dll_free]
pop ecx
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
leave
ret 0x18
push dword [ebp - 0x3c]
call dword [sym.imp.msvcrt.dll_free]
pop ecx
mov dword [ebp - 4], 8
xor ebx, ebx
jmp 0x10051ae