Function at 0x404160
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x44013b
mov eax, dword fs:[0]
push eax
sub esp, 0x674
mov eax, dword [0x454688]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x670], ecx
lea ecx, [ebp - 0x238]
call fcn.0040c8f6
mov dword [ebp - 4], 0
xor eax, eax
mov word [ebp - 0x220], ax
mov byte [ebp - 0x44d], 0
mov ecx, dword [ebp - 0x670]
add ecx, 0x4f94
call fcn.004054c0
push 0x105
lea ecx, [ebp - 0x44c]
push ecx
push str.WINDIR
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
je 0x4043fe
push str.System32
push 0x105
lea edx, [ebp - 0x44c]
push edx
call fcn.00401730
push 0x44a0dc
push 0x105
lea eax, [ebp - 0x44c]
push eax
call fcn.00401730
push 0
lea ecx, [ebp - 0x44c]
push ecx
lea ecx, [ebp - 0x238]
call fcn.0040c98e
test eax, eax
je 0x4043fe
lea edx, [ebp - 0x220]
push edx
lea eax, [ebp - 0x660]
push eax
lea ecx, [ebp - 0x664]
push ecx
lea edx, [ebp - 0x454]
push edx
push ecx
mov ecx, esp
mov dword [ebp - 0x668], esp
lea eax, [ebp - 0x44c]
push eax
call fcn.00405120
mov dword [ebp - 0x674], eax
mov ecx, dword [ebp - 0x670]
call fcn.00403230
mov dword [ebp - 0x678], eax
cmp dword [ebp - 0x678], 0
je 0x4043fe
movzx ecx, word [ebp - 0x454]
cmp ecx, 4
jg 0x4042a4
movzx edx, word [ebp - 0x454]
cmp edx, 4
jne 0x404309
movzx eax, word [ebp - 0x664]
cmp eax, 5
jl 0x404309
mov byte [ebp - 0x44d], 1
push 0x44a0f0
push 0x209
mov ecx, dword [ebp - 0x670]
add ecx, 0x1caa
push ecx
call fcn.004016e0
mov edx, dword [ebp - 0x670]
cmp dword [edx + 0x4f9c], 0
je 0x4042eb
mov eax, 1
test eax, eax
je 0x4042eb
mov dword [ebp - 0x67c], 1
jmp 0x4042f5
mov dword [ebp - 0x67c], 0
mov ecx, dword [ebp - 0x670]
mov edx, dword [ebp - 0x67c]
mov dword [ecx + 0x4f9c], edx
jmp 0x40434b
mov byte [ebp - 0x44d], 0
mov eax, dword [ebp - 0x670]
cmp dword [eax + 0x4f9c], 0
je 0x40432f
xor ecx, ecx
je 0x40432f
mov dword [ebp - 0x680], 1
jmp 0x404339
mov dword [ebp - 0x680], 0
mov edx, dword [ebp - 0x670]
mov eax, dword [ebp - 0x680]
mov dword [edx + 0x4f9c], eax
push 0xa
lea ecx, [ebp - 0x21c]
push ecx
movzx edx, word [ebp - 0x454]
push edx
call fcn.00406280
add esp, 0xc
push 0xa
lea eax, [ebp - 0x65c]
push eax
movzx ecx, word [ebp - 0x664]
push ecx
call fcn.00406280
add esp, 0xc
push str.Windows_Installer_Major_Version_is_:
mov ecx, dword [ebp - 0x670]
add ecx, 0x4f94
call fcn.004051c0
lea edx, [ebp - 0x21c]
push edx
mov ecx, dword [ebp - 0x670]
add ecx, 0x4f94
call fcn.00405200
push str._nWindows_Installer_Minor_Version_is_:
mov ecx, dword [ebp - 0x670]
add ecx, 0x4f94
call fcn.00405200
lea eax, [ebp - 0x65c]
push eax
mov ecx, dword [ebp - 0x670]
add ecx, 0x4f94
call fcn.00405200
mov ecx, dword [ebp - 0x670]
add ecx, 0x4f94
push ecx
mov edx, dword [ebp - 0x670]
add edx, 0x4f90
push edx
mov ecx, dword [ebp - 0x670]
call fcn.00404940
movzx eax, byte [ebp - 0x44d]
mov dword [ebp - 0x66c], eax
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x238]
call fcn.0040c91f
mov eax, dword [ebp - 0x66c]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004296c6
mov esp, ebp
pop ebp
ret