[SetupInfo] Author = Matrix42 AG CreationDate = 17.07.2007 InventoryID = Description = Empirum Agent Installation Method = Scripted Tested on = XP, Win7, W2K3, W2K8, Win8 Dependencies = Command line options = /S2 Last Change = 10.03.2015 Build = [VarDefInfo] [Setup] Version=14.2 ShowCaption=1 BlockInput=0 Platform=* [Requirements] [Application] ProductName=Agent Version=16.0 Revision=0 DeveloperName=Matrix42 SetupName=%ProductName% %Version% %SetupWizard% Text1="%ProductName%", Arial, 30, , FFFFFF, 3%, 5% , LEFT BOLD Text2="Matrix42 Client Management 2015", Arial, 24, , FFFFFF, 3%, , LEFT BOLD ITALIC Text3="©2000 - 2015 Matrix42 AG. All rights reserved.\nMatrix42, Empirum and Matrix42 logo are\nregistered trademarks of Matrix42 AG, Germany.\n\nVisit http://www.matrix42.com for more information.", Arial, 12, , FFFFFF, 3%, -15% , LEFT BackgroundColor=EFEFEF,000000 CopyDialogRect=0%, 0%, 100%, 100%, HCENTER VCENTER UserKeyName=%DeveloperName%\%ProductName% MachineKeyName=%DeveloperName%\%ProductName%\%Version% UninstallKeyName=%DeveloperName% %ProductName% %Version% UninstallDisplayName=%ProductName% %Version% UninstallString=%ReinstallString% /U ReinstallString="%CommonSetupDir%\Setup.exe" "%App%\%SetupInfDir%\Setup.inf" ReinstallMode=1 SrcDir=.. ApplicationDir=%System%\Empirum SetupInfDir=Install DataDir=%Personal% Prompts= AskUninstallOld=0 ShellLinks=1 CommonShellLinks=0 CreateUnresolvableShellLinks=1 UseStringSection=Strings:09 UseSysStringSection=SysStrings:09 DateWarning=1 SizeWarning=0 Reboot=0 PreventExternalReboot=1 StartServicesOnReboot=0 CallTimeOut=3600 AbortAfterCallTimeOut=1 DisableCancelButton=1 ShowEndMessage=1 EndMessage=%EndMessageDesc% Expand=0 [Strings:07] Disk1=Installationsmedium 1 EndMessageDesc=Die Installation wurde erfolgreich abgeschlossen! ErrorLogMessage=Die Installation/Deinstallation wurde mit einer Fehlermeldung abgebrochen! InstallationFor=Installation für: InstallerDesc=Dienstprogramm zum Installieren einzelner Komponenten. InstallerName=Installationsprogramm SetupWizard=Installations-Assistent Uninstallation=deinstallieren ErrorMessageVC=Installation Microsoft Visual C++ 2010 Runtime fehlgeschlagen! ErrorMessageDotNet=.NET FrameWork 4 Installation fehlgeschlagen! ErrorNoXMLfound=Keine AgentConfig.xml gefunden! AgentLanguage=de-DE ErrorMessageW2k3=Die Installation wurde abgebrochen!\n\nDie Systemvoraussetzung 'Windows 2003 Server mit SP2' ist nicht erfüllt! ErrorMessageXP=Die Installation wurde abgebrochen!\n\nDie Systemvoraussetzung 'Windows XP mit SP3' ist nicht erfüllt! ShutdownTextDesc=Zum Abschließen der Matrix42 Agent-Installation muß der Computer neu gestartet werden.\nSpeichern Sie Ihre Daten und schließen Sie alle offenen Anwendungen.\n\nKlicken Sie 'OK' um den Computer neu zu starten. ErrorInstallationSHI=Die Installation des Matrix42 Universal Agent Frameworks ist fehlgeschlagen! ErrorReinstallationSHI=Die Reinstallation des Matrix42 Universal Agent Frameworks ist fehlgeschlagen! ErrorStartingSHI=Matrix42 Universal Agent Framework nicht gestartet! ErrorUninstallationSHI=Deinstallation des Matrix42 Universal Agent Frameworks ist fehlgeschalgen! [Strings:09] Disk1=Installation media 1 EndMessageDesc=Installation was completed successfully! ErrorLogMessage=The installation/uninstallation aborted with an error message! InstallationFor=Installation for: InstallerDesc=Service program to install single components. InstallerName=Setup program SetupWizard=Installation Wizard Uninstallation=Uninstallation ErrorMessageDotNet=.NET FrameWork 4 Installation failed! ErrorMessageVC=Installation Microsoft Visual C++ 2010 Runtime failed! ErrorNoXMLfound=AgentConfig.xml not found! AgentLanguage=en-US ErrorMessageW2k3=The installaion is aborted!\n\nThe system requirement 'Windows 2003 Server with SP2' is not given! ErrorMessageXP=The installaion is aborted!\n\nThe system requirement 'Windows XP with SP3' is not given! ShutdownTextDesc=To complete the Matrix42 Advanced Agent installation you must restart your computer.\nSave your work and close all open applications.\n\nClick 'OK' to restart your computer. ErrorInstallationSHI=Installation of Matrix42 Universal Agent Framework failed! ErrorReinstallationSHI=Reinstallation of Matrix42 Universal Agent Framework failed! ErrorStartingSHI=Matrix42 Universal Agent Framework not started! ErrorUninstallationSHI=Deinstallation of Matrix42 Universal Agent Framework failed! [SysStrings:07] TLACode=deu Users=Benutzer [SysStrings:09] TLACode=enu Users=Users [SysStrings:0c] TLACode=fra [SysStrings:13] TLACode=nld [SysStrings:10] TLACode=ita [SysStrings:0a] TLACode=esn [SysStrings:19] TLACode=rus [SysStrings:11] TLACode=jpn [SysStrings:16,04] TLACode=ptb [SysStrings:04,08] TLACode=chs [Environment] CommonSetupDir=%CommonFilesDir%\Setup%SetupBits% V_MachineValuesPath=\\%EmpirumServer%\Values$\MachineValues\%DomainName% V_UserValuesPath=%HKLM,"Software\Matrix42\Software Depot","HomeServer"%\Values$\UserValues\%UserDomain% AGENT_TEMPLATE=%%%V_MachineValuesPath%\%ComputerName%.ini,%ComputerName%,AGENT_TEMPLATE%% CMDConfigLogfile=%Temp%\CONFIG_%ProductName%.%Version%.%Revision%.txt Install_SHI_LogFile=%Temp%\Install_SHI_%ProductName%.%Version%.%Revision%.log MSI_SHI_LogFile=%Temp%\%V_PATH_MSI%\MSI_SHI_%ProductName%.%Version%.%Revision%.log V_PATH_MSI=Matrix42\ServiceHostingFramework ReInstSuccessMessage1031=Die Konfiguration wurde erfolgreich abgeschlossen. ReInstSuccessMessage1031_1=Die Konfiguration wurde abgeschlossen. ReInstSuccessMessage1033=Configuration completed successfully. ReInstSuccessMessage1033_1=Configuration completed. [Disks] 1=%Disk1% [Icons] Product = %ProductName%.ico, 0, 000000, ICON [Options] Installer = %InstallerName%, COPYALWAYS, Installer, "%InstallerDesc%" Product = %ProductName%, COPYALWAYS, Product, "%ProductDesc%" [Installer] Del "%CommonSetupDir%\Setup.exe" 1:Install\Setup.exe, %CommonSetupDir%, OPTIONAL USEFILENAME DIRECTORY NOSIZEWARNING SETUP, 0 1:..\..\..\..\User\Setup.exe, %CommonSetupDir%, OPTIONAL USEFILENAME DIRECTORY NOSIZEWARNING SETUP, 0 1:..\..\..\..\User\SetupDeu.chm, %CommonSetupDir%, OPTIONAL USEFILENAME DIRECTORY NOSIZEWARNING SETUP, 0 1:..\..\..\..\User\SetupEnu.chm, %CommonSetupDir%, OPTIONAL USEFILENAME DIRECTORY NOSIZEWARNING SETUP, 0 1:%SetupInfDir%\Setup.inf, , NORMAL , 0 1:%Temp%\Setup64.exe, %CommonSetupDir%\Setup.exe, OPTIONAL NOSIZEWARNING SETUP ALWAYS WINDOWS64, 0 [Setx64] Set ARCHITECTURE=\x64 Set WICARCHITECTURE=x64 Set SYSTEMDIR=SysWOW64 Set X64REGISTRY=\WOW6432Node Set MSI_ARCHITECTURE=.x64 [Setx86] Set ARCHITECTURE= Set WICARCHITECTURE=x86 Set SYSTEMDIR=System32 Set X64REGISTRY= Set MSI_ARCHITECTURE= [Product] AddMeter -1 If %PROCESSOR_ARCHITECTURE% == "AMD64" Then "Setx64" Else "Setx86" EndIf #Set:Product #Set:CheckDotNetRequirements #Set:VC10032, DONTDELETE WINDOWS32 #Set:VC10064, DONTDELETE WINDOWS64 #Set:DotNet, DONTDELETE #Set:RootsUpd, DONTDELETE #Reg:Productx86, DONTDELETE WINDOWS32 #Reg:Productx64, DONTDELETE WINDOWS64 #Security:Productx86, DONTDELETE WINDOWS32 #Security:Productx64, DONTDELETE WINDOWS64 #Reg:DeleteRunKeyx86, DELETE WINDOWS32 #Reg:DeleteRunKeyx64, DELETE WINDOWS64 #Set:AgentCopy #Set:Autoexec.Bat:Server #Set:InstallAgent, DONTDELETE #InstallW8Notification, DONTDELETE #Set:OldRevokeCounter, DONTDELETE #Set:SHI, DONTDELETE #Set:UninstallAgent, DELETE #UninstallW8Notification, DELETE #Set:UnInstallLegacyAgent #Set:UninstallSHI, DELETE [Autoexec.bat:Server] SET EmpirumServer=%EmpirumServer% [Set:Product] If DoesRegKeyExist ("HKLM,System\CurrentControlSet\Services\Eris,Start") == "1" Then "CheckInstallMethod" EndIf [Set:CheckDotNetRequirements] If %WindowsVersion% == "5.1" Then "CheckSP3" EndIf If %WindowsVersion% == "5.2" Then "CheckSP2" EndIf [CheckSP3] If %OS.ServicePackMajor% < "3" Then "ErrorXP" [CheckSP2] If %OS.ServicePackMajor% < "2" Then "ErrorW2k3" [ErrorW2k3] ErrorLogMsg %ErrorMessageW2k3% Abort %ErrorMessageW2k3% [ErrorXP] ErrorLogMsg %ErrorMessageXP% Abort %ErrorMessageXP% [Set:VC10032] If "%RemoteServer%" <> "" Then "GetVCRedist10032fromServer" EndIf Call "%SRC%\VCRedist100\vcredist_x86.exe" /q /norestart If %Errorlevel% == 3010 Then "RebootRequired" EndIf If %Errorlevel% <> "0" Then "ErrorVC" EndIf [Set:VC10064] If "%RemoteServer%" <> "" Then "GetVCRedist10064fromServer" EndIf Call "%SRC%\VCRedist100\vcredist_x64.exe" /q /norestart If %Errorlevel% == 3010 Then "RebootRequired" EndIf If %Errorlevel% <> "0" Then "ErrorVC" EndIf #Set:VC10032 [GetVCRedist10032fromServer] 1:"\\%RemoteServer%\Configurator$\Packages\Matrix42\EmpirumAgent\%Version%\VCRedist100\vcredist_x86.exe", %Src%\VCRedist100\ , USEFILENAME, 5000 [GetVCRedist10064fromServer] 1:"\\%RemoteServer%\Configurator$\Packages\Matrix42\EmpirumAgent\%Version%\VCRedist100\vcredist_x64.exe", %Src%\VCRedist100\ , USEFILENAME, 5000 [ErrorVC] Echo %ErrorMessageVC% %ErrorLevel% ErrorLogMsg %ErrorMessageVC% %ErrorLevel% Abort %ErrorMessageVC% %ErrorLevel% [RebootRequired] SetReboot 1 Set V_FirstStartAfterReboot=1 Set Errorlevel=0 [Set:DotNet] If GetDotNetPatchLevel ("4.0 Full") == "-1" then "InstallDotNet4" EndIf [InstallDotNet4] If "%RemoteServer%" <> "" Then "GetDotNetfromServer" EndIf If %WindowsVersion% == "5.2" Then "InstallWIC" Endif Call "%Src%\dotnetfx\dotNetFx40_Full_x86_x64.exe" /q /norestart /lang:enu If DoesRegKeyExist ("HKLM,SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Full") == "0" Then "ErrorDotNet" EndIf If %Errorlevel% == "3010" | %Errorlevel% == "1641" Then "RebootRequired" EndIf [GetDotNetfromServer] 1:"\\%RemoteServer%\Configurator$\Packages\Matrix42\EmpirumAgent\%Version%\dotnetfx\dotNetFx40_Full_x86_x64.exe", %Src%\dotnetfx\ , USEFILENAME, 230000 [InstallWIC] If "%RemoteServer%" <> "" Then "GetWICfromServer" EndIf Call "%Src%\WIC\%WICARCHITECTURE%\wic_%WICARCHITECTURE%_%TLACode%.exe" /passive /quiet [GetWICfromServer] 1:"\\%RemoteServer%\Configurator$\Packages\Matrix42\EmpirumAgent\%Version%\WIC\%WICARCHITECTURE%\wic_%WICARCHITECTURE%_%TLACode%.exe", %Src%\WIC\%WICARCHITECTURE%\ , USEFILENAME, 230000 [ErrorDotNet] Echo %ErrorMessageDotNet% %ErrorLevel% ErrorLogMsg %ErrorMessageDotNet% %ErrorLevel% Abort %ErrorMessageDotNet% %ErrorLevel% [Set:RootsUpd] If %WindowsVersion% == "6.0" | %WindowsVersion% == "5.1" Then "InstallRootsUpd" EndIf [InstallRootsUpd] If "%RemoteServer%" <> "" Then "GetRootsUpdfromServer" EndIf Call "%Src%\RootsUpd\rootsupd.exe" /Q [GetRootsUpdfromServer] 1:"\\%RemoteServer%\Configurator$\Packages\Matrix42\EmpirumAgent\%Version%\RootsUpd\rootsupd.exe", %Src%\RootsUpd\ , USEFILENAME, 435732 [CheckEmpirumAgentTemplate] If DoesPathExist ("%WinDir%\Temp\EmpirumAgent_tmp") == "0" Then "NoCopyTemplate" EndIf [NoCopyTemplate] ReplaceEnv AGENT_TEMPLATE If %AGENT_TEMPLATE% == "" Then "CopyDefaultXML" Else "CopyTemplateXML" EndIf [CopyDefaultXML] If DoesFileExist ("%Src%\..\..\..\..\User\defaultAgentConfig.xml") == "0" Then "SFXCopyDefaultXML" Else "CopyDefaultXMLfromUserDir" Endif [CopyDefaultXMLfromUserDir] 1:..\..\..\..\User\defaultAgentConfig.xml, %System%\Empirum\AgentConfig.xml , ALWAYS, 0 [CopyTemplateXML] If DoesFileExist ("%Src%\..\..\..\..\User\%AGENT_TEMPLATE%.xml") == "0" Then "StopInstallation" Endif 1:..\..\..\..\User\%AGENT_TEMPLATE%.xml, %System%\Empirum\AgentConfig.xml , ALWAYS, 0 [SFXCopyDefaultXML] If DoesFileExist ("%Src%\Template_SFX\defaultAgentConfig.xml") == "0" Then "StopInstallation" Endif 1:Template_SFX\defaultAgentConfig.xml, %System%\Empirum\AgentConfig.xml , ALWAYS, 0 [StopInstallation] Echo %ErrorNoXMLfound% ErrorLogMsg %ErrorNoXMLfound% Abort %ErrorNoXMLfound% [Set:AgentCopy] Del %Windir%\%SYSTEMDIR%\Empirum\cygcrypto-0.9.8.dll Del %Windir%\%SYSTEMDIR%\Empirum\cygintl-3.dll Del %Windir%\%SYSTEMDIR%\Empirum\cygminires.dll Del %Windir%\%SYSTEMDIR%\Empirum\cygz.dll 1:Windows\System\Empirum\AgentConfig.xml, %System%\Empirum\ , USEFILENAME ALWAYS, 0 1:Windows\System\etc\fstab, %Windir%\%SYSTEMDIR%\etc\ , USEFILENAME, 112 1:Windows\System\Empirum\cyggcc_s-1.dll, %Windir%\%SYSTEMDIR%\Empirum\ , USEFILENAME, 1356545 1:Windows\System\Empirum\cygiconv-2.dll, %Windir%\%SYSTEMDIR%\Empirum\ , USEFILENAME, 969728 1:Windows\System\Empirum\cygwin1.dll, %Windir%\%SYSTEMDIR%\Empirum\ , USEFILENAME, 1875110 1:Windows\System\Empirum\EmpirumLib.dll, %System%\Empirum\ , USEFILENAME, 167936 1:Windows\System\Empirum\ERIS-Module-Service-Installer.dll, %System%\Empirum\ , USEFILENAME, 49152 1:Windows\System\Empirum\ERIS.exe, %System%\Empirum\ , USEFILENAME, 73728 1:Windows\System\Empirum\ERIS.exe.config, %System%\Empirum\ , USEFILENAME, 73728 1:Windows\System\Empirum\ERISLogonUI.exe, %System%\Empirum\ , USEFILENAME, 36864 1:Windows\System\Empirum\ERIS_Messaging.dll, %System%\Empirum\ , USEFILENAME, 495616 1:Windows\System\Empirum\ERIS_UI.exe, %System%\Empirum\ , USEFILENAME, 491520 1:Windows\System\Empirum\ERIS_UI_TransportActivity.dll, %System%\Empirum\ , USEFILENAME, 36864 1:Windows\System\Empirum\Glossary.xml, %System%\Empirum\ , USEFILENAME, 79596 1:Windows\System\Empirum\rsync.exe, %Windir%\%SYSTEMDIR%\Empirum\ , USEFILENAME, 283136 1:Windows\System\Empirum\Setup.exe, %System%\Empirum\ , USEFILENAME, 958464 1:Common\Matrix42.Empirum.Common.dll, %System%\Empirum\ , USEFILENAME SHAREDDLL , 133944 1:Common\Matrix42.Empirum.Common.NativeInterop.dll, %System%\Empirum\ , USEFILENAME SHAREDDLL , 52008 1:Common\Matrix42.Empirum.Common.Logging.dll, %System%\Empirum\ , USEFILENAME SHAREDDLL , 19752 1:Windows\System\Empirum\Matrix42.Platform.Common.dll, %System%\Empirum\ , USEFILENAME, 87552 1:Windows\System\Empirum\Matrix42.Empirum.SWM.Transport.dll, %System%\Empirum\ , USEFILENAME, 133944 1:Windows\System\Empirum\Matrix42.Empirum.SWM.Common.dll, %System%\Empirum\ , USEFILENAME, 133944 1:Windows\System\Empirum\Matrix42.Empirum.SWM.ERIS.Client.Modules.dll, %System%\Empirum\ , USEFILENAME, 133944 1:Windows\System\Empirum\Microsoft.Practices.Unity.dll, %System%\Empirum\ , USEFILENAME, 133944 1:Windows\System\Empirum\Microsoft.Practices.Unity.Interception.dll, %System%\Empirum\ , USEFILENAME, 125752 1:Windows\System\Empirum\Microsoft.Practices.Prism.dll, %System%\Empirum\ , USEFILENAME, 125752 1:Windows\System\Empirum\Microsoft.Practices.Prism.UnityExtensions.dll, %System%\Empirum\ , USEFILENAME, 125752 1:Windows\System\Empirum\Microsoft.Practices.Composite.dll, %System%\Empirum\ , USEFILENAME, 133944 1:Windows\System\Empirum\Microsoft.Practices.Composite.Presentation.dll, %System%\Empirum\ , USEFILENAME, 133944 1:Windows\System\Empirum\Microsoft.Practices.Composite.UnityExtensions.dll,%System%\Empirum\ , USEFILENAME, 133944 1:Windows\System\Empirum\Microsoft.Practices.ServiceLocation.dll, %System%\Empirum\ , USEFILENAME, 27448 1:Windows\System\Empirum\Microsoft.Practices.EnterpriseLibrary.Common.dll, %System%\Empirum\ , USEFILENAME, 334648 1:Windows\System\Empirum\Microsoft.Practices.EnterpriseLibrary.Data.dll, %System%\Empirum\ , USEFILENAME, 166712 1:Windows\System\Empirum\Microsoft.Practices.EnterpriseLibrary.Logging.dll,%System%\Empirum\ , USEFILENAME, 502584 1:Windows\System\Empirum\Microsoft.Practices.EnterpriseLibrary.Logging.Database.dll, %System%\Empirum\ , USEFILENAME, 56120 1:Common\XAPublisher.exe, %CommonFilesDir%\Setup32\, USEFILENAME, 6914 1:Common\Matrix42.Empirum.Common.dll, %CommonFilesDir%\Setup32\, USEFILENAME, 6914 1:Common\Matrix42.Empirum.Common.ScriptSupport.dll, %CommonFilesDir%\Setup32\, USEFILENAME, 6914 1:Common\Matrix42.Empirum.Common.NativeInterop.dll, %CommonFilesDir%\Setup32\, USEFILENAME, 52008 1:Common\Matrix42.Empirum.Common.Logging.dll, %CommonFilesDir%\Setup32\, USEFILENAME, 19752 1:Common\up.exe, %CommonFilesDir%\Setup32\, USEFILENAME, 6914 1:Windows\System\Empirum\Microsoft.Practices.Unity.dll, %CommonFilesDir%\Setup32\, USEFILENAME, 133944 1:Common\XAPublisher.exe, %CommonFilesDirx86%\Setup32\, USEFILENAME WINDOWS64, 6914 1:Common\Matrix42.Empirum.Common.dll, %CommonFilesDirx86%\Setup32\, USEFILENAME WINDOWS64, 6914 1:Common\Matrix42.Empirum.Common.ScriptSupport.dll, %CommonFilesDirx86%\Setup32\, USEFILENAME WINDOWS64, 6914 1:Common\Matrix42.Empirum.Common.NativeInterop.dll, %CommonFilesDirx86%\Setup32\, USEFILENAME WINDOWS64, 52008 1:Common\Matrix42.Empirum.Common.Logging.dll, %CommonFilesDirx86%\Setup32\, USEFILENAME WINDOWS64, 19752 1:Common\up.exe, %CommonFilesDirx86%\Setup32\, USEFILENAME WINDOWS64, 6914 1:Windows\System\Empirum\Microsoft.Practices.Unity.dll, %CommonFilesDirx86%\Setup32\, USEFILENAME WINDOWS64, 133944 1:Windows\System\Empirum%ARCHITECTURE%\EmpAgentComDll.dll, %System%\Empirum\ , USEFILENAME, 1052672 1:Windows\System\Empirum%ARCHITECTURE%\EmpirumRuntimeLib.dll, %System%\Empirum\ , USEFILENAME, 65536 1:Windows\System\Empirum%ARCHITECTURE%\SchedulerCheck.dll, %System%\Empirum\ , USEFILENAME, 241664 1:Windows\System\Empirum%ARCHITECTURE%\SwDepotEngine.dll, %System%\Empirum\ , USEFILENAME, 1040384 1:Windows\System\Empirum%ARCHITECTURE%\SwDepotWrapper.dll, %System%\Empirum\ , USEFILENAME, 167936 1:Windows\System\Empirum%ARCHITECTURE%\zlib1.dll, %System%\Empirum\ , USEFILENAME SHAREDDLL, 55808 If %WindowsVersion% >= "6.2" Then "CopyNotificationOnWindows8" EndIf #CheckEmpirumAgentTemplate [CopyNotificationOnWindows8] 1:Notification\Matrix42.Notification.exe, %ProgramFiles%\Matrix42\Notification\ , USEFILENAME SHAREDDLL, 0 1:Notification\Matrix42.Default.png, %ProgramFiles%\Matrix42\Notification\ , USEFILENAME SHAREDDLL, 0 1:Notification\Matrix42.Installation.png, %ProgramFiles%\Matrix42\Notification\ , USEFILENAME, 0 1:Notification\Matrix42.Reboot.png, %ProgramFiles%\Matrix42\Notification\ , USEFILENAME, 0 1:Notification\Matrix42.Reboot-Warning.png, %ProgramFiles%\Matrix42\Notification\ , USEFILENAME, 0 1:Notification\Microsoft.WindowsAPICodePack.dll, %ProgramFiles%\Matrix42\Notification\ , USEFILENAME SHAREDDLL, 0 1:Notification\Microsoft.WindowsAPICodePack.Shell.dll, %ProgramFiles%\Matrix42\Notification\ , USEFILENAME SHAREDDLL, 0 [InstallW8Notification] Del "%CMDConfigLogfile%" If %WindowsVersion% >= "6.2" Then "Set:InstallW8Link" EndIf [Set:InstallW8Link] ReplaceEnv CMDConfigLogfile CallHidden Cmd /c Echo CallHidden Cmd /c "C:\Program Files\Matrix42\Notification\Matrix42.Notification.exe" /S:all >> "%CMDConfigLogfile%" CallHidden cmd /c "C:\Program Files\Matrix42\Notification\Matrix42.Notification.exe" /S:all [UninstallW8Notification] If %WindowsVersion% >= "6.2" Then "Set:UninstallW8Link" EndIf -Del "%CMDConfigLogfile%" [Set:UninstallW8Link] -CallHidden cmd /c "C:\Program Files\Matrix42\Notification\Matrix42.Notification.exe" /S:remove -CallHidden Cmd /c Echo CallHidden Cmd /c "C:\Program Files\Matrix42\Notification\Matrix42.Notification.exe" /S:remove >> "%CMDConfigLogfile%" -ReplaceEnv CMDConfigLogfile [Set:InstallAgent] If DoesRegKeyExist ("HKLM,System\CurrentControlSet\Services\Eris") == "0" Then "InstallAgent" EndIf [InstallAgent] If %V_FirstStartAfterReboot% == "1" Then "InstallAgentviaRegistry" Else "InstallAgentviaCommandline" EndIf [InstallAgentviaCommandline] Call "%App%\Eris.exe" /I Sleep 3000 ; EmpirumAgentNoStart set as env variable in EmpirumAgent.bat If %EmpirumAgentNoStart% != "1" Then "Set:StartService" EndIf [Set:StartService] StartService ERIS [Set:OldRevokeCounter] If DoesRegKeyExist ("HKLM,Software\Matrix42\Software Depot\Revoke") == "1" Then "Reg:DeleteOldRevokeCounter" EndIf [InstallAgentviaRegistry] #Reg:InstallAgentviaRegistry [Reg:InstallAgentviaRegistry] HKLM,"SYSTEM\CurrentControlSet\Services\ERIS","DisplayName",0x00000000,"Empirum Remote Installation Service" HKLM,"SYSTEM\CurrentControlSet\Services\ERIS","Description",0x00000000,"Empirum Remote Installation Service" HKLM,"SYSTEM\CurrentControlSet\Services\ERIS","ImagePath",0x00020000,"%App%\ERIS.exe" HKLM,"SYSTEM\CurrentControlSet\Services\ERIS","ObjectName",0x00000000,"LocalSystem" HKLM,"SYSTEM\CurrentControlSet\Services\ERIS","ErrorControl",0x00010001,"1" HKLM,"SYSTEM\CurrentControlSet\Services\ERIS","Type",0x00010001,"16" HKLM,"SYSTEM\CurrentControlSet\Services\ERIS","Start",0x00010001,"2" [Reg:Productx86] HKLM,"Software\Matrix42" [Reg:Productx64] HKLM,"Software\Matrix42" HKLM,"Software\Wow6432Node\Matrix42" [Security:Productx86] RegDacl.Add (HKLM,"Software\Matrix42","%$Everyone%", SET | RECURSE, ALL, SUB_CONTAINERS_AND_OBJECTS_INHERIT) [Security:Productx64] RegDacl.Add (HKLM,"Software\Matrix42","%$Everyone%", SET | RECURSE, ALL, SUB_CONTAINERS_AND_OBJECTS_INHERIT) RegDacl.Add (HKLM,"Software\Wow6432Node\Matrix42","%$Everyone%", SET | RECURSE, ALL, SUB_CONTAINERS_AND_OBJECTS_INHERIT) [CheckInstallMethod] If DoesPathExist ("%WinDir%\Temp\EmpirumAgent_tmp") == "1" Then "Set:UninstallAgent" EndIf [Set:UninstallAgent] Call "%System%\Empirum\Eris.exe" /R #Autoexec.Bat:Push, DONTDELETE -Call "%System%\Empirum\Eris.exe" /R -Sleep 3000 -StopService ERIS -AddMeter -1 [Set:UninstallAgentError] AddMeter -1 StopService ERIS Sleep 3000 Call "%System%\Empirum\Eris.exe" /R [Reg:DeleteRunKeyx86] -HKLM,"Software\Microsoft\Windows\CurrentVersion\Run","Eris_UI" -HKLM,"Software\Microsoft\Windows\CurrentVersion\Run","ErisUI" [Reg:DeleteRunKeyx64] -HKLM,"Software\Microsoft\Windows\CurrentVersion\Run","Eris_UI" -HKLM,"Software\Microsoft\Windows\CurrentVersion\Run","ErisUI" -HKLM,"Software\Wow6432Node\Microsoft\Windows\CurrentVersion\Run","Eris_UI" -HKLM,"Software\Wow6432Node\Microsoft\Windows\CurrentVersion\Run","ErisUI" [Reg:FirstStartAfterReboot] HKLM,"Software\Matrix42\Agent","FirstStartAfterPush",0x00010001,"1" [Reg:DeleteOldRevokeCounter] -HKLM,"Software\Matrix42\Software Depot\Revoke","" [Autoexec.Bat:Product] Path >%Windir%\%SYSTEMDIR%\Empirum [Autoexec.Bat:Push] -Set EmpirumServer= [Set:UnInstallLegacyAgent] If DoesFileExist ("%WinDir%\%SYSTEMDIR%\EMPIRUM\SetupSvc.exe") == "1" Then "Set:DeleteOldAgent" EndIf [Set:DeleteOldAgent] If DoesPathExist ("%WinDir%\Temp\EmpirumAgent_tmp") == "1" Then "PathIsThere" Else "PathIsntThere" EndIf #Set:DeleteLegacyAgent #Reg:DeleteLegacyAgent [PathIsThere] KillProcess "SWDepot.exe" KillProcess "SetupSvc.exe" [PathIsntThere] SetReboot 1 StopService ERIS [Set:DeleteLegacyAgent] KillProcess "ResMon.exe" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\AktEnv.exe" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\ENV.EXE" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\InstMsi.exe" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\lnk.exe" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\MFC42.DLL" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\MSG.DLL" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\MSVCP60.DLL" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\SEC.EXE" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\SETUPSVC.EXE" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\SWDEPOT.EXE" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\SWDEPOTDEU.DLL" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\SWDEPOTENU.DLL" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\SWDEPOTFRA.DLL" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\SWDEPOT*.CHM" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\XALERTC.EXE" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\RESMON.EXE" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\XFTPD.EXE" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\SUTIL95.DLL" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\XPASSWD" Del "%Windir%\%SYSTEMDIR%\EMPIRUM\DDSINET.DLL" Del "%Commondesktop%\SoftwareDepot.lnk" [Reg:DeleteLegacyAgent] -HKLM,"SOFTWARE%X64REGISTRY%\Matrix42\Remote" -HKLM,"SOFTWARE%X64REGISTRY%\Matrix42\Empirum Agent" -HKLM,"SOFTWARE%X64REGISTRY%\Matrix42\Software Depot" -HKLM,"SOFTWARE%X64REGISTRY%\Microsoft\Windows\CurrentVersion\App Paths","SwDepot" -HKLM,"SOFTWARE%X64REGISTRY%\Matrix42\TemporaryData" -HKLM,"SOFTWARE%X64REGISTRY%\Matrix42\DHCPOptions" -HKLM,"SOFTWARE%X64REGISTRY%\Microsoft\Windows\CurrentVersion\Run","_UserEnv" -HKLM,"SOFTWARE%X64REGISTRY%\Microsoft\Windows\CurrentVersion\Run","RunSWDepot1" -HKLM,"SOFTWARE%X64REGISTRY%\Microsoft\Windows\CurrentVersion\Run","RunSWDepot2" -HKLM,"SOFTWARE%X64REGISTRY%\Microsoft\Windows\CurrentVersion\Run","RunSWDepot3" -HKLM,"SOFTWARE%X64REGISTRY%\Microsoft\Windows\CurrentVersion\App Paths\SwDepot.exe" -HKLM,"SYSTEM\CurrentControlSet\Services\SetupService" ; ------- Universal Agent Framework --------- [Set:SHI] ReplaceEnv %Install_SHI_LogFile% ReplaceEnv %V_PATH_MSI% ReplaceEnv %MSI_SHI_LogFile% Del "%Install_SHI_LogFile%" #Set:CopySHI #Set:MSIGUID_SHI #Reg:SetKeysSHI If DoesRegKeyExist ("HKLM,SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\%V_MSIGUID_SHI%,UninstallString") == "0" & DoesRegKeyExist ("HKLM,SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\%V_MSIGUID_SHI%,UninstallString") == "0" Then "Set:InstallSHI" Else "Set:RepairSHI" EndIf If %ErrorLevel% == "3010" Then "RebootRequired" EndIf #ChangeMSISourcelist, DONTDELETE [Set:MSIGUID_SHI] Set V_MSIInstallerID_SHI=06F9724C3B689164E9B504B2EC92A52E Set V_MSIGUID_SHI={C4279F60-86B3-4619-9E5B-402BCE295AE2} [Set:CopySHI] MD %TEMP%\%V_PATH_MSI%\ 1:"Windows\System\Matrix42\Universal Agent Framework\Matrix42 Universal Agent Framework Setup%MSI_ARCHITECTURE%.msi", "%TEMP%\%V_PATH_MSI%\", USEFILENAME ALWAYS, 14000 1:"Windows\System\Matrix42\Universal Agent Framework\Matrix42 Universal Agent Framework Setup.exe", "%TEMP%\%V_PATH_MSI%\", USEFILENAME ALWAYS, 387000 1:"Windows\System\Matrix42\Universal Agent Framework\Matrix42 Universal Agent Framework Setup1.cab", "%TEMP%\%V_PATH_MSI%\", USEFILENAME ALWAYS, 0 1:"Windows\System\Matrix42\Universal Agent Framework\Matrix42 Universal Agent Framework Setup.mst", "%TEMP%\%V_PATH_MSI%\", USEFILENAME ALWAYS, 0 [Set:InstallSHI] ;CallHidden Cmd /c Echo CallHidden Msiexec /i "%TEMP%\%V_PATH_MSI%\Matrix42 Universal Agent Framework Setup.msi" /qn /norestart /log %MSI_SHI_LogFile% >> "%Install_SHI_LogFile%" ;CallHidden Msiexec /i "%TEMP%\%V_PATH_MSI%\Matrix42 Universal Agent Framework Setup.msi" /qn /norestart /log "%MSI_SHI_LogFile%" CallHidden Cmd /c Echo CallHidden "%TEMP%\%V_PATH_MSI%\Matrix42 Universal Agent Framework Setup.exe" /qn /norestart /log "%MSI_SHI_LogFile%" >> "%Install_SHI_LogFile%" CallHidden "%TEMP%\%V_PATH_MSI%\Matrix42 Universal Agent Framework Setup.exe" /quiet /norestart /log "%MSI_SHI_LogFile%" Set ErrorLevelSave=%ErrorLevel% If DoesRegKeyExist ("HKLM,SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\%V_MSIGUID_SHI%") <> "1" & DoesRegKeyExist ("HKLM,SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\%V_MSIGUID_SHI%") <> "1" Then "Set:ErrorInstallationSHI" EndIf If %ErrorLevelSave% <> "3010" & %ErrorLevelSave% <> "0" Then "Set:ErrorInstallationSHI" EndIf If %V_FirstStartAfterReboot% <> "1" & %EmpirumAgentNoStart% <> "1" Then "Set:CheckRunningSHI" EndIf If %ErrorLevelSave% == "3010" | %ErrorLevelSave% == "0" Then "Set:OkInstallationSHI" EndIf [Set:OkInstallationSHI] Del "%Install_SHI_LogFile%" DelTree "%TEMP%\%V_PATH_MSI%" [Set:ErrorInstallationSHI] CallHidden Cmd /c Echo %ErrorInstallationSHI% %ErrorLevelSave% >> "%Install_SHI_LogFile%" ErrorLogMsg %ErrorInstallationSHI% %ErrorLevelSave% #Reg:DeleteKeysSHI #Set:UninstallAgentError Abort %ErrorInstallationSHI% %ErrorLevelSave% [Set:RepairSHI] #Set:StopSHI CallHidden Cmd /c Msiexec /fm %V_MSIGUID_SHI% REBOOT=REALLYSUPPRESS /quiet /log "%MSI_SHI_LogFile%" CallHidden Cmd /c Echo CallHidden Cmd /c "Msiexec /fm %V_MSIGUID_SHI% REBOOT=REALLYSUPPRESS /quiet /log %MSI_SHI_LogFile%" >> "%Install_SHI_LogFile%" Set ErrorLevelSave=%ErrorLevel% ;If DoesTextInFileExist ("%ReInstSuccessMessage1031%", "%MSI_SHI_LogFile%") == "0" & DoesTextInFileExist ("%ReInstSuccessMessage1031_1%", "%MSI_SHI_LogFile%") == "0" & DoesTextInFileExist ("%ReInstSuccessMessage1033%", "%MSI_SHI_LogFile%") == "0" & DoesTextInFileExist ("%ReInstSuccessMessage1033_1%", "%MSI_SHI_LogFile%") == "0" Then "Set:ErrorReinstallationSHI" EndIf If %ErrorLevelSave% <> "3010" & %ErrorLevelSave% <> "0" Then "Set:ErrorReinstallationSHI" EndIf #Set:CheckRunningSHI If %ErrorLevelSave% == "3010" | %ErrorLevelSave% == "0" Then "Set:OkReinstallationSHI" EndIf [Set:OkReinstallationSHI] Del "%Install_SHI_LogFile%" DelTree "%TEMP%\%V_PATH_MSI%" [Set:ErrorReinstallationSHI] CallHidden Cmd /c Echo %ErrorReinstallationSHI% %ErrorLevelSave% >> "%Install_SHI_LogFile%" ErrorLogMsg %ErrorReinstallationSHI% %ErrorLevelSave% Abort %ErrorReinstallationSHI% %ErrorLevelSave% [Set:CheckRunningSHI] If DoesProcessExist ("Matrix42.Platform.Service.Host.exe") <> "1" Then "Set:StartSHI" EndIf If DoesProcessExist ("Matrix42.Platform.Service.Host.exe") <> "1" Then "Set:ErrorStartingSHI" EndIf [Set:StartSHI] CallHidden Cmd /c Echo StartService "Matrix42 Universal Agent Framework" >> "%Install_SHI_LogFile%" StartService "Matrix42UAF" WaitUntilProcessExists "Matrix42.Platform.Service.Host.exe",60 [Set:StopSHI] CallHidden Cmd /c Echo StopService "Matrix42 Universal Agent Framework" >> "%Install_SHI_LogFile%" StopService "Matrix42UAF" WaitWhileProcessExists "Matrix42.Platform.Service.Host.exe",60 [Set:ErrorStartingSHI] CallHidden Cmd /c Echo %ErrorStartingSHI% %ErrorLevel% >> "%Install_SHI_LogFile%" ErrorLogMsg %ErrorStartingSHI% [Set:UninstallSHI] #Reg:DeleteKeysSHI,DELETE If DoesRegKeyExist ("HKLM,SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\%V_MSIGUID_SHI%,InstallDate") == "1" | DoesRegKeyExist ("HKLM,SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Uninstall\%V_MSIGUID_SHI%,InstallDate") == "1" Then "Set:ErrorUninstallSHI" Else "Set:OkUninstallationSHI" EndIf If %ErrorLevel% == "3010" Then "RebootRequired" EndIf -CallHidden Cmd /c Msiexec /uninstall %V_MSIGUID_SHI% REBOOT=REALLYSUPPRESS /quiet /log "%MSI_SHI_LogFile%" -CallHidden Cmd /c Echo CallHidden Cmd /c "Msiexec /uninstall %V_MSIGUID_SHI% REBOOT=REALLYSUPPRESS /quiet /log %MSI_SHI_LogFile%" >> "%Install_SHI_LogFile%" -MD %TEMP%\%V_PATH_MSI%\ #Set:MSIGUID_SHI,DELETE -Del "%Install_SHI_LogFile%" -ReplaceEnv %Install_SHI_LogFile% -ReplaceEnv %MSI_SHI_LogFile% -ReplaceEnv %V_PATH_MSI% [Set:ErrorUninstallSHI] -CallHidden Cmd /c Echo %ErrorUninstallationSHI% %ErrorLevelSave% >> "%Install_SHI_LogFile%" ErrorLogMsg %ErrorUninstallationSHI% %ErrorLevelSave% Set ErrorLevelSave=%ErrorLevel% [Set:OkUninstallationSHI] -Del "%Install_SHI_LogFile%" -DelTree "%TEMP%\%V_PATH_MSI%" [Reg:SetKeysSHI] HKLM,"Software\Matrix42\Platform\Service\Host\Configuration","Source.Agent",0x00000000,"agentconfiguration://%System%\Empirum\AgentConfig.xml" HKLM,"Software\Matrix42\Platform\Service\Host\Configuration","Source.Server",0x00000000,"reg://HKLM/Software/Matrix42/Platform/Service/Host/Server, Server" [Reg:DeleteKeysSHI] HKLM,"Software\Matrix42\Platform\Service\Host\Configuration", "Source.Agent" -HKLM,"Software\Matrix42\Platform\Service\Host\Configuration", "Source.Agent" -HKLM,"Software\Matrix42\Platform\Service\Host\Configuration", "Source.Server" [ChangeMSISourcelist] ReplaceRegValue (HKCR,"Installer\Products\%V_MSIInstallerID_SHI%\Sourcelist","LastUsedSource","\\%EmpirumServer%","\\%%EmpirumServer%%", 1) ReplaceRegValue (HKCR,"Installer\Products\%V_MSIInstallerID_SHI%\Sourcelist\Net","1","\\%EmpirumServer%","\\%%EmpirumServer%%", 1)