Function at 0x5bf9a0
Capabilities:
Query or enumerate registry key
Query or enumerate registry value
Set registry value

Disassembly:
sub esp, 0x248
mov ecx, dword [esp + 0x250]
mov edx, dword [esp + 0x24c]
push ebp
lea eax, [esp + 4]
push eax
push 0x20019
xor ebp, ebp
push ebp
push ecx
push edx
mov dword [esp + 0x28], ebp
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x5bfc9a
mov ecx, dword [esp + 0x25c]
mov edx, dword [esp + 0x258]
push ebp
lea eax, [esp + 0x1c]
push eax
push ebp
push 0x2001f
push ebp
push ebp
push ebp
push ecx
push edx
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
jne 0x5bfc7a
mov eax, dword [esp + 0x18]
push eax
call fcn.005bf6c0
lea ecx, [esp + 0x3c]
push ecx
lea edx, [esp + 0x38]
push edx
lea eax, [esp + 0x14]
push eax
lea ecx, [esp + 0x28]
push ecx
lea edx, [esp + 0x38]
push edx
lea eax, [esp + 0x4c]
push eax
lea ecx, [esp + 0x38]
push ecx
lea edx, [esp + 0x4c]
push edx
mov edx, dword [esp + 0x24]
push ebp
lea eax, [esp + 0x50]
push eax
lea ecx, [esp + 0x6c]
push ecx
push edx
mov dword [esp + 0x5c], 0x208
call dword [sym.imp.ADVAPI32.dll_RegQueryInfoKeyW]
test eax, eax
jne 0x5bfc6f
cmp dword [esp + 0x28], ebp
push ebx
push esi
push edi
jbe 0x5bfbb8
mov eax, dword [esp + 0x28]
mov edi, dword [esp + 0x18]
mov ebx, dword [sym.imp.KERNEL32.dll_GlobalAlloc]
add eax, 0xa
mov dword [esp + 0x28], eax
add eax, eax
push eax
add edi, 0xa
push 2
mov dword [esp + 0x20], edi
call ebx
mov esi, dword [sym.imp.KERNEL32.dll_GlobalLock]
push eax
call esi
mov ecx, dword [esp + 0x18]
push ecx
push 2
mov edi, eax
call ebx
push eax
call esi
mov edx, dword [esp + 0x28]
mov ecx, dword [esp + 0x18]
mov ebx, dword [sym.imp.ADVAPI32.dll_RegEnumValueW]
mov esi, eax
lea eax, [edx + edx]
lea edx, [esp + 0x1c]
push edx
mov edx, dword [esp + 0x14]
push esi
mov dword [esp + 0x1c], eax
lea eax, [esp + 0x38]
push eax
push ebp
mov dword [esp + 0x2c], ecx
lea ecx, [esp + 0x24]
push ecx
push edi
push ebp
push edx
call ebx
cmp eax, 0x103
je 0x5bfb80
mov ecx, dword [esp + 0x30]
inc ebp
cmp ecx, 1
je 0x5bfaf6
cmp ecx, 2
je 0x5bfaf6
cmp ecx, 7
jne 0x5bfb24
test esi, esi
jne 0x5bfafe
xor eax, eax
jmp 0x5bfb0b
push esi
call fcn.005c43e2
mov ecx, dword [esp + 0x34]
add esp, 4
mov edx, dword [esp + 0x18]
lea eax, [eax + eax + 2]
cmp eax, edx
mov dword [esp + 0x1c], eax
ja 0x5bfb28
mov byte [eax + esi - 2], 0
mov ecx, dword [esp + 0x30]
mov eax, dword [esp + 0x1c]
push eax
mov eax, dword [esp + 0x28]
push esi
push ecx
push 0
push edi
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
jne 0x5bfb78
mov ecx, dword [esp + 0x28]
mov eax, dword [esp + 0x18]
lea edx, [ecx + ecx]
lea ecx, [esp + 0x1c]
push ecx
mov ecx, dword [esp + 0x14]
push esi
mov dword [esp + 0x1c], edx
lea edx, [esp + 0x38]
push edx
push 0
mov dword [esp + 0x2c], eax
lea eax, [esp + 0x24]
push eax
push edi
push ebp
push ecx
call ebx
cmp eax, 0x103
jne 0x5bfae2
jmp 0x5bfb80
mov dword [esp + 0x20], 1
mov ebx, dword [sym.imp.KERNEL32.dll_GlobalHandle]
push edi
call ebx
mov ebp, dword [sym.imp.KERNEL32.dll_GlobalUnlock]
push eax
call ebp
push edi
call ebx
mov edi, dword [sym.imp.KERNEL32.dll_GlobalFree]
push eax
call edi
push esi
call ebx
push eax
call ebp
push esi
call ebx
push eax
call edi
mov eax, dword [esp + 0x20]
test eax, eax
jne 0x5bfc6c
jmp 0x5bfbbe
mov ebx, dword [sym.imp.KERNEL32.dll_GlobalHandle]
mov eax, dword [esp + 0x3c]
test eax, eax
jbe 0x5bfc6c
mov eax, dword [esp + 0x2c]
add eax, 0xa
lea edx, [eax + eax]
push edx
push 2
xor edi, edi
mov dword [esp + 0x34], eax
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
push eax
call dword [sym.imp.KERNEL32.dll_GlobalLock]
mov edx, dword [esp + 0x10]
mov ebp, dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
push edi
push edi
push edi
push edi
lea ecx, [esp + 0x24]
push ecx
mov esi, eax
mov eax, dword [esp + 0x40]
push esi
push edi
push edx
mov dword [esp + 0x34], eax
call ebp
cmp eax, 0x103
je 0x5bfc58
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x10]
push esi
push eax
push esi
push ecx
inc edi
call fcn.005bf9a0
test eax, eax
je 0x5bfc50
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x2c]
push 0
push 0
push 0
push 0
lea eax, [esp + 0x24]
push eax
push esi
push edi
push ecx
mov dword [esp + 0x34], edx
call ebp
cmp eax, 0x103
jne 0x5bfc13
jmp 0x5bfc58
mov dword [esp + 0x20], 1
push esi
call ebx
push eax
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
push esi
call ebx
push eax
call dword [sym.imp.KERNEL32.dll_GlobalFree]
pop edi
pop esi
pop ebx
mov edx, dword [esp + 0x18]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [esp + 4]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [esp + 0x14]
xor eax, eax
test ecx, ecx
sete al
pop ebp
add esp, 0x248
ret 0x10
xor eax, eax
pop ebp
add esp, 0x248
ret 0x10