Function at 0x12bba
Capabilities:
Delete registry value
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x50
push ebx
xor ebx, ebx
cmp dword [ebp + 8], ebx
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0xc], ebx
jne 0x12bd8
or eax, 0xffffffff
jmp 0x12df3
push esi
mov esi, dword [sym.imp.ntoskrnl.exe_ExAllocatePool]
push edi
push 0x3e8
push 1
call esi
push dword [ebp + 8]
mov dword [ebp - 0x20], eax
lea eax, [ebp - 0x38]
push eax
call dword [sym.imp.ntoskrnl.exe_RtlInitUnicodeString]
lea eax, [ebp - 0x38]
mov dword [ebp - 0x48], eax
lea eax, [ebp - 0x50]
push eax
push 0xf003f
lea eax, [ebp - 4]
push eax
mov dword [ebp - 0x50], 0x18
mov dword [ebp - 0x4c], ebx
mov dword [ebp - 0x44], 0x40
mov dword [ebp - 0x40], ebx
mov dword [ebp - 0x3c], ebx
call dword [sym.imp.ntoskrnl.exe_ZwOpenKey]
test eax, eax
jl 0x12dcf
lea eax, [ebp + 8]
push eax
push ebx
push ebx
push 2
push dword [ebp - 4]
call dword [sym.imp.ntoskrnl.exe_ZwQueryKey]
push dword [ebp + 8]
push 1
call esi
mov edi, eax
lea eax, [ebp + 8]
push eax
push dword [ebp + 8]
mov dword [ebp - 0x28], edi
push edi
push 2
push dword [ebp - 4]
call dword [sym.imp.ntoskrnl.exe_ZwQueryKey]
mov eax, dword [edi + 0x24]
add eax, 0x10
push eax
push 1
mov dword [ebp - 0x2c], eax
call esi
mov dword [ebp - 0x18], eax
mov eax, dword [edi + 0x28]
add eax, 0x10
push eax
push 1
mov dword [ebp - 0x30], eax
call esi
cmp dword [edi + 0x20], ebx
mov dword [ebp - 0x1c], eax
mov dword [ebp - 8], ebx
jbe 0x12d76
mov edi, 0x208
lea eax, [ebp + 8]
push eax
push dword [ebp - 0x2c]
push dword [ebp - 0x18]
push ebx
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.ntoskrnl.exe_ZwEnumerateValueKey]
lea eax, [ebp + 8]
push eax
push dword [ebp - 0x30]
push dword [ebp - 0x1c]
push 2
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.ntoskrnl.exe_ZwEnumerateValueKey]
push edi
push 1
call esi
push 0x104
push ebx
push eax
mov dword [ebp - 0x10], eax
call sub.ntoskrnl.exe_memset
add esp, 0xc
push edi
push 1
call esi
push 0x104
push ebx
push dword [ebp - 0x10]
mov dword [ebp - 0x14], eax
call sub.ntoskrnl.exe_memset
mov eax, dword [ebp - 0x18]
mov ecx, dword [eax + 8]
shr ecx, 1
push ecx
add eax, 0xc
push eax
push dword [ebp - 0x10]
call dword [sym.imp.ntoskrnl.exe_wcsncpy]
mov eax, dword [ebp - 0x1c]
mov ecx, dword [eax + 8]
shr ecx, 1
push ecx
add eax, 0xc
push eax
push dword [ebp - 0x14]
call dword [sym.imp.ntoskrnl.exe_wcsncpy]
add esp, 0x24
push dword [ebp - 0x14]
call fcn.00014e30
test eax, eax
jne 0x12d4e
push edi
push 1
call esi
mov edx, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x20]
mov dword [ecx + edx*4], eax
mov edx, dword [ebp - 0x10]
movzx ecx, word [edx]
inc edx
mov word [eax], cx
inc edx
inc eax
inc eax
cmp cx, bx
jne 0x12d3c
inc dword [ebp - 0xc]
push ebx
push dword [ebp - 0x10]
call dword [sym.imp.ntoskrnl.exe_ExFreePoolWithTag]
push ebx
push dword [ebp - 0x14]
call dword [sym.imp.ntoskrnl.exe_ExFreePoolWithTag]
inc dword [ebp - 8]
mov eax, dword [ebp - 0x28]
mov ecx, dword [ebp - 8]
cmp ecx, dword [eax + 0x20]
jb 0x12c94
mov edi, eax
mov esi, dword [sym.imp.ntoskrnl.exe_ExFreePoolWithTag]
push ebx
push dword [ebp - 0x18]
call esi
push ebx
push dword [ebp - 0x1c]
call esi
push ebx
push edi
call esi
cmp dword [ebp - 0xc], ebx
mov dword [ebp - 0x10], ebx
jle 0x12dd5
mov eax, dword [ebp - 0x20]
mov ecx, dword [ebp - 0x10]
lea edi, [eax + ecx*4]
push dword [edi]
lea eax, [ebp - 0x38]
push eax
call dword [sym.imp.ntoskrnl.exe_RtlInitUnicodeString]
lea eax, [ebp - 0x38]
push eax
push dword [ebp - 4]
call dword [sym.imp.ntoskrnl.exe_ZwDeleteValueKey]
test eax, eax
jl 0x12dbd
inc dword [ebp - 0x24]
push ebx
push dword [edi]
call esi
inc dword [ebp - 0x10]
mov eax, dword [ebp - 0x10]
cmp eax, dword [ebp - 0xc]
jl 0x12d94
jmp 0x12dd5
mov esi, dword [sym.imp.ntoskrnl.exe_ExFreePoolWithTag]
push ebx
push dword [ebp - 0x20]
call esi
call dword [sym.imp.ntoskrnl.exe_ExGetPreviousMode]
test al, al
pop edi
pop esi
jne 0x12df0
push dword [ebp - 4]
call dword [sym.imp.ntoskrnl.exe_ZwClose]
mov eax, dword [ebp - 0x24]
pop ebx
leave
ret 4