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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5d8436
mov eax, dword fs:[0]
push eax
mov eax, 0x17a8
call fcn.005a8610
mov eax, dword [0x659fd4]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, edx
mov dword [ebp - 0x17a4], ebx
mov esi, ecx
mov byte [ebp - 0x1799], 0
mov dword [ebp - 0x17b4], 0
mov dword [ebp - 0x17b0], 0
mov dword [ebp - 0x17ac], 0
push str.SOFTWAREMicrosoftWindowsCurrentVersionApp_Paths_
lea ecx, [ebp - 0x1798]
mov dword [ebp - 4], 0
call fcn.004076f8
mov byte [ebp - 4], 1
mov edx, esi
cmp dword [esi + 0x14], 8
jb 0x4376a6
mov edx, dword [esi]
mov ecx, dword [esi + 0x10]
mov esi, dword [ebp - 0x1788]
mov eax, dword [ebp - 0x1784]
sub eax, esi
mov dword [ebp - 0x17a0], esi
cmp ecx, eax
ja 0x4376fd
cmp dword [ebp - 0x1784], 8
lea edi, [esi + ecx]
lea eax, [ecx + ecx]
mov dword [ebp - 0x1788], edi
push eax
mov eax, dword [ebp - 0x17a0]
lea esi, [ebp - 0x1798]
cmovae esi, dword [ebp - 0x1798]
push edx
lea eax, [esi + eax*2]
push eax
call fcn.005abfe0
add esp, 0xc
xor eax, eax
mov word [esi + edi*2], ax
jmp 0x437718
push ecx
push edx
mov byte [ebp - 0x17a0], 0
push dword [ebp - 0x17a0]
push ecx
lea ecx, [ebp - 0x1798]
call fcn.0041ad40
cmp dword [ebp - 0x1784], 8
lea eax, [ebp - 0x1798]
push 0x20019
cmovae eax, dword [ebp - 0x1798]
lea ecx, [ebp - 0x17b4]
push eax
push reloc.OLEAUT32.dll_SysReAllocString
call fcn.0042f890
mov esi, dword [ebp - 0x17b4]
test eax, eax
jne 0x4377a8
lea eax, [ebp - 0x17a0]
mov dword [ebp - 0x17a0], 0x7d0
push eax
lea eax, [ebp - 0x7e0]
push eax
lea eax, [ebp - 0x17a8]
push eax
push 0
push 0x624ff8
push esi
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x4377a8
mov eax, dword [ebp - 0x17a8]
cmp eax, 1
je 0x43778d
cmp eax, 2
jne 0x4377a8
mov eax, dword [ebp - 0x17a0]
test eax, eax
je 0x437801
test al, 1
jne 0x4377a8
shr eax, 1
cmp word [ebp + eax*2 - 0x7e2], 0
je 0x43780a
mov bl, byte [ebp - 0x1799]
lea ecx, [ebp - 0x1798]
mov byte [ebp - 4], 0
call fcn.004076c4
mov dword [ebp - 4], 0xffffffff
test esi, esi
je 0x4377d9
push esi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [ebp - 0x17b4], 0
mov dword [ebp - 0x17b0], 0
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.005a7b5f
mov esp, ebp
pop ebp
ret
xor eax, eax
mov word [ebp - 0x7e0], ax
push 0x7d0
lea eax, [ebp - 0x1780]
push eax
lea eax, [ebp - 0x7e0]
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
lea esi, [ebp - 0x1780]
lea ecx, [esi + 2]
nop dword [eax]
mov ax, word [esi]
add esi, 2
test ax, ax
jne 0x437830
sub esi, ecx
mov ecx, dword [ebx + 0x14]
sar esi, 1
mov dword [ebp - 0x17a8], ecx
cmp esi, ecx
ja 0x43787e
mov edi, ebx
cmp ecx, 8
jb 0x437855
mov edi, dword [ebx]
mov dword [ebx + 0x10], esi
lea eax, [ebp - 0x1780]
add esi, esi
push esi
push eax
push edi
call fcn.005abfe0
add esp, 0xc
mov bl, 1
xor eax, eax
mov word [esi + edi], ax
mov esi, dword [ebp - 0x17b4]
jmp 0x4377ae
cmp esi, 0x7ffffffe
ja 0x437982
mov edi, esi
or edi, 7
cmp edi, 0x7ffffffe
jbe 0x43789e
mov edi, SysReAllocString
jmp 0x4378bc
mov edx, ecx
mov eax, SysReAllocString
shr edx, 1
sub eax, edx
cmp ecx, eax
jbe 0x4378b4
mov edi, SysReAllocString
jmp 0x4378bc
lea eax, [edx + ecx]
cmp edi, eax
cmovb edi, eax
lea eax, [edi + 1]
lea ecx, [eax + eax]
cmp eax, 0x7fffffff
jbe 0x4378ce
or ecx, 0xffffffff
jmp 0x4378d6
cmp ecx, 0x1000
jb 0x4378fd
lea eax, [ecx + 0x23]
or edx, 0xffffffff
cmp eax, ecx
cmovbe eax, edx
push eax
call fcn.00461253
add esp, 4
test eax, eax
je 0x437987
lea ebx, [eax + 0x23]
and ebx, 0xffffffe0
mov dword [ebx - 4], eax
jmp 0x437910
test ecx, ecx
je 0x43790e
push ecx
call fcn.00461253
add esp, 4
mov ebx, eax
jmp 0x437910
xor ebx, ebx
mov eax, dword [ebp - 0x17a4]
mov dword [eax + 0x10], esi
add esi, esi
mov dword [eax + 0x14], edi
lea eax, [ebp - 0x1780]
push esi
push eax
push ebx
call fcn.005aba60
mov ecx, dword [ebp - 0x17a8]
xor eax, eax
add esp, 0xc
mov word [esi + ebx], ax
mov esi, dword [ebp - 0x17a4]
cmp ecx, 8
jb 0x437973
mov eax, dword [esi]
lea ecx, [ecx*2 + 2]
cmp ecx, 0x1000
jb 0x437969
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x437987
mov eax, edx
push ecx
push eax
call fcn.005a7e2d
add esp, 8
mov dword [esi], ebx
mov bl, 1
mov esi, dword [ebp - 0x17b4]
jmp 0x4377ae
call fcn.00405425
call fcn.005af179
int3