Function at 0x10018230
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x34
mov dword [ebp - 0x24], 0
mov dword [ebp - 4], 0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0x24
mov dword [ebp - 0x10], 0x26
mov dword [ebp - 0xc], 0x2a
mov dword [ebp - 0x20], 3
mov dword [ebp - 8], 0
cmp dword [0x10320260], 0
jne 0x100182f4
push 3
push 0x20
push 3
push 1
push 3
push 2
push 0
push 0
call sub.KERNEL32.dll_VerSetConditionMask
push edx
push eax
call sub.KERNEL32.dll_VerSetConditionMask
push edx
push eax
call sub.KERNEL32.dll_VerSetConditionMask
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x2c], edx
mov dword [0x10320260], 0x11c
mov dword [0x10320264], 6
mov dword [0x10320268], 1
mov word [0x10320374], 0
mov eax, dword [ebp - 0x2c]
push eax
mov ecx, dword [ebp - 0x30]
push ecx
push 0x23
push 0x10320260
call dword [sym.imp.KERNEL32.dll_VerifyVersionInfoW]
neg eax
sbb eax, eax
inc eax
mov dword [0x102f70a0], eax
cmp dword [0x102f70a0], 0
je 0x10018307
mov eax, 1
jmp 0x100184ce
cmp dword [ebp + 8], 0
jne 0x10018312
jmp 0x100184b7
push 0
push 0
push 0
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.KERNEL32.dll_GetFullPathNameW]
mov dword [ebp - 0x24], eax
cmp dword [ebp - 0x24], 0
jne 0x10018330
jmp 0x100184b7
mov eax, dword [ebp - 0x24]
shl eax, 1
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0
jne 0x1001834c
jmp 0x100184b7
push 0
mov ecx, dword [ebp - 0x1c]
push ecx
mov edx, dword [ebp - 0x24]
push edx
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_GetFullPathNameW]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 0x24]
cmp ecx, dword [ebp - 4]
ja 0x10018370
jmp 0x100184b7
mov dword [ebp - 8], 0
jmp 0x10018382
mov edx, dword [ebp - 8]
add edx, 1
mov dword [ebp - 8], edx
mov eax, dword [ebp - 8]
cmp eax, dword [ebp - 0x20]
jge 0x100184b7
mov ecx, dword [ebp - 8]
cmp dword [ebp + ecx*4 - 0x14], 0x26
jne 0x10018458
push 0
push 0
push 0x102f70a4
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
mov dword [ebp - 0x34], eax
cmp dword [ebp - 0x34], 0
je 0x100183cd
mov edx, dword [ebp - 0x34]
lea eax, [edx + edx + 2]
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov dword [ebp - 0x28], eax
cmp dword [ebp - 0x28], 0
jne 0x100183d2
jmp 0x100184b7
mov ecx, dword [ebp - 0x34]
push ecx
mov edx, dword [ebp - 0x28]
push edx
push 0x102f70c4
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
cmp dword [ebp - 0x34], eax
je 0x100183ef
jmp 0x100184b7
mov eax, dword [ebp - 0x28]
push eax
push str._ProgramW6432_
call dword [sym.imp.KERNEL32.dll_lstrcmpW]
test eax, eax
jne 0x10018431
mov ecx, dword [ebp - 0x28]
push ecx
call dword [sym.imp.KERNEL32.dll_LocalFree]
push 0x1032037c
mov edx, dword [ebp - 8]
mov eax, dword [ebp + edx*4 - 0x14]
push eax
call fcn.100184e0
add esp, 8
mov dword [ebp - 0x28], eax
cmp dword [ebp - 0x28], 0
jne 0x1001842f
jmp 0x100184b7
jmp 0x10018456
mov ecx, dword [ebp - 0x34]
mov edx, dword [ebp - 0x28]
movzx eax, word [edx + ecx*2 - 4]
cmp eax, 0x5c
je 0x10018456
push 0x102f7104
mov ecx, dword [ebp - 0x34]
add ecx, 1
push ecx
mov edx, dword [ebp - 0x28]
push edx
call fcn.10019460
jmp 0x10018478
push 0x10320380
mov eax, dword [ebp - 8]
mov ecx, dword [ebp + eax*4 - 0x14]
push ecx
call fcn.100184e0
add esp, 8
mov dword [ebp - 0x28], eax
cmp dword [ebp - 0x28], 0
jne 0x10018478
jmp 0x100184b7
mov edx, dword [ebp - 0x28]
push edx
call sub.api_ms_win_crt_string_l1_1_0.dll_wcslen
add esp, 4
push eax
mov eax, dword [ebp - 0x28]
push eax
mov ecx, dword [ebp - 0x1c]
push ecx
call sub.api_ms_win_crt_string_l1_1_0.dll__wcsnicmp
add esp, 0xc
neg eax
sbb eax, eax
inc eax
mov dword [ebp - 0x18], eax
je 0x100184a1
jmp 0x100184b7
mov edx, dword [ebp - 0x28]
push edx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [ebp - 0x28], 0
jmp 0x10018379
mov eax, dword [ebp - 0x28]
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov ecx, dword [ebp - 0x1c]
push ecx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, dword [ebp - 0x18]
mov esp, ebp
pop ebp
ret