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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x424
mov eax, dword [0x103f058]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
mov edi, dword [ebp + 8]
push edi
push dword [0x103f06c]
lea eax, [ebp - 0x20c]
push 0x1008fa8
xor esi, esi
push 0x103
push eax
mov dword [ebp - 0x420], esi
mov dword [ebp - 0x424], esi
call fcn.01027f64
add esp, 0x14
lea eax, [ebp - 0x420]
push eax
push 0x20019
push esi
lea eax, [ebp - 0x20c]
push eax
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x1038d72
push ebx
lea eax, [ebp - 0x41c]
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x418]
push eax
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push 0x1008f0c
push dword [ebp - 0x420]
xor ebx, ebx
inc ebx
mov dword [ebp - 0x418], ebx
mov dword [ebp - 0x41c], 0x208
call esi
test eax, eax
jne 0x1038bf1
cmp dword [ebp - 0x418], ebx
je 0x1038b60
cmp dword [ebp - 0x418], 2
jne 0x1038bf1
lea eax, [ebp - 0x20c]
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
test cx, cx
jne 0x1038b69
sub eax, edx
sar eax, 1
cmp eax, 5
jbe 0x1038bf1
cmp dword [ebp - 0x418], 2
mov ebx, 0x104
jne 0x1038bc3
push ebx
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
test eax, eax
je 0x1038d65
lea eax, [ebp - 0x414]
push eax
push ebx
lea eax, [ebp - 0x20c]
push eax
call fcn.01027e68
test eax, eax
jl 0x1038d65
push 1
push ebx
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
call fcn.0103c444
test eax, eax
jl 0x1038bf1
lea eax, [ebp - 0x414]
push eax
call fcn.0102e8b9
test eax, eax
je 0x1038d65
lea eax, [ebp - 0x41c]
push eax
lea eax, [edi + 0x3e8]
push eax
lea eax, [ebp - 0x418]
push eax
push 0
push 0x1008f8c
push dword [ebp - 0x420]
mov dword [ebp - 0x41c], 0x14
call esi
test eax, eax
jne 0x1038d65
cmp dword [ebp - 0x418], 1
jne 0x1038d65
lea eax, [ebp - 0x41c]
push eax
lea eax, [edi + 0xc8]
push eax
lea eax, [ebp - 0x418]
push eax
push 0
push 0x1008f64
push dword [ebp - 0x420]
mov ebx, 0x12c
mov dword [ebp - 0x41c], ebx
call esi
test eax, eax
jne 0x1038d65
cmp dword [ebp - 0x418], 1
jne 0x1038d65
lea ecx, [ebp - 0x41c]
push ecx
lea eax, [edi + 0x320]
push eax
lea eax, [ebp - 0x418]
push eax
push 0
push 0x1001b94
push dword [ebp - 0x420]
mov dword [ebp - 0x41c], 0xc8
call esi
test eax, eax
jne 0x1038cb3
cmp dword [ebp - 0x418], 1
je 0x1038cc6
push 0x1002720
push 0x64
lea eax, [edi + 0x320]
push eax
call fcn.01027e68
lea eax, [ebp - 0x41c]
push eax
lea eax, [edi + 0x1f4]
push eax
lea eax, [ebp - 0x418]
push eax
push 0
push 0x1008f3c
push dword [ebp - 0x420]
mov dword [ebp - 0x41c], ebx
call esi
test eax, eax
jne 0x1038d65
xor ebx, ebx
inc ebx
cmp dword [ebp - 0x418], ebx
jne 0x1038d65
lea eax, [ebp - 0x41c]
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x418]
push eax
push 0
push 0x1008f28
push dword [ebp - 0x420]
mov dword [ebp - 0x41c], 0x208
call esi
test eax, eax
jne 0x1038d59
cmp dword [ebp - 0x418], ebx
jne 0x1038d59
lea eax, [ebp - 0x20c]
push 0x100559c
push eax
call dword [sym.imp.msvcrt.dll__wcsicmp]
pop ecx
pop ecx
test eax, eax
jne 0x1038d59
and dword [edi + 0x3fc], eax
jmp 0x1038d5f
mov dword [edi + 0x3fc], ebx
mov dword [ebp - 0x424], ebx
push dword [ebp - 0x420]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop ebx
mov ecx, dword [ebp - 4]
mov eax, dword [ebp - 0x424]
pop edi
xor ecx, ebp
pop esi
call fcn.0102df7d
leave
ret 4