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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x290
push ebx
push esi
mov esi, dword [sym.imp.ntoskrnl.exe_RtlInitUnicodeString]
push edi
push str.RegistryMachineSOFTWAREMicrosoftWindows_NTCurrentVersionProfileList_
lea eax, [ebp - 0x28]
push eax
call esi
push str.RegistryUser_
lea ecx, [ebp - 0x38]
push ecx
call esi
mov eax, dword [ebp + 8]
mov esi, dword [sym.imp.ntoskrnl.exe_RtlCopyUnicodeString]
lea edx, [ebp - 0x38]
push edx
lea ecx, [ebp - 0x28c]
push eax
mov dword [ebp - 0x18], 0x2000000
mov dword [ebp - 0x14], ecx
call esi
lea ecx, [ebp - 0x28]
push ecx
lea edx, [ebp - 0x18]
push edx
call esi
xor edi, edi
push 0x38
lea eax, [ebp - 0x88]
push edi
push eax
mov dword [ebp - 0x2c], edi
call sub.ntoskrnl.exe_memset
lea ecx, [ebp - 0x30]
add esp, 0xc
mov dword [ebp - 0x7c], ecx
lea ecx, [ebp - 0x50]
mov eax, 4
lea edx, [ebp - 0x2c]
push ecx
mov dword [ebp - 0x74], edx
mov dword [ebp - 0x78], eax
mov dword [ebp - 0x70], eax
push 0xf003f
lea edx, [ebp - 0x10]
lea eax, [ebp - 0x28]
push edx
mov dword [ebp - 0x84], 0x20
mov dword [ebp - 0x80], str.RefCount
mov dword [ebp - 0x50], 0x18
mov dword [ebp - 0x4c], edi
mov dword [ebp - 0x44], 0x40
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x40], edi
mov dword [ebp - 0x3c], edi
call dword [sym.imp.ntoskrnl.exe_ZwOpenKey]
cmp eax, edi
jl 0x4014b1
mov ecx, dword [ebp - 0x10]
mov esi, dword [sym.imp.ntoskrnl.exe_ZwQueryKey]
lea eax, [ebp - 0xc]
push eax
push edi
push edi
push 2
push ecx
call esi
mov edx, dword [ebp - 0xc]
push edx
push 1
call dword [sym.imp.ntoskrnl.exe_ExAllocatePool]
mov ebx, eax
cmp ebx, edi
jne 0x4013ad
mov eax, 0xc000009a
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebp - 0x10]
lea eax, [ebp - 0xc]
push eax
push ecx
push ebx
push 2
push edx
call esi
mov byte [ebp - 5], 0
cmp dword [ebx + 0x14], edi
jbe 0x401490
mov ecx, dword [ebp - 0x10]
lea eax, [ebp - 0xc]
push eax
push 0
push 0
push 0
push edi
push ecx
call dword [sym.imp.ntoskrnl.exe_ZwEnumerateKey]
mov edx, dword [ebp - 0xc]
push edx
push 1
call dword [sym.imp.ntoskrnl.exe_ExAllocatePool]
mov esi, eax
test esi, esi
je 0x40139f
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebp - 0x10]
lea eax, [ebp - 0xc]
push eax
push ecx
push esi
push 0
push edi
push edx
call dword [sym.imp.ntoskrnl.exe_ZwEnumerateKey]
mov ax, word [esi + 0xc]
lea ecx, [esi + 0x10]
mov word [ebp - 0x1e], ax
mov word [ebp - 0x20], ax
mov dword [ebp - 0x1c], ecx
cmp ax, 0x14
jbe 0x40145d
mov eax, dword [ebp + 8]
lea edx, [ebp - 0x20]
push edx
push eax
call dword [sym.imp.ntoskrnl.exe_RtlAppendUnicodeStringToString]
lea ecx, [ebp - 0x20]
push ecx
lea edx, [ebp - 0x18]
push edx
call dword [sym.imp.ntoskrnl.exe_RtlAppendUnicodeStringToString]
mov ecx, dword [ebp - 0x14]
push 0
push 0
lea eax, [ebp - 0x88]
push eax
push ecx
push 0
call dword [sym.imp.ntoskrnl.exe_RtlQueryRegistryValues]
cmp dword [ebp - 0x30], 0
jbe 0x40145d
mov byte [ebp - 5], 1
push 0
push esi
call dword [sym.imp.ntoskrnl.exe_ExFreePoolWithTag]
cmp byte [ebp - 5], 0
jne 0x401490
mov eax, dword [ebp + 8]
mov esi, dword [sym.imp.ntoskrnl.exe_RtlCopyUnicodeString]
lea edx, [ebp - 0x38]
push edx
push eax
call esi
lea ecx, [ebp - 0x28]
push ecx
lea edx, [ebp - 0x18]
push edx
call esi
inc edi
cmp edi, dword [ebx + 0x14]
jb 0x4013cb
push 0
push ebx
call dword [sym.imp.ntoskrnl.exe_ExFreePoolWithTag]
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.ntoskrnl.exe_ZwClose]
xor eax, eax
cmp byte [ebp - 5], al
setne al
dec eax
and eax, 0xc0000225
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4