Function at 0x100aba8
Capabilities:
Query environment variable
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x24
push ebx
push esi
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x30]
mov ebx, 0x400
push ebx
push 0
push dword [eax + 0x18]
call dword [sym.imp.ntdll.dll_RtlAllocateHeap]
mov esi, eax
test esi, esi
jne 0x100abdc
mov eax, 0xc0000017
jmp 0x100ad80
push edi
mov ecx, 0x100
xor eax, eax
mov edi, esi
rep stosd dword es:[edi], eax
xor edi, edi
mov word [ebp - 0xc], di
mov word [ebp - 0xa], bx
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x30]
push ebx
push edi
push dword [eax + 0x18]
call dword [sym.imp.ntdll.dll_RtlAllocateHeap]
cmp eax, edi
mov dword [ebp - 8], eax
jne 0x100ac2b
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x30]
push esi
push edi
push dword [eax + 0x18]
call dword [sym.imp.ntdll.dll_RtlFreeHeap]
mov eax, 0xc0000017
jmp 0x100ad7f
mov ecx, dword [ebp + 0xc]
mov eax, ecx
lea edx, [eax + 1]
mov word [ebp - 0x1a], bx
mov dword [ebp + 0xc], edx
mov dl, byte [eax]
inc eax
test dl, dl
jne 0x100ac3a
sub eax, dword [ebp + 0xc]
push edi
mov word [ebp - 0x1c], ax
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0xc]
push eax
mov dword [ebp - 0x18], ecx
call dword [sym.imp.ntdll.dll_RtlAnsiStringToUnicodeString]
lea eax, [ebp - 4]
push eax
push ebx
push esi
push 1
lea eax, [ebp - 0xc]
push eax
push dword [ebp + 8]
call dword [sym.imp.ntdll.dll_NtQueryValueKey]
cmp eax, edi
mov dword [ebp + 0xc], eax
jge 0x100aca3
mov eax, dword fs:[0x18]
push dword [ebp - 8]
mov eax, dword [eax + 0x30]
mov ebx, dword [sym.imp.ntdll.dll_RtlFreeHeap]
push edi
push dword [eax + 0x18]
call ebx
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x30]
push esi
push edi
push dword [eax + 0x18]
call ebx
jmp 0x100ad7c
mov eax, dword [esi + 4]
cmp eax, 4
mov ecx, dword [ebp + 0x14]
mov dword [ecx], eax
je 0x100ad48
cmp eax, 3
je 0x100ad48
cmp eax, 2
mov word [ebp - 0x14], di
mov edi, dword [sym.imp.ntdll.dll_RtlFreeHeap]
jne 0x100acd8
mov eax, dword [ebp - 8]
mov dword [ebp - 0x10], eax
mov word [ebp - 0x12], bx
jmp 0x100acf9
mov eax, dword fs:[0x18]
push dword [ebp - 8]
mov eax, dword [eax + 0x30]
push 0
push dword [eax + 0x18]
call edi
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x10], eax
mov ax, word [ebp + 0x18]
mov word [ebp - 0x12], ax
mov ax, word [esi + 0xc]
mov word [ebp - 0x24], ax
mov ax, word [esi + 0xc]
mov word [ebp - 0x22], ax
mov eax, dword [esi + 8]
add eax, esi
mov dword [ebp - 0x20], eax
push 0
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x14]
push eax
call dword [sym.imp.ntdll.dll_RtlUnicodeStringToAnsiString]
mov eax, dword [ebp + 0x14]
cmp dword [eax], 2
jne 0x100ad6b
push dword [ebp + 0x18]
push dword [ebp + 0x10]
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
mov dword [ebp - 4], eax
mov eax, dword fs:[0x18]
push dword [ebp - 0x10]
push 0
jmp 0x100ad63
mov eax, dword [esi + 8]
mov eax, dword [esi + eax]
mov ecx, dword [ebp + 0x10]
mov dword [ecx], eax
mov eax, dword fs:[0x18]
push dword [ebp - 8]
push edi
mov edi, dword [sym.imp.ntdll.dll_RtlFreeHeap]
mov eax, dword [eax + 0x30]
push dword [eax + 0x18]
call edi
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x30]
push esi
push 0
push dword [eax + 0x18]
call edi
mov eax, dword [ebp + 0xc]
pop edi
pop esi
pop ebx
leave
ret 0x14