Function at 0x415790
Capabilities:
Get common file path
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5988b0
mov eax, dword fs:[0]
push eax
sub esp, 0x130
mov eax, dword [0x6031c0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x78], ecx
mov dword [ebp - 0x104], 0x22
mov dword [ebp - 0x88], 0
jmp 0x4157e3
mov eax, dword [ebp - 0x88]
add eax, 1
mov dword [ebp - 0x88], eax
mov ecx, dword [ebp - 0x88]
cmp ecx, dword [ebp - 0x104]
jge 0x415aa1
mov edx, dword [ebp - 0x88]
shl edx, 4
add edx, section..data
mov dword [ebp - 0x7c], edx
lea ecx, [ebp - 0x74]
call fcn.00402220
mov dword [ebp - 4], 0
mov eax, dword [ebp - 0x7c]
cmp dword [eax + 8], 0xffffffff
jne 0x4158dd
push str.Temp
mov ecx, dword [ebp - 0x7c]
mov edx, dword [ecx]
push edx
lea ecx, [ebp - 0x118]
call fcn.004020c0
mov dword [ebp - 0x114], eax
mov eax, dword [ebp - 0x114]
push eax
call fcn.00402670
add esp, 8
mov byte [ebp - 0x81], al
lea ecx, [ebp - 0x118]
call fcn.004023e0
movzx ecx, byte [ebp - 0x81]
test ecx, ecx
je 0x415879
push 0x607bb8
lea ecx, [ebp - 0x74]
call fcn.004025b0
jmp 0x4158dd
push str.PkgDir
mov edx, dword [ebp - 0x7c]
mov eax, dword [edx]
push eax
lea ecx, [ebp - 0x90]
call fcn.004020c0
mov dword [ebp - 0x8c], eax
mov ecx, dword [ebp - 0x8c]
push ecx
call fcn.00402670
add esp, 8
mov byte [ebp - 0x7d], al
lea ecx, [ebp - 0x90]
call fcn.004023e0
movzx edx, byte [ebp - 0x7d]
test edx, edx
je 0x4158c9
push 0x607bb4
lea ecx, [ebp - 0x74]
call fcn.004025b0
jmp 0x4158dd
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x74]
call fcn.004023e0
jmp 0x4157d4
mov eax, dword [ebp - 0x7c]
cmp dword [eax + 8], 0
jne 0x41592a
push 0x104
lea ecx, [ebp - 0x74]
call fcn.00405e30
mov dword [ebp - 0x94], eax
mov ecx, dword [ebp - 0x7c]
mov edx, dword [ecx + 4]
mov dword [ebp - 0x98], edx
push 0x104
mov eax, dword [ebp - 0x94]
push eax
mov ecx, dword [ebp - 0x98]
push ecx
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
push 0xffffffffffffffff
lea ecx, [ebp - 0x74]
call fcn.004094e0
jmp 0x41596d
push 0x104
lea ecx, [ebp - 0x74]
call fcn.00405e30
mov dword [ebp - 0x9c], eax
mov edx, dword [ebp - 0x7c]
mov eax, dword [edx + 8]
mov dword [ebp - 0xa0], eax
mov ecx, dword [ebp - 0x9c]
push ecx
push 0
push 0
mov edx, dword [ebp - 0xa0]
push edx
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
push 0xffffffffffffffff
lea ecx, [ebp - 0x74]
call fcn.004094e0
push 0x5ac904
lea ecx, [ebp - 0x74]
call fcn.0040a7f0
lea ecx, [ebp - 0x74]
call fcn.0040a530
push 0x5ac908
lea eax, [ebp - 0x74]
push eax
call fcn.004026d0
add esp, 8
movzx ecx, al
test ecx, ecx
je 0x415a4b
push 0x5ac90c
lea edx, [ebp - 0x74]
push edx
lea eax, [ebp - 0xac]
push eax
call fcn.00402870
add esp, 0xc
mov dword [ebp - 0xa4], eax
mov ecx, dword [ebp - 0xa4]
mov dword [ebp - 0xa8], ecx
mov byte [ebp - 4], 1
mov ecx, dword [ebp - 0xa8]
call fcn.00402790
push eax
lea ecx, [ebp - 0x28]
call fcn.00414820
mov byte [ebp - 4], 3
lea ecx, [ebp - 0xac]
call fcn.004023e0
mov edx, dword [ebp - 0x78]
add edx, 0x1c
mov dword [ebp - 0xb8], edx
lea eax, [ebp - 0x28]
push eax
mov ecx, dword [ebp - 0x7c]
push ecx
lea ecx, [ebp - 0x70]
call fcn.00411b70
mov dword [ebp - 0xb0], eax
mov edx, dword [ebp - 0xb0]
mov dword [ebp - 0xb4], edx
mov byte [ebp - 4], 4
mov eax, dword [ebp - 0xb4]
push eax
mov ecx, dword [ebp - 0xb8]
call fcn.00416f70
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x70]
call fcn.00414d70
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x28]
call fcn.00414d50
mov ecx, dword [ebp - 0x7c]
cmp dword [ecx + 8], 0xffffffff
je 0x415a8d
mov edx, dword [ebp - 0x78]
add edx, 0x28
mov dword [ebp - 0xbc], edx
mov eax, dword [ebp - 0x7c]
mov ecx, dword [eax]
push ecx
lea ecx, [ebp - 0x40]
call fcn.00414820
mov byte [ebp - 4], 5
lea edx, [ebp - 0x40]
push edx
mov ecx, dword [ebp - 0xbc]
call fcn.00416fa0
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x40]
call fcn.00414d50
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x74]
call fcn.004023e0
jmp 0x4157d4
mov eax, dword [ebp - 0x78]
add eax, 0x28
mov dword [ebp - 0xc0], eax
lea ecx, [ebp - 0x120]
push ecx
mov ecx, dword [ebp - 0xc0]
call fcn.00416d00
mov edx, dword [eax]
mov dword [ebp - 0xc8], edx
mov eax, dword [ebp - 0x78]
add eax, 0x28
mov dword [ebp - 0xc4], eax
lea ecx, [ebp - 0x134]
push ecx
mov ecx, dword [ebp - 0xc4]
call fcn.00416af0
mov edx, dword [eax]
mov dword [ebp - 0xcc], edx
mov eax, dword [ebp - 0xc8]
push eax
mov ecx, dword [ebp - 0xcc]
push ecx
call fcn.004143b0
add esp, 8
mov edx, dword [ebp - 0x78]
add edx, 0x28
mov dword [ebp - 0xf4], edx
mov eax, dword [ebp - 0x78]
add eax, 0x28
mov dword [ebp - 0xd0], eax
lea ecx, [ebp - 0x138]
push ecx
mov ecx, dword [ebp - 0xd0]
call fcn.00416d00
mov edx, dword [eax]
mov dword [ebp - 0xd4], edx
mov eax, dword [ebp - 0xd4]
mov dword [ebp - 0xec], eax
mov ecx, dword [ebp - 0x78]
add ecx, 0x28
mov dword [ebp - 0xd8], ecx
lea edx, [ebp - 0x11c]
push edx
mov ecx, dword [ebp - 0xd8]
call fcn.00416d00
mov eax, dword [eax]
mov dword [ebp - 0xe0], eax
mov ecx, dword [ebp - 0x78]
add ecx, 0x28
mov dword [ebp - 0xdc], ecx
lea edx, [ebp - 0x13c]
push edx
mov ecx, dword [ebp - 0xdc]
call fcn.00416af0
mov eax, dword [eax]
mov dword [ebp - 0xe4], eax
mov ecx, dword [ebp - 0xe0]
push ecx
mov edx, dword [ebp - 0xe4]
push edx
lea eax, [ebp - 0x124]
push eax
call fcn.004144d0
add esp, 0xc
mov ecx, dword [eax]
mov dword [ebp - 0xe8], ecx
mov edx, dword [ebp - 0xe8]
mov dword [ebp - 0xf0], edx
mov eax, dword [ebp - 0xec]
push eax
mov ecx, dword [ebp - 0xf0]
push ecx
lea edx, [ebp - 0x128]
push edx
mov ecx, dword [ebp - 0xf4]
call fcn.00416d40
xor eax, eax
mov byte [ebp - 0x7e], al
mov cl, byte [ebp - 0x7e]
mov byte [ebp - 0x7f], cl
mov dl, byte [ebp - 0x7f]
mov byte [ebp - 0x80], dl
mov eax, dword [ebp - 0x78]
add eax, 0x1c
mov dword [ebp - 0xf8], eax
lea ecx, [ebp - 0x12c]
push ecx
mov ecx, dword [ebp - 0xf8]
call fcn.00416d00
mov edx, dword [eax]
mov dword [ebp - 0xfc], edx
mov eax, dword [ebp - 0xfc]
mov dword [ebp - 0x108], eax
mov ecx, dword [ebp - 0x78]
add ecx, 0x1c
mov dword [ebp - 0x100], ecx
lea edx, [ebp - 0x130]
push edx
mov ecx, dword [ebp - 0x100]
call fcn.00416af0
mov eax, dword [eax]
mov dword [ebp - 0x110], eax
mov ecx, dword [ebp - 0x110]
mov dword [ebp - 0x10c], ecx
movzx edx, byte [ebp - 0x80]
push edx
mov eax, dword [ebp - 0x108]
push eax
mov ecx, dword [ebp - 0x10c]
push ecx
call fcn.00414340
add esp, 0xc
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0056a45e
mov esp, ebp
pop ebp
ret