Function at 0x401540
Capabilities:
Check mutex on windows
Get common file path

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov eax, 0x14094
call fcn.004372f0
mov eax, dword [0x45407c]
xor eax, esp
mov dword [esp + 0x14090], eax
mov eax, dword [ebp + 0xc]
push ebx
push esi
push edi
mov edi, dword [ebp + 0x10]
mov dword [esp + 0x48], eax
mov eax, edi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x401570
sub eax, edx
sar eax, 1
je 0x401669
mov ecx, edi
mov eax, str._asService
lea esp, [esp]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x4015b6
test dx, dx
je 0x4015b2
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x4015b6
add eax, 4
add ecx, 4
test dx, dx
jne 0x401590
xor eax, eax
jmp 0x4015bb
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x401669
lea ecx, [esp + 0x104]
push ecx
push 0x104
mov dword [esp + 0x18], vtable.ZonaCommandFactory.0
call dword [sym.imp.KERNEL32.DLL_GetTempPathW]
mov esi, dword [sym.imp.USER32.dll_wsprintfW]
push str.ZonaInstall.log
lea edx, [esp + 0x108]
push edx
mov eax, edx
push 0x446ba4
push eax
call esi
push 0x446bb0
lea ecx, [esp + 0x320]
push 0x446b64
push ecx
call esi
add esp, 0x1c
push 0x446608
lea edx, [esp + 0x310]
push 0x446b64
push edx
call esi
add esp, 0xc
push 0x3e8
call dword [sym.imp.KERNEL32.DLL_Sleep]
lea eax, [esp + 0x100]
lea ecx, [esp + 0x10]
lea esi, [esp + 0x30]
mov dword [esp + 0x34], eax
mov dword [esp + 0x38], ecx
call fcn.004038e0
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x14090]
xor ecx, esp
call fcn.004276fb
mov esp, ebp
pop ebp
ret 0x10
push str.zonaWeb
push 0
push 0
call dword [sym.imp.KERNEL32.DLL_CreateMutexW]
mov dword [esp + 0x18], eax
call dword [sym.imp.KERNEL32.DLL_GetLastError]
mov ebx, eax
call fcn.00401be0
mov esi, eax
mov dword [esp + 0x10], esi
cmp ebx, 0xb7
jne 0x40173b
xor ecx, ecx
mov eax, 0x446622
movzx edx, word [eax - 2]
mov edi, ecx
shl edi, 5
sub edi, ecx
add edx, edi
mov ecx, edx
shl ecx, 5
sub ecx, edx
movzx edx, word [eax]
add ecx, edx
mov edx, ecx
shl edx, 5
sub edx, ecx
movzx ecx, word [eax + 2]
add edx, ecx
mov ecx, edx
shl ecx, 5
sub ecx, edx
movzx edx, word [eax + 4]
add ecx, edx
mov edx, ecx
shl edx, 5
sub edx, ecx
movzx ecx, word [eax + 6]
add eax, 0xa
add ecx, edx
cmp eax, str.___START___
jl 0x4016a2
lea edx, [esp + 0x10]
mov eax, esi
mov dword [esp + 0x10], ecx
call fcn.00405250
mov eax, dword [eax]
test eax, eax
jne 0x401706
mov eax, str.INSTALLER_RUNNING_ALREADY
push 0x10
push 0
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
mov eax, dword [esp + 0x18]
test eax, eax
je 0x401722
push eax
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x14090]
xor ecx, esp
call fcn.004276fb
mov esp, ebp
pop ebp
ret 0x10
push 0
call dword [sym.imp.ole32.dll_CoInitialize]
lea edx, [esp + 0x37c]
push edx
push 0x104
call dword [sym.imp.KERNEL32.DLL_GetTempPathW]
mov ebx, dword [sym.imp.USER32.dll_wsprintfW]
push str.ZonaInstall.log
lea eax, [esp + 0x380]
push eax
mov ecx, eax
push 0x446ba4
push ecx
call ebx
push 0x446bb0
lea edx, [esp + 0x598]
push 0x446b64
push edx
call ebx
add esp, 0x1c
push str.___START___
push str.INFO
lea ecx, [esp + 0x380]
call fcn.00404920
mov eax, edi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4017a5
sub eax, edx
sar eax, 1
je 0x4017de
push str.Start_args:
push str.INFO
lea ecx, [esp + 0x380]
call fcn.00404920
push edi
push str.INFO
lea ecx, [esp + 0x380]
call fcn.00404920
lea eax, [esp + 0x378]
push eax
push edi
lea ecx, [esp + 0x5d0]
push ecx
call fcn.00408c40
mov ebx, str._version
lea eax, [esp + 0x1e30]
mov dword [esp + 0x5c8], 0x4498cc
mov dword [esp + 0x14094], 0
call fcn.004045c0
test al, al
je 0x401838
lea edi, [esp + 0x5c8]
call fcn.00409790
mov edx, edi
push edx
call fcn.0040fd60
jmp 0x401713
lea ecx, [esp + 0x5c8]
call fcn.00410ca0
xor ebx, ebx
cmp word [esp + 0x1790], bx
jne 0x401895
push 0x104
lea eax, [esp + 0x1794]
push eax
lea ecx, [esp + 0x1590]
push ecx
call dword [sym.imp.KERNEL32.DLL_GetShortPathNameW]
test eax, eax
jne 0x401882
xor edx, edx
mov word [esp + 0x1790], dx
lea eax, [esp + 0x1588]
jmp 0x40189c
cmp word [esp + 0x1790], bx
jne 0x401895
lea eax, [esp + 0x1588]
jmp 0x40189c
lea eax, [esp + 0x1790]
push eax
mov edi, esi
lea ecx, [esp + 0x5cc]
call fcn.0040a020
add esp, 4
test al, al
jne 0x40191a
push 0x80000
call fcn.0042770a
add esp, 4
push ebx
mov edi, eax
push str.installCancel
push edi
lea ecx, [esp + 0x5d4]
xor eax, eax
push ecx
mov word [edi], ax
call fcn.00409da0
push edi
lea ebx, [esp + 0x5cc]
call fcn.0040a1b0
mov edx, ebx
push edx
call fcn.0040fd60
mov eax, dword [esp + 0x18]
test eax, eax
je 0x4018fe
push eax
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
mov eax, 1
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x14090]
xor ecx, esp
call fcn.004276fb
mov esp, ebp
pop ebp
ret 0x10
mov edx, dword [esp + 0x5c8]
lea eax, [esp + 0x5c8]
mov dword [esp + 0x20], eax
mov ecx, eax
mov eax, dword [edx + 0x20]
mov dword [esp + 0x1c], vtable.InstallScenario.0
mov dword [esp + 0x24], ebx
mov word [esp + 0x29], bx
mov byte [esp + 0x28], bl
mov dword [esp + 0x2c], ebx
call eax
test al, al
jne 0x40195c
lea eax, [esp + 0x5c8]
call fcn.0040a2c0
mov ebx, str._silent
lea eax, [esp + 0x1e30]
mov dword [esp + 0x1c], vtable.ZonaInstallScenario.0
call fcn.004045c0
test al, al
jne 0x401b2b
call fcn.00404b40
mov ecx, dword [eax]
mov dword [esp + 0x108], ecx
mov edx, dword [eax + 4]
mov dword [esp + 0x10c], edx
mov ecx, dword [eax + 8]
mov dword [esp + 0x110], ecx
mov edx, dword [eax + 0xc]
mov dword [esp + 0x114], edx
mov ecx, 0x93
lea esi, [esp + 0x378]
lea edi, [esp + 0x118]
rep movsd dword es:[edi], dword [esi]
mov esi, dword [esp + 0x10]
push esi
lea eax, [esp + 0x368]
push eax
call fcn.00401c70
mov cx, word [esi + 0x10]
mov edx, dword [ebp + 8]
mov eax, dword [esp + 0x48]
mov esi, dword [sym.imp.USER32.dll_GetSystemMetrics]
push 0x11
mov word [esp + 0x378], cx
mov dword [esp + 0x108], edx
mov dword [esp + 0x104], eax
call esi
push 0x10
mov edi, eax
call esi
mov ecx, eax
mov eax, edi
cdq
sub eax, edx
sar eax, 1
sub eax, 0xdf
push eax
mov eax, ecx
cdq
sub eax, edx
mov edx, eax
sar edx, 1
sub edx, 0xfa
lea eax, [esp + 0x104]
lea esi, [esp + 0xd8]
call fcn.00402900
call fcn.00402960
lea ecx, [esp + 0x5c8]
mov dword [esp + 0x58], ecx
lea edx, [esp + 0x100]
lea ecx, [esp + 0x30]
mov dword [esp + 0x5c], edx
lea eax, [esp + 0x364]
push ecx
lea edx, [esp + 0x20]
mov dword [esp + 0x38], eax
push edx
lea eax, [esp + 0x54]
lea edi, [esp + 0x5d0]
lea esi, [esp + 0x68]
mov dword [esp + 0x54], vtable.SimpleWizardHeader.0
mov dword [esp + 0x38], vtable.LicenseResourceProviderImpl.0
call fcn.0040ddb0
lea eax, [esp + 0xd4]
mov ebx, vtable.ZonaInstallerWizard.1.0
mov edi, vtable.ZonaInstallerWizard.2.0
mov esi, vtable.ZonaInstallerWizard.3.0
push eax
lea ecx, [esp + 0x64]
mov dword [esp + 0x64], vtable.ZonaInstallerWizard.0
mov dword [esp + 0x68], ebx
mov dword [esp + 0xa0], edi
mov dword [esp + 0xb0], esi
call fcn.004023a0
lea ecx, [esp + 0x9c]
mov dword [esp + 0x24], ecx
lea eax, [esp + 0x64]
lea ecx, [esp + 0xd4]
call fcn.004029f0
mov dword [esp + 0x60], vtable.ZonaInstallerWizard.0
mov dword [esp + 0x64], ebx
mov dword [esp + 0xac], esi
lea esi, [esp + 0x60]
mov dword [esp + 0x9c], edi
call fcn.0040de60
mov eax, dword [esp + 0x368]
mov ecx, dword [eax]
push eax
push ecx
lea esi, [esp + 0x4c]
lea eax, [esp + 0x36c]
call fcn.00401d40
mov edx, dword [esp + 0x368]
push edx
call fcn.00427715
add esp, 4
jmp 0x401b5a
lea eax, [esp + 0x5c8]
lea ecx, [esp + 0x1c]
lea edx, [esp + 0x378]
lea esi, [esp + 0x30]
mov dword [esp + 0x30], vtable.SilentScenarioListener.0
mov dword [esp + 0x34], eax
mov dword [esp + 0x38], ecx
mov dword [esp + 0x3c], edx
call fcn.0040a680
lea eax, [esp + 0x5c8]
push eax
mov dword [esp + 0x20], vtable.InstallScenario.0
call fcn.0040fd60
mov eax, dword [esp + 0x18]
test eax, eax
je 0x401b7e
push eax
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
mov ecx, dword [esp + 0x1409c]
pop edi
pop esi
pop ebx
xor ecx, esp
or eax, 0xffffffff
call fcn.004276fb
mov esp, ebp
pop ebp
ret 0x10