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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x6cc
mov eax, dword [0x294d0]
xor eax, ebp
mov dword [ebp - 4], eax
cmp dword [ebp + 8], 1
mov eax, dword [ebp + 0xc]
push ebx
push esi
mov esi, dword [ebp + 0x10]
mov dword [ebp - 0x648], eax
mov eax, dword [ebp + 0x14]
push edi
mov dword [ebp - 0x64c], esi
mov dword [ebp - 0x650], eax
jne 0x13352
xor eax, eax
xor ebx, ebx
mov dword [ebp - 0x670], ebx
lea edi, [ebp - 0x66c]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
xor eax, eax
push 0x3fe
mov word [ebp - 0x604], ax
lea eax, [ebp - 0x602]
push ebx
push eax
mov dword [ebp - 0x608], ebx
call sub.ntoskrnl.exe_memset
xor eax, eax
lea edi, [ebp - 0x61a]
stosd dword es:[edi], eax
stosw word es:[edi], ax
add esp, 0xc
lea eax, [ebp - 0x604]
mov dword [ebp - 0x618], eax
mov eax, 0x39c
mov word [ebp - 0x61a], ax
xor eax, eax
push 0x24
mov word [ebp - 0x61c], ax
pop eax
push 0x26
mov word [ebp - 0x63c], ax
pop eax
mov word [ebp - 0x63a], ax
lea eax, [ebp - 0x63c]
push eax
lea eax, [ebp - 0x61c]
push eax
mov dword [ebp - 0x638], 0x22b7e
call dword [sym.imp.ntoskrnl.exe_RtlCopyUnicodeString]
push dword [ebp - 0x648]
lea eax, [ebp - 0x61c]
push eax
call dword [sym.imp.ntoskrnl.exe_RtlAppendUnicodeStringToString]
lea eax, [ebp - 0x61c]
mov dword [ebp - 0x668], eax
lea eax, [ebp - 0x670]
push eax
push 0x20019
lea eax, [ebp - 0x608]
push eax
mov dword [ebp - 0x670], 0x18
mov dword [ebp - 0x66c], ebx
mov dword [ebp - 0x664], 0x240
mov dword [ebp - 0x660], ebx
mov dword [ebp - 0x65c], ebx
call dword [sym.imp.ntoskrnl.exe_ZwOpenKey]
test eax, eax
jl 0x139ce
push 0x1ff
lea eax, [ebp - 0x203]
push ebx
push eax
mov byte [ebp - 0x204], bl
call sub.ntoskrnl.exe_memset
mov edi, dword [sym.imp.ntoskrnl.exe_ZwQueryValueKey]
add esp, 0xc
lea eax, [ebp - 0x624]
push eax
push ebx
push ebx
push 2
push esi
push dword [ebp - 0x608]
mov dword [ebp - 0x624], ebx
call edi
cmp eax, 0xc0000034
je 0x139c2
cmp dword [ebp - 0x624], ebx
je 0x139c2
cmp dword [ebp - 0x624], 0xc8
jae 0x139c2
lea eax, [ebp - 0x628]
push eax
push dword [ebp - 0x624]
lea eax, [ebp - 0x204]
push eax
push 2
push esi
push dword [ebp - 0x608]
mov dword [ebp - 0x628], ebx
call edi
test eax, eax
jl 0x139c2
mov eax, dword [ebp - 0x628]
lea ecx, [eax - 0xc]
cmp ecx, 0xbb
ja 0x139c2
cmp eax, dword [ebp + 0x18]
ja 0x139c2
mov eax, dword [ebp - 0x1fc]
cmp eax, 0x1e0
ja 0x1333f
cmp eax, dword [ebp + 0x18]
ja 0x1333f
push eax
lea eax, [ebp - 0x1f8]
push eax
push dword [ebp - 0x650]
call sub.ntoskrnl.exe_memcpy
add esp, 0xc
mov bl, 1
push dword [ebp - 0x608]
call dword [sym.imp.ntoskrnl.exe_ZwClose]
mov al, bl
jmp 0x139d0
cmp dword [ebp + 8], 2
jne 0x139ce
mov esi, dword [sym.imp.ntoskrnl.exe_RtlInitUnicodeString]
xor eax, eax
mov word [ebp - 0x63c], ax
lea edi, [ebp - 0x63a]
stosd dword es:[edi], eax
stosw word es:[edi], ax
push 0x22b5e
lea eax, [ebp - 0x63c]
xor ebx, ebx
push eax
mov byte [ebp - 0x61d], bl
call esi
xor eax, eax
lea edi, [ebp - 0x612]
stosd dword es:[edi], eax
stosw word es:[edi], ax
xor eax, eax
mov word [ebp - 0x614], ax
mov eax, 0x400
push 0x4d746147
mov ecx, eax
push eax
mov word [ebp - 0x612], cx
call fcn.0001457a
push eax
call fcn.000123d2
mov dword [ebp - 0x610], eax
cmp eax, ebx
je 0x139ce
lea eax, [ebp - 0x63c]
push eax
lea eax, [ebp - 0x614]
push eax
call dword [sym.imp.ntoskrnl.exe_RtlCopyUnicodeString]
xor eax, eax
mov word [ebp - 0x658], ax
lea edi, [ebp - 0x656]
stosd dword es:[edi], eax
stosw word es:[edi], ax
push 0x22ac6
lea eax, [ebp - 0x658]
push eax
call esi
xor eax, eax
lea edi, [ebp - 0x61a]
stosd dword es:[edi], eax
stosw word es:[edi], ax
xor eax, eax
mov word [ebp - 0x61c], ax
mov eax, 0x400
mov esi, 0x4d746147
push esi
mov ecx, eax
push eax
mov word [ebp - 0x61a], cx
call fcn.0001457a
push eax
call fcn.000123d2
mov dword [ebp - 0x618], eax
cmp eax, ebx
jne 0x1344e
push esi
push dword [ebp - 0x610]
call fcn.000124d0
jmp 0x139ce
lea eax, [ebp - 0x658]
push eax
lea eax, [ebp - 0x61c]
push eax
call dword [sym.imp.ntoskrnl.exe_RtlCopyUnicodeString]
xor eax, eax
lea edi, [ebp - 0x66c]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
lea eax, [ebp - 0x658]
mov dword [ebp - 0x668], eax
lea eax, [ebp - 0x670]
push eax
push 0x20019
lea eax, [ebp - 0x608]
push eax
mov dword [ebp - 0x670], 0x18
mov dword [ebp - 0x66c], ebx
mov dword [ebp - 0x664], 0x240
mov dword [ebp - 0x660], ebx
mov dword [ebp - 0x65c], ebx
mov dword [ebp - 0x608], ebx
call dword [sym.imp.ntoskrnl.exe_ZwOpenKey]
test eax, eax
jge 0x134e2
push esi
push dword [ebp - 0x610]
call fcn.000124d0
push esi
push dword [ebp - 0x618]
mov dword [ebp - 0x610], ebx
jmp 0x13444
mov edi, dword [sym.imp.ntoskrnl.exe_ZwQueryKey]
lea eax, [ebp - 0x60c]
push eax
push ebx
push ebx
push 2
push dword [ebp - 0x608]
mov dword [ebp - 0x60c], ebx
call edi
cmp eax, ebx
jge 0x13517
cmp eax, 0x80000005
je 0x13517
cmp eax, 0xc0000023
jne 0x1399e
cmp dword [ebp - 0x60c], ebx
je 0x1399e
cmp dword [ebp - 0x60c], 0x400
ja 0x1399e
push 0x504649
push dword [ebp - 0x60c]
call fcn.0001457a
push eax
call fcn.000123d2
mov dword [ebp - 0x630], eax
cmp eax, ebx
je 0x1399e
lea ecx, [ebp - 0x60c]
push ecx
push dword [ebp - 0x60c]
push eax
push 2
push dword [ebp - 0x608]
call edi
test eax, eax
jl 0x1398e
cmp dword [ebp - 0x60c], ebx
je 0x1398e
mov eax, dword [ebp - 0x630]
mov byte [ebp - 0x61e], bl
mov dword [ebp - 0x624], ebx
cmp dword [eax + 0x14], ebx
jbe 0x13936
mov edi, dword [sym.imp.ntoskrnl.exe_ZwEnumerateKey]
lea eax, [ebp - 0x60c]
push eax
push ebx
push ebx
push ebx
push dword [ebp - 0x624]
push dword [ebp - 0x608]
call edi
cmp eax, ebx
jge 0x135d2
cmp eax, 0x80000005
je 0x135d2
cmp eax, 0xc0000023
jne 0x13909
cmp dword [ebp - 0x60c], ebx
je 0x13909
cmp dword [ebp - 0x60c], 0x400
ja 0x13909
push 0x504249
push dword [ebp - 0x60c]
call fcn.0001457a
push eax
call fcn.000123d2
mov dword [ebp - 0x634], eax
cmp eax, ebx
je 0x13936
lea ecx, [ebp - 0x60c]
push ecx
push dword [ebp - 0x60c]
push eax
push ebx
push dword [ebp - 0x624]
push dword [ebp - 0x608]
call edi
test eax, eax
jl 0x13926
cmp dword [ebp - 0x60c], ebx
je 0x13926
xor eax, eax
mov word [ebp - 0x644], ax
lea edi, [ebp - 0x642]
stosd dword es:[edi], eax
stosw word es:[edi], ax
mov edi, dword [ebp - 0x634]
mov ax, word [edi + 0xc]
mov word [ebp - 0x644], ax
mov cx, word [edi + 0xc]
mov word [ebp - 0x642], cx
lea ecx, [edi + 0x10]
mov dword [ebp - 0x640], ecx
cmp ax, 0x14
jbe 0x138d0
lea eax, [ebp - 0x644]
push eax
lea eax, [ebp - 0x61c]
push eax
call dword [sym.imp.ntoskrnl.exe_RtlAppendUnicodeStringToString]
push 0x34
lea eax, [ebp - 0x6c8]
push ebx
push eax
mov dword [ebp - 0x674], ebx
mov dword [ebp - 0x678], ebx
mov dword [ebp - 0x6cc], ebx
call sub.ntoskrnl.exe_memset
add esp, 0xc
lea eax, [ebp - 0x674]
mov dword [ebp - 0x6c0], eax
push 4
pop eax
mov dword [ebp - 0x6bc], eax
mov dword [ebp - 0x6b4], eax
lea eax, [ebp - 0x678]
mov dword [ebp - 0x6b8], eax
mov dword [ebp - 0x6c8], 0x20
mov dword [ebp - 0x6c4], 0x22ab4
cmp byte [ebp + 0x1c], bl
je 0x1371f
push ebx
push ebx
lea eax, [ebp - 0x6cc]
push eax
push dword [ebp - 0x618]
push ebx
call dword [sym.imp.ntoskrnl.exe_RtlQueryRegistryValues]
cmp word [ebp - 0x61c], bx
je 0x138d0
lea eax, [ebp - 0x644]
push eax
lea eax, [ebp - 0x614]
push eax
call dword [sym.imp.ntoskrnl.exe_RtlAppendUnicodeStringToString]
mov ecx, dword [ebp - 0x648]
cmp word [ecx], 2
jb 0x13785
mov eax, dword [ecx + 4]
cmp word [eax], 0x5c
je 0x13785
movzx eax, word [ebp - 0x614]
mov edx, dword [ebp - 0x610]
shr eax, 1
lea eax, [edx + eax*2]
cmp word [eax - 2], 0x5c
je 0x13785
push 0x5c
pop edx
mov word [eax], dx
movzx eax, word [ebp - 0x614]
mov edi, dword [ebp - 0x610]
shr eax, 1
xor edx, edx
mov word [edi + eax*2 + 2], dx
add word [ebp - 0x614], 2
push ecx
lea eax, [ebp - 0x614]
push eax
call dword [sym.imp.ntoskrnl.exe_RtlAppendUnicodeStringToString]
xor eax, eax
lea edi, [ebp - 0x690]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
lea eax, [ebp - 0x614]
mov dword [ebp - 0x68c], eax
lea eax, [ebp - 0x694]
push eax
push 0x20019
lea eax, [ebp - 0x62c]
push eax
mov dword [ebp - 0x694], 0x18
mov dword [ebp - 0x690], ebx
mov dword [ebp - 0x688], 0x240
mov dword [ebp - 0x684], ebx
mov dword [ebp - 0x680], ebx
mov dword [ebp - 0x62c], ebx
call dword [sym.imp.ntoskrnl.exe_ZwOpenKey]
test eax, eax
jl 0x138ca
lea eax, [ebp - 0x628]
push eax
push ebx
push ebx
push 2
push dword [ebp - 0x64c]
mov dword [ebp - 0x628], ebx
push dword [ebp - 0x62c]
call dword [sym.imp.ntoskrnl.exe_ZwQueryValueKey]
cmp eax, ebx
jge 0x13832
cmp eax, 0x80000005
je 0x13832
cmp eax, 0xc0000023
jne 0x138b8
push 0x52454749
push dword [ebp - 0x628]
mov byte [ebp - 0x61e], 1
call fcn.0001457a
push eax
call fcn.000123d2
mov edi, eax
cmp edi, ebx
je 0x138b8
lea eax, [ebp - 0x67c]
push eax
push dword [ebp - 0x628]
mov dword [ebp - 0x67c], ebx
push edi
push 2
push dword [ebp - 0x64c]
push dword [ebp - 0x62c]
call dword [sym.imp.ntoskrnl.exe_ZwQueryValueKey]
test eax, eax
jl 0x138ad
cmp dword [edi + 4], 1
jne 0x138ad
mov eax, dword [edi + 8]
cmp eax, ebx
jbe 0x138ad
cmp eax, dword [ebp + 0x18]
ja 0x138ad
push eax
lea eax, [edi + 0xc]
push eax
push dword [ebp - 0x650]
call sub.ntoskrnl.exe_memcpy
add esp, 0xc
mov byte [ebp - 0x61d], 1
push 0x52454749
push edi
call fcn.000124d0
push dword [ebp - 0x62c]
call dword [sym.imp.ntoskrnl.exe_ZwClose]
mov dword [ebp - 0x62c], ebx
mov edi, dword [ebp - 0x634]
push 0x504249
push edi
call fcn.000124d0
cmp byte [ebp - 0x61e], bl
jne 0x13936
mov edi, dword [sym.imp.ntoskrnl.exe_RtlCopyUnicodeString]
lea eax, [ebp - 0x63c]
push eax
lea eax, [ebp - 0x614]
push eax
call edi
lea eax, [ebp - 0x658]
push eax
lea eax, [ebp - 0x61c]
push eax
call edi
inc dword [ebp - 0x624]
mov eax, dword [ebp - 0x630]
mov ecx, dword [ebp - 0x624]
cmp ecx, dword [eax + 0x14]
jb 0x1359e
jmp 0x13936
push 0x504249
push dword [ebp - 0x634]
call fcn.000124d0
push 0x504649
push dword [ebp - 0x630]
call fcn.000124d0
push dword [ebp - 0x608]
call dword [sym.imp.ntoskrnl.exe_ZwClose]
mov dword [ebp - 0x608], ebx
cmp dword [ebp - 0x610], ebx
je 0x13972
push esi
push dword [ebp - 0x610]
call fcn.000124d0
mov dword [ebp - 0x610], ebx
cmp dword [ebp - 0x618], ebx
je 0x13986
push esi
push dword [ebp - 0x618]
call fcn.000124d0
mov al, byte [ebp - 0x61d]
jmp 0x139d0
push 0x504649
push dword [ebp - 0x630]
call fcn.000124d0
push esi
push dword [ebp - 0x610]
call fcn.000124d0
push esi
push dword [ebp - 0x618]
mov dword [ebp - 0x610], ebx
call fcn.000124d0
mov dword [ebp - 0x618], ebx
push dword [ebp - 0x608]
call dword [sym.imp.ntoskrnl.exe_ZwClose]
xor al, al
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.000223b6
leave
ret 0x18