Function at 0x401570
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xfffffffffffffffe
push 0x41bd00
push 0x403260
mov eax, dword fs:[0]
push eax
sub esp, 8
mov eax, 0x10f8
call fcn.00402690
mov eax, dword [0x41d014]
xor dword [ebp - 8], eax
xor eax, ebp
mov dword [ebp - 0x1c], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0x10]
mov dword fs:[0], eax
mov dword [ebp - 0x18], esp
mov esi, dword [ebp + 0x10]
push 0x20a
push 0
lea eax, [ebp - 0x68c]
push eax
call fcn.004033c0
push 0x20a
push 0
lea eax, [ebp - 0x898]
push eax
call fcn.004033c0
push 0x20a
push 0
lea eax, [ebp - 0x278]
push eax
call fcn.004033c0
push 0x802
push 0
lea eax, [ebp - 0x109c]
push eax
call fcn.004033c0
add esp, 0x30
mov dword [ebp - 0x10b8], 0
mov dword [ebp - 0x1100], 0
mov dword [ebp - 0x10d8], 0
mov dword [ebp - 0x10dc], 0
mov dword [ebp - 0x10e4], 0
mov dword [ebp - 0x10e8], 0
mov dword [ebp - 0x10e0], 0
mov dword [ebp - 0x10ec], 0
mov dword [ebp - 0x10f0], 0
mov dword [ebp - 0x10f4], 0
mov dword [ebp - 0x10f8], 0
mov dword [ebp - 0x10fc], 0
mov dword [0x41e614], 0
mov dword [0x41e610], 0
lea eax, [ebp - 0x68c]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
push 0x104
push 0x41d8c0
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea eax, [ebp - 0x110c]
push eax
lea eax, [ebp - 0x1104]
push eax
lea eax, [ebp - 0x1110]
push eax
push 0x41d8c0
call fcn.004022f0
add esp, 0x10
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
push dword [ebp - 0x1104]
lea eax, [ebp - 0x68c]
push eax
push str._s_s_X.log
push 0x104
lea eax, [ebp - 0x898]
push eax
call fcn.00401530
lea eax, [ebp - 0x898]
push eax
call fcn.00402360
push esi
call fcn.004041e0
add esp, 0x20
mov esi, eax
mov dword [ebp - 0x1108], esi
test esi, esi
jne 0x401727
lea edi, [eax + 0x57]
jmp 0x401ddd
push esi
push str.Command_Line:__s_n
call fcn.00401ef0
lea eax, [ebp - 0x10d8]
push eax
push esi
push 0x41d8c0
call fcn.004021d0
add esp, 0x14
mov ecx, eax
mov dword [ebp - 0x1100], ecx
mov eax, dword [ebp - 0x10d8]
mov dword [ebp - 0x10cc], eax
mov dword [ebp - 0x10d0], 0
xor edi, edi
mov dword [ebp - 0x10b4], edi
mov dword [ebp - 0x10d4], edi
cmp eax, 1
jle 0x401a48
mov dword [ebp - 0x10bc], 2
lea esi, [ecx + 8]
dec eax
mov dword [ebp - 0x10c0], eax
push 0x415190
push dword [esi - 4]
call fcn.00402000
add esp, 8
test eax, eax
je 0x4017db
mov eax, dword [ebp - 0x10bc]
cmp eax, dword [ebp - 0x10cc]
jge 0x4017c9
mov eax, dword [esi]
cmp word [eax], 0
je 0x4017c9
push eax
call fcn.004041e0
add esp, 4
mov dword [ebp - 0x10d4], eax
mov eax, dword [esi]
xor ecx, ecx
mov word [eax], cx
mov eax, dword [esi - 4]
mov word [eax], cx
jmp 0x401a32
push 0x415198
push dword [esi - 4]
call fcn.00402000
add esp, 8
test eax, eax
je 0x401826
mov eax, dword [ebp - 0x10bc]
cmp eax, dword [ebp - 0x10cc]
jge 0x401814
mov eax, dword [esi]
cmp word [eax], 0
je 0x401814
push eax
call fcn.004066ff
add esp, 4
mov dword [ebp - 0x10d0], eax
mov eax, dword [esi]
xor ecx, ecx
mov word [eax], cx
mov eax, dword [esi - 4]
mov word [eax], cx
jmp 0x401a32
push 0x4151a0
push dword [esi - 4]
call fcn.00402000
add esp, 8
test eax, eax
je 0x401a32
mov eax, dword [ebp - 0x10bc]
inc eax
cmp eax, dword [ebp - 0x10cc]
jge 0x401a32
mov eax, dword [esi]
cmp word [eax], 0
je 0x401a32
mov eax, dword [esi + 4]
cmp word [eax], 0
je 0x401a32
mov dword [ebp - 0x10c8], 0
mov dword [ebp - 0x10c4], 0
push dword [ebp - 0x10d0]
push 0
push 0x40
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov edi, eax
test edi, edi
je 0x401949
push 2
push 1
push 0
lea eax, [ebp - 0x10c8]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
push dword [esi]
call fcn.004066ff
add esp, 4
push eax
push edi
call dword [sym.imp.KERNEL32.dll_DuplicateHandle]
test eax, eax
jne 0x4018e8
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10b4], eax
push eax
push edi
push dword [esi]
call fcn.004066ff
add esp, 4
push eax
push str.Duplicating_handle__d_from_0x_08X_failed._GetLastError____4dl_n
call fcn.00401ef0
add esp, 0x10
push 2
push 1
push 0
lea eax, [ebp - 0x10c4]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
push dword [esi + 4]
call fcn.004066ff
add esp, 4
push eax
push edi
call dword [sym.imp.KERNEL32.dll_DuplicateHandle]
test eax, eax
jne 0x40193a
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10b4], eax
push eax
push edi
push dword [esi + 4]
call fcn.004066ff
add esp, 4
push eax
push str.Duplicating_handle__d_from_0x_08X_failed._GetLastError____4dl_n
call fcn.00401ef0
add esp, 0x10
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edi, dword [ebp - 0x10b4]
jmp 0x40196b
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
mov dword [ebp - 0x10b4], edi
push edi
push dword [ebp - 0x10d0]
push str.Opening_parent_process_pid_d_failed._GetLastError____4dl_n
call fcn.00401ef0
add esp, 0xc
test edi, edi
jne 0x401a32
push dword [ebp - 0x10c8]
call dword [sym.imp.KERNEL32.dll_GetFileType]
cmp eax, 3
jne 0x4019ed
push dword [ebp - 0x10c4]
call dword [sym.imp.KERNEL32.dll_GetFileType]
cmp eax, 3
jne 0x4019ed
mov eax, dword [ebp - 0x10c8]
mov dword [0x41e614], eax
mov eax, dword [ebp - 0x10c4]
mov dword [0x41e610], eax
mov eax, dword [esi - 4]
xor ecx, ecx
mov word [eax], cx
mov eax, dword [esi]
mov word [eax], cx
mov eax, dword [esi + 4]
mov word [eax], cx
test edi, edi
jne 0x401a32
push dword [ebp - 0x10d4]
push ecx
push 2
call dword [sym.imp.KERNEL32.dll_OpenEventW]
mov edi, eax
test edi, edi
je 0x401a10
push edi
call dword [sym.imp.KERNEL32.dll_SetEvent]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edi, dword [ebp - 0x10b4]
jmp 0x401a32
push dword [ebp - 0x10c4]
push dword [ebp - 0x10c8]
push str.Invalid_handles__d_and_possibly__d_n
call fcn.00401ef0
mov edi, 1
mov dword [ebp - 0x10b4], edi
jmp 0x401a2f
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
mov dword [ebp - 0x10b4], edi
push edi
push dword [ebp - 0x10d4]
push str.Opening_event__s_failed._GetLastError____4dl_n
call fcn.00401ef0
add esp, 0xc
inc dword [ebp - 0x10bc]
add esi, 4
sub dword [ebp - 0x10c0], 1
jne 0x401790
test edi, edi
jne 0x401dd8
call fcn.00402410
test eax, eax
jne 0x401aea
push str.SetDefaultDllDirectories_is_not_available._n
call fcn.00401ef0
push str.DWMAPI.DLL
call fcn.00402040
mov dword [ebp - 0x10e0], eax
push str.CRYPTBASE.DLL
call fcn.00402040
mov dword [ebp - 0x10e4], eax
push str.CRYPTSP.DLL
call fcn.00402040
mov dword [ebp - 0x10e8], eax
push str.MsiMsg.dll
call fcn.00402040
mov dword [ebp - 0x10ec], eax
push str.netutils.dll
call fcn.00402040
mov dword [ebp - 0x10f0], eax
push str.srvcli.dll
call fcn.00402040
mov dword [ebp - 0x10f4], eax
push str.wkscli.dll
call fcn.00402040
mov dword [ebp - 0x10f8], eax
push str.RpcRtRemote.dll
call fcn.00402040
add esp, 0x24
mov dword [ebp - 0x10fc], eax
push str.Msi.dll
call fcn.00402040
add esp, 4
mov edi, eax
mov dword [ebp - 0x10dc], edi
test edi, edi
je 0x401b3f
push str.MsiSetInternalUI
push edi
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
call esi
mov dword [0x41e624], eax
push str.MsiInstallProductW
push edi
call esi
mov dword [0x41e61c], eax
push str.MsiSetExternalUIW
push edi
call esi
mov dword [0x41e620], eax
push str.MsiConfigureProductExW
push edi
call esi
mov dword [0x41e618], eax
jmp 0x401b44
mov eax, dword [0x41e618]
cmp dword [0x41e61c], 0
je 0x401dc4
cmp dword [0x41e620], 0
je 0x401dc4
cmp dword [0x41e624], 0
je 0x401dc4
test eax, eax
je 0x401dc4
xor edi, edi
cmp dword [0x41e614], edi
je 0x401de3
cmp dword [0x41e610], edi
je 0x401de3
xorps xmm0, xmm0
movups xmmword [ebp - 0x10b0], xmm0
mov dword [ebp - 0x10a0], edi
nop dword [eax]
lea eax, [ebp - 0x10b0]
push eax
lea eax, [ebp - 0x109c]
push eax
lea eax, [ebp - 0x278]
push eax
call fcn.00401000
add esp, 0xc
test eax, eax
je 0x401de3
push 0x208
push 0
lea eax, [ebp - 0x480]
push eax
call fcn.004033c0
lea eax, [ebp - 0x278]
push eax
call fcn.00402460
add esp, 0x10
test eax, eax
je 0x401c80
push 0x4e
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.004033c0
push 0x27
lea eax, [ebp - 0x6c]
push eax
lea eax, [ebp - 0x278]
push eax
call fcn.00401f20
add esp, 0x18
test eax, eax
je 0x401c65
lea eax, [ebp - 0x109c]
push eax
lea eax, [ebp - 0x6c]
push eax
push str.Calling_MsiConfigureProduct___s___INSTALLLEVEL_DEFAULT__INSTALLSTATE_ABSENT____s___n
call fcn.00401ef0
add esp, 0xc
push 0
push 2
call dword [0x41e624]
push 0
push 0x7fdf
push 0x4011e0
call dword [0x41e620]
lea eax, [ebp - 0x109c]
push eax
push 2
push 0
lea eax, [ebp - 0x6c]
push eax
call dword [0x41e618]
mov esi, eax
jmp 0x401d5b
lea eax, [ebp - 0x278]
push eax
push str.No_installed_products_found_for_upgrade_code___s__n
call fcn.00401ef0
add esp, 8
xor esi, esi
jmp 0x401d5b
lea eax, [ebp - 0x10c0]
push eax
lea eax, [ebp - 0x10b0]
push eax
lea eax, [ebp - 0x278]
push eax
call fcn.00402540
add esp, 0xc
test eax, eax
je 0x401cf0
lea eax, [ebp - 0x109c]
push eax
lea eax, [ebp - 0x278]
push eax
push str.Calling_MsiInstallProduct___s_____s___n
call fcn.00401ef0
add esp, 0xc
push 0
push 2
call dword [0x41e624]
push 0
push 0x7fdf
push 0x4011e0
call dword [0x41e620]
lea eax, [ebp - 0x109c]
push eax
lea eax, [ebp - 0x278]
push eax
call dword [0x41e61c]
mov esi, eax
jmp 0x401d5b
push dword [ebp - 0x10c0]
lea eax, [ebp - 0x278]
push eax
push str.Could_not_validate___s______lu_n
call fcn.00401ef0
push dword [ebp - 0x10c0]
push 2
push str._u__ld_
lea eax, [ebp - 0x480]
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x1c
lea ecx, [ebp - 0x480]
lea edx, [ecx + 2]
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x401d30
sub ecx, edx
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
lea eax, [ebp - 0x480]
push eax
call fcn.004013f0
add esp, 8
mov esi, 1
push esi
push 1
push str._u__ld_
lea eax, [ebp - 0x480]
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
lea ecx, [ebp - 0x480]
lea edx, [ecx + 2]
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x401d80
sub ecx, edx
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
lea eax, [ebp - 0x480]
push eax
call fcn.004013f0
add esp, 8
xor edi, edi
cmp esi, 0xbc2
cmovne edi, esi
mov dword [ebp - 0x10b8], edi
cmp eax, 0x103
jne 0x401ba0
jmp 0x401ddd
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Could_not_load_Msi.dll_functions:__d_n
call fcn.00401ef0
add esp, 8
mov edi, 1
mov dword [ebp - 0x10b8], edi
push edi
push str._nExiting_with_code:__d_n
call fcn.00401ef0
add esp, 8
mov dword [ebp - 4], 0
push dword [0x41e614]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [0x41e610]
call esi
mov dword [ebp - 4], 0xfffffffe
jmp 0x401e2d
mov eax, dword [ebp - 0x10dc]
mov esi, dword [sym.imp.KERNEL32.dll_FreeLibrary]
test eax, eax
je 0x401e40
push eax
call esi
mov eax, dword [ebp - 0x10e0]
test eax, eax
je 0x401e4d
push eax
call esi
mov eax, dword [ebp - 0x10e4]
test eax, eax
je 0x401e5a
push eax
call esi
mov eax, dword [ebp - 0x10e8]
test eax, eax
je 0x401e67
push eax
call esi
mov eax, dword [ebp - 0x10ec]
test eax, eax
je 0x401e74
push eax
call esi
mov eax, dword [ebp - 0x10f0]
test eax, eax
je 0x401e81
push eax
call esi
mov eax, dword [ebp - 0x10f4]
test eax, eax
je 0x401e8e
push eax
call esi
mov eax, dword [ebp - 0x10f8]
test eax, eax
je 0x401e9b
push eax
call esi
mov eax, dword [ebp - 0x10fc]
test eax, eax
je 0x401ea8
push eax
call esi
push dword [ebp - 0x1100]
call dword [sym.imp.KERNEL32.dll_LocalFree]
push dword [ebp - 0x1108]
call fcn.00406b65
push 1
call fcn.00404307
push eax
call fcn.00406799
add esp, 0xc
mov eax, edi
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x1c]
xor ecx, ebp
call fcn.00402678
mov esp, ebp
pop ebp
ret 0x10