From 1492e8c6c49d7dd9a7bb40283ea8f1138ca1cc7b Mon Sep 17 00:00:00 2001 From: DSR! Date: Fri, 18 Feb 2022 10:11:43 -0300 Subject: [PATCH] Update installer code for better cli support --- bin/installer/generate-sections.py | 117 +++++++++++++++++++----- bin/installer/sections/analysis.iss | 4 +- bin/installer/sections/cli.iss | 75 +++++++++++++++ bin/installer/sections/decompilers.iss | 4 +- bin/installer/sections/dissasembler.iss | 1 - bin/installer/sections/monitor.iss | 8 +- bin/installer/sections/other.iss | 24 ++--- bin/installer/sections/unpacking.iss | 10 +- bin/installer/setup.iss | 4 + 9 files changed, 198 insertions(+), 49 deletions(-) create mode 100644 bin/installer/sections/cli.iss diff --git a/bin/installer/generate-sections.py b/bin/installer/generate-sections.py index 4782c32..d08c001 100644 --- a/bin/installer/generate-sections.py +++ b/bin/installer/generate-sections.py @@ -3,27 +3,33 @@ # Copyright (C) 2022 DSR! # Released under the terms of the MIT License # Developed for Python 3.6+ -# pip install py7zr pywin32 colorama +# pip install py7zr pefile colorama import argparse import pathlib import os import re import py7zr -import win32file +import pefile import colorama -def is_64bit_pe(name, file_path): - try: - is_64bit = win32file.GetBinaryType(str(file_path)) == 6 - except: - is_64bit = False +def get_pe_info(file_path): + IMAGE_FILE_MACHINE_AMD64 = 34404 + IMAGE_SUBSYSTEM_WINDOWS_CUI = 3 - return { - 'name': f'{name} x64' if is_64bit else name, - 'check': 'Check: Is64BitInstallMode;' if is_64bit else '', - } + try: + pe = pefile.PE(file_path, fast_load=True) + + return { + # https://docs.microsoft.com/en-us/windows/win32/debug/pe-format#machine-types + 'is_x64': pe.FILE_HEADER.Machine == IMAGE_FILE_MACHINE_AMD64, + + # https://docs.microsoft.com/en-us/windows/win32/debug/pe-format#windows-subsystem + 'is_cli': pe.OPTIONAL_HEADER.Subsystem == IMAGE_SUBSYSTEM_WINDOWS_CUI, + } + except: + return False def component_name(name): @@ -36,6 +42,7 @@ class GenerateInstall: self.section_name = '' self.tool_name = '' self.section_list = [] + self.cli_list = [] self.fix_tool_exe_list = { # fix to support main executable '[dotnet] dnspyex': ['dnspy.exe'], @@ -202,27 +209,54 @@ class GenerateInstall: def iterate_tool_exe_gen(self, exe_path): print(colorama.Fore.GREEN + f' [*] Adding: "{str(pathlib.Path(exe_path).name)}"') - tool_exe_path = self.absolute_to_local_path(exe_path) working_dir = str(pathlib.Path(exe_path).parent) - pe_data = is_64bit_pe(self.tool_name, exe_path) + pe_data = get_pe_info(exe_path) + + # iss variables + iss_name = f'{self.tool_name} x64' if pe_data['is_x64'] else self.tool_name + iss_check = 'Check: Is64BitInstallMode;' if pe_data['is_x64'] else '' + iss_filename = f'{{#MyAppToolsFolder}}\\{self.absolute_to_local_path(exe_path)}' + iss_working_dir = f'{{#MyAppToolsFolder}}\\{self.absolute_to_local_path(working_dir)}' + iss_components = f'{component_name(self.section_name)}\\{component_name(self.tool_name)}' + + if pe_data['is_x64']: + print(colorama.Fore.MAGENTA + f' [!] x64 exe') + + if pe_data['is_cli']: + print(colorama.Fore.MAGENTA + f' [!] CLI exe') + iss_filename = f'{{sys}}\\cmd.exe /K {iss_filename}' + self.cli_list_append( + iss_components, + f'\\{self.absolute_to_local_path(working_dir)}', + ) self.section_list.append('[Icons]') self.section_list.append( - f'Name: "{{group}}\\{{#MyAppName}}\\{pe_data["name"]}"; ' - f'Filename: "{{#MyAppToolsFolder}}\\{tool_exe_path}"; ' - f'WorkingDir: "{{#MyAppToolsFolder}}\\{self.absolute_to_local_path(working_dir)}"; ' - f'Components: "{component_name(self.section_name)}\\{component_name(self.tool_name)}"; ' - f'{pe_data["check"]}' + f'Name: "{{group}}\\{{#MyAppName}}\\{iss_name}"; ' + f'Filename: "{iss_filename}"; ' + f'WorkingDir: "{iss_working_dir}"; ' + f'Components: "{iss_components}"; ' + f'{iss_check}' ) self.section_list.append( - f'Name: "{{#MyAppBinsFolder}}\\sendto\\sendto\\{self.section_name}\\{pe_data["name"]}"; ' - f'Filename: "{{#MyAppToolsFolder}}\\{tool_exe_path}"; ' - f'WorkingDir: "{{#MyAppToolsFolder}}\\{self.absolute_to_local_path(working_dir)}"; ' - f'Components: "{component_name(self.section_name)}\\{component_name(self.tool_name)}"; ' - f'{pe_data["check"]}' + f'Name: "{{#MyAppBinsFolder}}\\sendto\\sendto\\{self.section_name}\\{iss_name}"; ' + f'Filename: "{iss_filename}"; ' + f'WorkingDir: "{iss_working_dir}"; ' + f'Components: "{iss_components}"; ' + f'{iss_check}' ) self.section_list.append('') + def cli_list_append(self, component, working_dir): + for item in self.cli_list: + if item['component'] == component: + return False + + self.cli_list.append({ + 'component': component, + 'working_dir': working_dir, + }) + def iterate_tool_jar(self, folder_path): jar_list = list(folder_path.glob('*.jar')) @@ -258,6 +292,42 @@ class GenerateInstall: ) self.section_list.append('') + def cli_env_extra_code(self): + print('') + print(colorama.Fore.YELLOW + f'[+] Generate cli register code') + + lines_list = [] + + # install hook + lines_list.append('procedure CurStepChanged(CurStep: TSetupStep);') + lines_list.append('begin') + lines_list.append(' if CurStep = ssPostInstall then') + lines_list.append(' begin') + + for item in self.cli_list: + lines_list.append(f' if WizardIsComponentSelected("{item["component"]}") then EnvAddPath(ExpandConstant("{{#MyAppToolsFolder}}") + "{item["working_dir"]}");') + + lines_list.append(' end') + lines_list.append('end;') + lines_list.append('') + + # uninstall hook + lines_list.append('procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep);') + lines_list.append('begin') + lines_list.append(' if CurUninstallStep = usPostUninstall then') + lines_list.append(' begin') + + for item in self.cli_list: + lines_list.append(f' EnvRemovePath(ExpandConstant("{{#MyAppToolsFolder}}") + "{item["working_dir"]}");') + + lines_list.append(' end') + lines_list.append('end;') + lines_list.append('') + + # save + with open('sections\\cli.iss', 'a') as file: + file.writelines('\n'.join(lines_list)) + def main(self): colorama.init(autoreset=True) @@ -280,6 +350,7 @@ class GenerateInstall: return 0 self.iterate_sections(toolkit_folder) + self.cli_env_extra_code() # se fini diff --git a/bin/installer/sections/analysis.iss b/bin/installer/sections/analysis.iss index 9add6c3..9c4398a 100644 --- a/bin/installer/sections/analysis.iss +++ b/bin/installer/sections/analysis.iss @@ -6,8 +6,8 @@ Name: "analysis\capa"; Description: "CAPA"; Types: full; Source: "{#MySrcDir}\toolkit\Analysis\CAPA\*"; DestDir: "{#MyAppToolsFolder}\Analysis\CAPA"; Components: "analysis\capa"; Flags: ignoreversion recursesubdirs createallsubdirs; [Icons] -Name: "{group}\{#MyAppName}\CAPA x64"; Filename: "{#MyAppToolsFolder}\Analysis\CAPA\capa.exe"; WorkingDir: "{#MyAppToolsFolder}\Analysis\CAPA"; Components: "analysis\capa"; Check: Is64BitInstallMode; -Name: "{#MyAppBinsFolder}\sendto\sendto\Analysis\CAPA x64"; Filename: "{#MyAppToolsFolder}\Analysis\CAPA\capa.exe"; WorkingDir: "{#MyAppToolsFolder}\Analysis\CAPA"; Components: "analysis\capa"; Check: Is64BitInstallMode; +Name: "{group}\{#MyAppName}\CAPA x64"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Analysis\CAPA\capa.exe"; WorkingDir: "{#MyAppToolsFolder}\Analysis\CAPA"; Components: "analysis\capa"; Check: Is64BitInstallMode; +Name: "{#MyAppBinsFolder}\sendto\sendto\Analysis\CAPA x64"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Analysis\CAPA\capa.exe"; WorkingDir: "{#MyAppToolsFolder}\Analysis\CAPA"; Components: "analysis\capa"; Check: Is64BitInstallMode; diff --git a/bin/installer/sections/cli.iss b/bin/installer/sections/cli.iss new file mode 100644 index 0000000..d28052f --- /dev/null +++ b/bin/installer/sections/cli.iss @@ -0,0 +1,75 @@ +; Cli programs register/unregister +[Code] +procedure EnvAddPath(Path: string); +var + Paths: string; +begin + { Retrieve current path (use empty string if entry not exists) } + if not RegQueryStringValue(HKEY_CURRENT_USER, 'Environment', 'Path', Paths) then + Paths := ''; + + { Skip if string already found in path } + if Pos(';' + Uppercase(Path) + ';', ';' + Uppercase(Paths) + ';') > 0 then + exit; + + { App string to the end of the path variable } + Paths := Paths + ';'+ Path //+';' + + { Overwrite (or create if missing) path environment variable } + if RegWriteStringValue(HKEY_CURRENT_USER, 'Environment', 'Path', Paths) then + Log(Format('The [%s] added to PATH: [%s]', [Path, Paths])) + else + Log(Format('Error while adding the [%s] to PATH: [%s]', [Path, Paths])); +end; + +procedure EnvRemovePath(Path: string); +var + Paths: string; + P: Integer; +begin + { Skip if registry entry not exists } + if not RegQueryStringValue(HKEY_CURRENT_USER, 'Environment', 'Path', Paths) then + exit; + + { Skip if string not found in path } + P := Pos(';' + Uppercase(Path) + ';', ';' + Uppercase(Paths) + ';'); + if P = 0 then + exit; + + { Update path variable } + Delete(Paths, P - 1, Length(Path) + 1); + + { Overwrite path environment variable } + if RegWriteStringValue(HKEY_CURRENT_USER, 'Environment', 'Path', Paths) then + Log(Format('The [%s] removed from PATH: [%s]', [Path, Paths])) + else + Log(Format('Error while removing the [%s] from PATH: [%s]', [Path, Paths])); +end; + +procedure CurStepChanged(CurStep: TSetupStep); +begin + if CurStep = ssPostInstall then + begin + if WizardIsComponentSelected('analysis\capa') then EnvAddPath(ExpandConstant('{#MyAppToolsFolder}') + '\Analysis\CAPA'); + if WizardIsComponentSelected('monitor\hollowshunter') then EnvAddPath(ExpandConstant('{#MyAppToolsFolder}') + '\Monitor\HollowsHunter'); + if WizardIsComponentSelected('monitor\pesieve') then EnvAddPath(ExpandConstant('{#MyAppToolsFolder}') + '\Monitor\PE-sieve'); + if WizardIsComponentSelected('other\floss') then EnvAddPath(ExpandConstant('{#MyAppToolsFolder}') + '\Other\FLOSS'); + if WizardIsComponentSelected('other\processdump') then EnvAddPath(ExpandConstant('{#MyAppToolsFolder}') + '\Other\Process-Dump'); + if WizardIsComponentSelected('other\strings') then EnvAddPath(ExpandConstant('{#MyAppToolsFolder}') + '\Other\Strings'); + if WizardIsComponentSelected('unpacking\de4dot') then EnvAddPath(ExpandConstant('{#MyAppToolsFolder}') + '\UnPacking\De4Dot'); + end +end; + +procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep); +begin + if CurUninstallStep = usPostUninstall then + begin + EnvRemovePath(ExpandConstant('{#MyAppToolsFolder}') + '\Analysis\CAPA'); + EnvRemovePath(ExpandConstant('{#MyAppToolsFolder}') + '\Monitor\HollowsHunter'); + EnvRemovePath(ExpandConstant('{#MyAppToolsFolder}') + '\Monitor\PE-sieve'); + EnvRemovePath(ExpandConstant('{#MyAppToolsFolder}') + '\Other\FLOSS'); + EnvRemovePath(ExpandConstant('{#MyAppToolsFolder}') + '\Other\Process-Dump'); + EnvRemovePath(ExpandConstant('{#MyAppToolsFolder}') + '\Other\Strings'); + EnvRemovePath(ExpandConstant('{#MyAppToolsFolder}') + '\UnPacking\De4Dot'); + end +end; diff --git a/bin/installer/sections/decompilers.iss b/bin/installer/sections/decompilers.iss index 1219867..86d4ae0 100644 --- a/bin/installer/sections/decompilers.iss +++ b/bin/installer/sections/decompilers.iss @@ -123,8 +123,8 @@ Name: "decompilers\javarecaf"; Description: "[JAVA] Recaf"; Types: full compact; Source: "{#MySrcDir}\toolkit\Decompilers\[JAVA] Recaf\*"; DestDir: "{#MyAppToolsFolder}\Decompilers\[JAVA] Recaf"; Components: "decompilers\javarecaf"; Flags: ignoreversion recursesubdirs createallsubdirs; [Icons] -Name: "{group}\{#MyAppName}\[JAVA] Recaf"; Filename: "{#MyAppToolsFolder}\Decompilers\[JAVA] Recaf\recaf-J8-jar-with-dependencies.jar"; WorkingDir: "{#MyAppToolsFolder}\Decompilers\[JAVA] Recaf"; IconFilename: "{#MyAppToolsIconsFolder}\recaf.ico"; Components: "decompilers\javarecaf"; -Name: "{#MyAppBinsFolder}\sendto\sendto\Decompilers\[JAVA] Recaf"; Filename: "{#MyAppToolsFolder}\Decompilers\[JAVA] Recaf\recaf-J8-jar-with-dependencies.jar"; WorkingDir: "{#MyAppToolsFolder}\Decompilers\[JAVA] Recaf"; IconFilename: "{#MyAppToolsIconsFolder}\recaf.ico"; Components: "decompilers\javarecaf"; +Name: "{group}\{#MyAppName}\[JAVA] Recaf"; Filename: "{#MyAppToolsFolder}\Decompilers\[JAVA] Recaf\recaf-J8-jar-with-dependencies.jar"; WorkingDir: "{#MyAppToolsFolder}\Decompilers\[JAVA] Recaf"; Components: "decompilers\javarecaf"; +Name: "{#MyAppBinsFolder}\sendto\sendto\Decompilers\[JAVA] Recaf"; Filename: "{#MyAppToolsFolder}\Decompilers\[JAVA] Recaf\recaf-J8-jar-with-dependencies.jar"; WorkingDir: "{#MyAppToolsFolder}\Decompilers\[JAVA] Recaf"; Components: "decompilers\javarecaf"; diff --git a/bin/installer/sections/dissasembler.iss b/bin/installer/sections/dissasembler.iss index 20c1384..da6577b 100644 --- a/bin/installer/sections/dissasembler.iss +++ b/bin/installer/sections/dissasembler.iss @@ -86,4 +86,3 @@ Name: "{#MyAppBinsFolder}\sendto\sendto\Dissasembler\x64dbg"; Filename: "{#MyApp ;[Icons] ;Name: "{group}\{#MyAppName}\Ghidra"; Filename: "{#MyAppToolsFolder}\Decompilers\Ghidra\ghidraRun.bat"; WorkingDir: "{#MyAppToolsFolder}\Decompilers\Ghidra"; IconFilename: "{#MyAppToolsIconsFolder}\ghidra.ico"; Components: "decompilers\ghidra"; ;Name: "{#MyAppBinsFolder}\sendto\sendto\Decompilers\Ghidra"; Filename: "{#MyAppToolsFolder}\Decompilers\Ghidra\ghidraRun.bat"; WorkingDir: "{#MyAppToolsFolder}\Decompilers\Ghidra"; IconFilename: "{#MyAppToolsIconsFolder}\ghidra.ico"; Components: "decompilers\ghidra"; - diff --git a/bin/installer/sections/monitor.iss b/bin/installer/sections/monitor.iss index 520cc42..9fdd0ae 100644 --- a/bin/installer/sections/monitor.iss +++ b/bin/installer/sections/monitor.iss @@ -53,8 +53,8 @@ Name: "monitor\hollowshunter"; Description: "HollowsHunter"; Types: full; Source: "{#MySrcDir}\toolkit\Monitor\HollowsHunter\*"; DestDir: "{#MyAppToolsFolder}\Monitor\HollowsHunter"; Components: "monitor\hollowshunter"; Flags: ignoreversion recursesubdirs createallsubdirs; [Icons] -Name: "{group}\{#MyAppName}\HollowsHunter x64"; Filename: "{#MyAppToolsFolder}\Monitor\HollowsHunter\hollows_hunter.exe"; WorkingDir: "{#MyAppToolsFolder}\Monitor\HollowsHunter"; Components: "monitor\hollowshunter"; Check: Is64BitInstallMode; -Name: "{#MyAppBinsFolder}\sendto\sendto\Monitor\HollowsHunter x64"; Filename: "{#MyAppToolsFolder}\Monitor\HollowsHunter\hollows_hunter.exe"; WorkingDir: "{#MyAppToolsFolder}\Monitor\HollowsHunter"; Components: "monitor\hollowshunter"; Check: Is64BitInstallMode; +Name: "{group}\{#MyAppName}\HollowsHunter x64"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Monitor\HollowsHunter\hollows_hunter.exe"; WorkingDir: "{#MyAppToolsFolder}\Monitor\HollowsHunter"; Components: "monitor\hollowshunter"; Check: Is64BitInstallMode; +Name: "{#MyAppBinsFolder}\sendto\sendto\Monitor\HollowsHunter x64"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Monitor\HollowsHunter\hollows_hunter.exe"; WorkingDir: "{#MyAppToolsFolder}\Monitor\HollowsHunter"; Components: "monitor\hollowshunter"; Check: Is64BitInstallMode; @@ -79,8 +79,8 @@ Name: "monitor\pesieve"; Description: "PE-sieve"; Types: full; Source: "{#MySrcDir}\toolkit\Monitor\PE-sieve\*"; DestDir: "{#MyAppToolsFolder}\Monitor\PE-sieve"; Components: "monitor\pesieve"; Flags: ignoreversion recursesubdirs createallsubdirs; [Icons] -Name: "{group}\{#MyAppName}\PE-sieve x64"; Filename: "{#MyAppToolsFolder}\Monitor\PE-sieve\pe-sieve.exe"; WorkingDir: "{#MyAppToolsFolder}\Monitor\PE-sieve"; Components: "monitor\pesieve"; Check: Is64BitInstallMode; -Name: "{#MyAppBinsFolder}\sendto\sendto\Monitor\PE-sieve x64"; Filename: "{#MyAppToolsFolder}\Monitor\PE-sieve\pe-sieve.exe"; WorkingDir: "{#MyAppToolsFolder}\Monitor\PE-sieve"; Components: "monitor\pesieve"; Check: Is64BitInstallMode; +Name: "{group}\{#MyAppName}\PE-sieve x64"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Monitor\PE-sieve\pe-sieve.exe"; WorkingDir: "{#MyAppToolsFolder}\Monitor\PE-sieve"; Components: "monitor\pesieve"; Check: Is64BitInstallMode; +Name: "{#MyAppBinsFolder}\sendto\sendto\Monitor\PE-sieve x64"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Monitor\PE-sieve\pe-sieve.exe"; WorkingDir: "{#MyAppToolsFolder}\Monitor\PE-sieve"; Components: "monitor\pesieve"; Check: Is64BitInstallMode; diff --git a/bin/installer/sections/other.iss b/bin/installer/sections/other.iss index 9773d91..ff6424a 100644 --- a/bin/installer/sections/other.iss +++ b/bin/installer/sections/other.iss @@ -84,8 +84,8 @@ Name: "other\floss"; Description: "FLOSS"; Types: full; Source: "{#MySrcDir}\toolkit\Other\FLOSS\*"; DestDir: "{#MyAppToolsFolder}\Other\FLOSS"; Components: "other\floss"; Flags: ignoreversion recursesubdirs createallsubdirs; [Icons] -Name: "{group}\{#MyAppName}\FLOSS x64"; Filename: "{#MyAppToolsFolder}\Other\FLOSS\floss.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\FLOSS"; Components: "other\floss"; Check: Is64BitInstallMode; -Name: "{#MyAppBinsFolder}\sendto\sendto\Other\FLOSS x64"; Filename: "{#MyAppToolsFolder}\Other\FLOSS\floss.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\FLOSS"; Components: "other\floss"; Check: Is64BitInstallMode; +Name: "{group}\{#MyAppName}\FLOSS x64"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Other\FLOSS\floss.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\FLOSS"; Components: "other\floss"; Check: Is64BitInstallMode; +Name: "{#MyAppBinsFolder}\sendto\sendto\Other\FLOSS x64"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Other\FLOSS\floss.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\FLOSS"; Components: "other\floss"; Check: Is64BitInstallMode; @@ -166,12 +166,12 @@ Name: "other\processdump"; Description: "Process-Dump"; Types: full; Source: "{#MySrcDir}\toolkit\Other\Process-Dump\*"; DestDir: "{#MyAppToolsFolder}\Other\Process-Dump"; Components: "other\processdump"; Flags: ignoreversion recursesubdirs createallsubdirs; [Icons] -Name: "{group}\{#MyAppName}\Process-Dump"; Filename: "{#MyAppToolsFolder}\Other\Process-Dump\pd32.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Process-Dump"; Components: "other\processdump"; -Name: "{#MyAppBinsFolder}\sendto\sendto\Other\Process-Dump"; Filename: "{#MyAppToolsFolder}\Other\Process-Dump\pd32.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Process-Dump"; Components: "other\processdump"; +Name: "{group}\{#MyAppName}\Process-Dump"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Other\Process-Dump\pd32.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Process-Dump"; Components: "other\processdump"; +Name: "{#MyAppBinsFolder}\sendto\sendto\Other\Process-Dump"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Other\Process-Dump\pd32.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Process-Dump"; Components: "other\processdump"; [Icons] -Name: "{group}\{#MyAppName}\Process-Dump x64"; Filename: "{#MyAppToolsFolder}\Other\Process-Dump\pd64.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Process-Dump"; Components: "other\processdump"; Check: Is64BitInstallMode; -Name: "{#MyAppBinsFolder}\sendto\sendto\Other\Process-Dump x64"; Filename: "{#MyAppToolsFolder}\Other\Process-Dump\pd64.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Process-Dump"; Components: "other\processdump"; Check: Is64BitInstallMode; +Name: "{group}\{#MyAppName}\Process-Dump x64"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Other\Process-Dump\pd64.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Process-Dump"; Components: "other\processdump"; Check: Is64BitInstallMode; +Name: "{#MyAppBinsFolder}\sendto\sendto\Other\Process-Dump x64"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Other\Process-Dump\pd64.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Process-Dump"; Components: "other\processdump"; Check: Is64BitInstallMode; @@ -226,12 +226,12 @@ Name: "other\strings"; Description: "Strings"; Types: full; Source: "{#MySrcDir}\toolkit\Other\Strings\*"; DestDir: "{#MyAppToolsFolder}\Other\Strings"; Components: "other\strings"; Flags: ignoreversion recursesubdirs createallsubdirs; [Icons] -Name: "{group}\{#MyAppName}\Strings"; Filename: "{#MyAppToolsFolder}\Other\Strings\strings.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Strings"; Components: "other\strings"; -Name: "{#MyAppBinsFolder}\sendto\sendto\Other\Strings"; Filename: "{#MyAppToolsFolder}\Other\Strings\strings.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Strings"; Components: "other\strings"; +Name: "{group}\{#MyAppName}\Strings"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Other\Strings\strings.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Strings"; Components: "other\strings"; +Name: "{#MyAppBinsFolder}\sendto\sendto\Other\Strings"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Other\Strings\strings.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Strings"; Components: "other\strings"; [Icons] -Name: "{group}\{#MyAppName}\Strings x64"; Filename: "{#MyAppToolsFolder}\Other\Strings\strings64.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Strings"; Components: "other\strings"; Check: Is64BitInstallMode; -Name: "{#MyAppBinsFolder}\sendto\sendto\Other\Strings x64"; Filename: "{#MyAppToolsFolder}\Other\Strings\strings64.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Strings"; Components: "other\strings"; Check: Is64BitInstallMode; +Name: "{group}\{#MyAppName}\Strings x64"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Other\Strings\strings64.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Strings"; Components: "other\strings"; Check: Is64BitInstallMode; +Name: "{#MyAppBinsFolder}\sendto\sendto\Other\Strings x64"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\Other\Strings\strings64.exe"; WorkingDir: "{#MyAppToolsFolder}\Other\Strings"; Components: "other\strings"; Check: Is64BitInstallMode; @@ -243,8 +243,8 @@ Name: "other\threadtear"; Description: "Threadtear"; Types: full; Source: "{#MySrcDir}\toolkit\Other\Threadtear\*"; DestDir: "{#MyAppToolsFolder}\Other\Threadtear"; Components: "other\threadtear"; Flags: ignoreversion recursesubdirs createallsubdirs; [Icons] -Name: "{group}\{#MyAppName}\Threadtear"; Filename: "{#MyAppToolsFolder}\Other\Threadtear\threadtear-gui-all.jar"; WorkingDir: "{#MyAppToolsFolder}\Other\Threadtear"; IconFilename: "{#MyAppToolsIconsFolder}\threadtear.ico"; Components: "other\threadtear"; -Name: "{#MyAppBinsFolder}\sendto\sendto\Other\Threadtear"; Filename: "{#MyAppToolsFolder}\Other\Threadtear\threadtear-gui-all.jar"; WorkingDir: "{#MyAppToolsFolder}\Other\Threadtear"; IconFilename: "{#MyAppToolsIconsFolder}\threadtear.ico"; Components: "other\threadtear"; +Name: "{group}\{#MyAppName}\Threadtear"; Filename: "{#MyAppToolsFolder}\Other\Threadtear\threadtear-gui-all.jar"; WorkingDir: "{#MyAppToolsFolder}\Other\Threadtear"; Components: "other\threadtear"; +Name: "{#MyAppBinsFolder}\sendto\sendto\Other\Threadtear"; Filename: "{#MyAppToolsFolder}\Other\Threadtear\threadtear-gui-all.jar"; WorkingDir: "{#MyAppToolsFolder}\Other\Threadtear"; Components: "other\threadtear"; diff --git a/bin/installer/sections/unpacking.iss b/bin/installer/sections/unpacking.iss index 1b97545..1dc0a3d 100644 --- a/bin/installer/sections/unpacking.iss +++ b/bin/installer/sections/unpacking.iss @@ -6,12 +6,12 @@ Name: "unpacking\de4dot"; Description: "De4Dot"; Types: full; Source: "{#MySrcDir}\toolkit\UnPacking\De4Dot\*"; DestDir: "{#MyAppToolsFolder}\UnPacking\De4Dot"; Components: "unpacking\de4dot"; Flags: ignoreversion recursesubdirs createallsubdirs; [Icons] -Name: "{group}\{#MyAppName}\De4Dot x64"; Filename: "{#MyAppToolsFolder}\UnPacking\De4Dot\de4dot-x64.exe"; WorkingDir: "{#MyAppToolsFolder}\UnPacking\De4Dot"; Components: "unpacking\de4dot"; Check: Is64BitInstallMode; -Name: "{#MyAppBinsFolder}\sendto\sendto\UnPacking\De4Dot x64"; Filename: "{#MyAppToolsFolder}\UnPacking\De4Dot\de4dot-x64.exe"; WorkingDir: "{#MyAppToolsFolder}\UnPacking\De4Dot"; Components: "unpacking\de4dot"; Check: Is64BitInstallMode; +Name: "{group}\{#MyAppName}\De4Dot x64"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\UnPacking\De4Dot\de4dot-x64.exe"; WorkingDir: "{#MyAppToolsFolder}\UnPacking\De4Dot"; Components: "unpacking\de4dot"; Check: Is64BitInstallMode; +Name: "{#MyAppBinsFolder}\sendto\sendto\UnPacking\De4Dot x64"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\UnPacking\De4Dot\de4dot-x64.exe"; WorkingDir: "{#MyAppToolsFolder}\UnPacking\De4Dot"; Components: "unpacking\de4dot"; Check: Is64BitInstallMode; [Icons] -Name: "{group}\{#MyAppName}\De4Dot"; Filename: "{#MyAppToolsFolder}\UnPacking\De4Dot\de4dot.exe"; WorkingDir: "{#MyAppToolsFolder}\UnPacking\De4Dot"; Components: "unpacking\de4dot"; -Name: "{#MyAppBinsFolder}\sendto\sendto\UnPacking\De4Dot"; Filename: "{#MyAppToolsFolder}\UnPacking\De4Dot\de4dot.exe"; WorkingDir: "{#MyAppToolsFolder}\UnPacking\De4Dot"; Components: "unpacking\de4dot"; +Name: "{group}\{#MyAppName}\De4Dot"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\UnPacking\De4Dot\de4dot.exe"; WorkingDir: "{#MyAppToolsFolder}\UnPacking\De4Dot"; Components: "unpacking\de4dot"; +Name: "{#MyAppBinsFolder}\sendto\sendto\UnPacking\De4Dot"; Filename: "{sys}\cmd.exe /K {#MyAppToolsFolder}\UnPacking\De4Dot\de4dot.exe"; WorkingDir: "{#MyAppToolsFolder}\UnPacking\De4Dot"; Components: "unpacking\de4dot"; @@ -103,7 +103,7 @@ Name: "{#MyAppBinsFolder}\sendto\sendto\UnPacking\VM Unpacker"; Filename: "{#MyA ; XVolkolak [Components] -Name: "unpacking\xvolkolak"; Description: "XVolkolak"; Types: full; +Name: "unpacking\xvolkolak"; Description: "XVolkolak"; Types: full compact; [Files] Source: "{#MySrcDir}\toolkit\UnPacking\XVolkolak\*"; DestDir: "{#MyAppToolsFolder}\UnPacking\XVolkolak"; Components: "unpacking\xvolkolak"; Flags: ignoreversion recursesubdirs createallsubdirs; diff --git a/bin/installer/setup.iss b/bin/installer/setup.iss index 065ce1a..8a2b621 100644 --- a/bin/installer/setup.iss +++ b/bin/installer/setup.iss @@ -117,3 +117,7 @@ Name: "{userdesktop}\{#MyAppName}\Menu"; Filename: "{#MyAppBinsFolder}\sendto\se [UninstallDelete] Type: filesandordirs; Name: "{#MyAppToolsFolder}" Type: filesandordirs; Name: "{#MyAppBinsFolder}" + + +; Cli programs register/unregister +#include "sections\cli.iss"