From 91b5dbfe88f94c76c0442ab0535717a57e7550ac Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sat, 18 Aug 2018 13:22:23 -0700 Subject: [PATCH 01/36] Added ENABLED_OPEN_LOGS toggle var --- .bin/Scripts/functions/common.py | 2 +- .bin/Scripts/settings/main.py | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.bin/Scripts/functions/common.py b/.bin/Scripts/functions/common.py index f677df45..2c9614a2 100644 --- a/.bin/Scripts/functions/common.py +++ b/.bin/Scripts/functions/common.py @@ -162,7 +162,7 @@ def exit_script(return_value=0): # Open Log (if it exists) log = global_vars.get('LogFile', '') - if log and os.path.exists(log) and psutil.WINDOWS: + if log and os.path.exists(log) and psutil.WINDOWS and ENABLED_OPEN_LOGS: try: extract_item('NotepadPlusPlus', silent=True) popen_program( diff --git a/.bin/Scripts/settings/main.py b/.bin/Scripts/settings/main.py index c49da96e..95be9c40 100644 --- a/.bin/Scripts/settings/main.py +++ b/.bin/Scripts/settings/main.py @@ -1,8 +1,9 @@ # Wizard Kit: Settings - Main / Branding # Features -ENABLED_UPLOAD_DATA = False +ENABLED_OPEN_LOGS = False ENABLED_TICKET_NUMBERS = False +ENABLED_UPLOAD_DATA = False # STATIC VARIABLES (also used by BASH and BATCH files) ## NOTE: There are no spaces around the = for easier parsing in BASH and BATCH From 71297eacc896442ebd24f39b21ab49e2c3391d00 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sat, 18 Aug 2018 13:24:59 -0700 Subject: [PATCH 02/36] Allow L_ARGS for Python scripts in Launch.cmd --- .bin/Scripts/Launch.cmd | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.bin/Scripts/Launch.cmd b/.bin/Scripts/Launch.cmd index 2364dcc8..ef3d31d9 100644 --- a/.bin/Scripts/Launch.cmd +++ b/.bin/Scripts/Launch.cmd @@ -280,9 +280,9 @@ rem Create VB script mkdir "%bin%\tmp" 2>nul echo Set UAC = CreateObject^("Shell.Application"^) > "%bin%\tmp\Elevate.vbs" if defined L_NCMD ( - echo UAC.ShellExecute "%PYTHON%", """%script%""", "", "runas", 3 >> "%bin%\tmp\Elevate.vbs" + echo UAC.ShellExecute "%PYTHON%", """%script%"" %L_ARGS%", "", "runas", 3 >> "%bin%\tmp\Elevate.vbs" ) else ( - echo UAC.ShellExecute "%CON%", "-run ""%PYTHON%"" ""%script%"" -new_console:n", "", "runas", 1 >> "%bin%\tmp\Elevate.vbs" + echo UAC.ShellExecute "%CON%", "-run ""%PYTHON%"" ""%script%"" %L_ARGS% -new_console:n", "", "runas", 1 >> "%bin%\tmp\Elevate.vbs" ) rem Run @@ -291,9 +291,9 @@ goto Exit :LaunchPyScriptUser if defined L_NCMD ( - start "" "%PYTHON%" "%script%" || goto ErrorUnknown + start "" "%PYTHON%" "%script%" %L_ARGS% || goto ErrorUnknown ) else ( - start "" "%CON%" -run "%PYTHON%" "%script%" -new_console:n || goto ErrorUnknown + start "" "%CON%" -run "%PYTHON%" "%script%" %L_ARGS% -new_console:n || goto ErrorUnknown ) goto Exit @@ -333,7 +333,7 @@ echo. Executable Working Dir Program Args [L_7ZIP] [L_ELEV] [L__CLI] echo. Folder Folder '.' [L_7ZIP] echo. Office Year Product [L_7ZIP] echo. PSScript Scripts Script [L_7ZIP] [L_ELEV] [L_NCMD] -echo. PyScript Scripts Script [L_7ZIP] [L_ELEV] [L_NCMD] +echo. PyScript Scripts Script Args [L_7ZIP] [L_ELEV] [L_NCMD] echo. QuickBooks Year Product [L_7ZIP] echo. echo.L_7ZIP: Extra arguments for 7-Zip (in the :ExtractCBin label) From ed3323fffbaa5e0ad9934843579271739fd2f568 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sat, 18 Aug 2018 13:30:07 -0700 Subject: [PATCH 03/36] Updated system checklist/diags and user checklits * Added D7_MODE to limit functions run during d7II * Added new archive_all_users() function to be run in system_diagnostics --- .bin/Scripts/functions/browsers.py | 68 ++++++++++++++++++--- .bin/Scripts/system_checklist.py | 30 +++++---- .bin/Scripts/system_diagnostics.py | 97 +++++++++++++++++------------- .bin/Scripts/user_checklist.py | 12 ++-- 4 files changed, 139 insertions(+), 68 deletions(-) diff --git a/.bin/Scripts/functions/browsers.py b/.bin/Scripts/functions/browsers.py index b969a59c..7efa4af8 100644 --- a/.bin/Scripts/functions/browsers.py +++ b/.bin/Scripts/functions/browsers.py @@ -2,6 +2,8 @@ from functions.common import * +from operator import itemgetter + # Define other_results for later try_and_print browser_data = {} other_results = { @@ -98,11 +100,57 @@ SUPPORTED_BROWSERS = { }, } +def archive_all_users(): + """Create backups for all browsers for all users.""" + users_root = r'{}\Users'.format(global_vars['Env']['SYSTEMDRIVE']) + user_envs = [] + + # Build list of valid users + for user_name in os.listdir(users_root): + valid_user = True + if user_name in ('Default', 'Default User'): + # Skip default users + continue + user_path = os.path.join(users_root, user_name) + appdata_local = os.path.join(user_path, r'AppData\Local') + appdata_roaming = os.path.join(user_path, r'AppData\Roaming') + valid_user &= os.path.exists(appdata_local) + valid_user &= os.path.exists(appdata_roaming) + if valid_user: + user_envs.append({ + 'USERNAME': user_name, + 'USERPROFILE': user_path, + 'APPDATA': appdata_roaming, + 'LOCALAPPDATA': appdata_local}) + + # Backup browsers for all valid users + print_info('Backing up browsers') + for fake_env in sorted(user_envs, key=itemgetter('USERPROFILE')): + print_standard(fake_env['USERNAME']) + for b_k, b_v in sorted(SUPPORTED_BROWSERS.items()): + if b_k == 'Mozilla Firefox Dev': + continue + source_path = b_v['user_data_path'].format(**fake_env) + if not os.path.exists(source_path): + continue + source_items = source_path + '*' + archive_path = r'{BackupDir}\Browsers ({USERNAME})'.format( + **global_vars, **fake_env) + os.makedirs(archive_path, exist_ok=True) + archive_path += r'\{}.7z'.format(b_k) + cmd = [ + global_vars['Tools']['SevenZip'], + 'a', '-aoa', '-bso0', '-bse0', '-mx=1', + archive_path, source_items] + try_and_print(message=' {}...'.format(b_k), + function=run_program, cmd=cmd) + print_standard(' ') + def archive_browser(name): """Create backup of Browser saved in the BackupDir.""" source = '{}*'.format(browser_data[name]['user_data_path']) dest = r'{BackupDir}\Browsers ({USERNAME})'.format( - **global_vars, **global_vars['Env']) + **global_vars, **env) archive = r'{}\{}.7z'.format(dest, name) os.makedirs(dest, exist_ok=True) cmd = [ @@ -135,7 +183,7 @@ def clean_chromium_profile(profile): def clean_internet_explorer(**kwargs): """Uses the built-in function to reset IE and sets the homepage. - + NOTE: kwargs set but unused as a workaround.""" kill_process('iexplore.exe') run_program(['rundll32.exe', 'inetcpl.cpl,ResetIEtoDefaults'], check=False) @@ -179,11 +227,11 @@ def clean_mozilla_profile(profile): def get_browser_details(name): """Get installation status and profile details for all supported browsers.""" browser = SUPPORTED_BROWSERS[name].copy() - + # Update user_data_path browser['user_data_path'] = browser['user_data_path'].format( **global_vars['Env']) - + # Find executable (if multiple files are found, the last one is used) exe_path = None num_installs = 0 @@ -194,7 +242,7 @@ def get_browser_details(name): if os.path.exists(test_path): num_installs += 1 exe_path = test_path - + # Find profile(s) profiles = [] if browser['base'] == 'ie': @@ -227,7 +275,7 @@ def get_browser_details(name): if os.path.exists(browser['user_data_path']): profiles.append( {'name': 'Default', 'path': browser['user_data_path']}) - + # Get homepages if browser['base'] == 'ie': # IE is set to only have one profile above @@ -236,14 +284,14 @@ def get_browser_details(name): for profile in profiles: prefs_path = r'{path}\prefs.js'.format(**profile) profile['homepages'] = get_mozilla_homepages(prefs_path=prefs_path) - + # Add to browser_data browser_data[name] = browser browser_data[name].update({ 'exe_path': exe_path, 'profiles': profiles, }) - + # Raise installation warnings (if any) if num_installs == 0: raise NotInstalledError @@ -299,7 +347,7 @@ def get_mozilla_homepages(prefs_path): homepages = search.group(1).split('|') except Exception: pass - + return homepages def get_mozilla_profiles(search_path, dev=False): @@ -391,7 +439,7 @@ def install_adblock(indent=8, width=32): def list_homepages(indent=8, width=32): """List current homepages for reference.""" - + for browser in [k for k, v in sorted(browser_data.items()) if v['exe_path']]: # Skip Chromium-based browsers if browser_data[browser]['base'] == 'chromium': diff --git a/.bin/Scripts/system_checklist.py b/.bin/Scripts/system_checklist.py index 73410d92..33865daa 100644 --- a/.bin/Scripts/system_checklist.py +++ b/.bin/Scripts/system_checklist.py @@ -15,6 +15,7 @@ from functions.setup import * init_global_vars() os.system('title {}: System Checklist Tool'.format(KIT_NAME_FULL)) global_vars['LogFile'] = r'{LogDir}\System Checklist.log'.format(**global_vars) +D7_MODE = 'd7mode' in sys.argv if __name__ == '__main__': try: @@ -49,17 +50,18 @@ if __name__ == '__main__': function=cleanup_adwcleaner, cs='Done', other_results=other_results) # Export system info - print_info('Backup System Information') - try_and_print(message='AIDA64 reports...', - function=run_aida64, cs='Done', other_results=other_results) - try_and_print(message='File listing...', - function=backup_file_list, cs='Done', other_results=other_results) - try_and_print(message='Power plans...', - function=backup_power_plans, cs='Done') - try_and_print(message='Product Keys...', other_results=other_results, - function=run_produkey, cs='Done') - try_and_print(message='Registry...', - function=backup_registry, cs='Done', other_results=other_results) + if not D7_MODE: + print_info('Backup System Information') + try_and_print(message='AIDA64 reports...', + function=run_aida64, cs='Done', other_results=other_results) + try_and_print(message='File listing...', + function=backup_file_list, cs='Done', other_results=other_results) + try_and_print(message='Power plans...', + function=backup_power_plans, cs='Done') + try_and_print(message='Product Keys...', other_results=other_results, + function=run_produkey, cs='Done') + try_and_print(message='Registry...', + function=backup_registry, cs='Done', other_results=other_results) # User data print_info('User Data') @@ -79,12 +81,18 @@ if __name__ == '__main__': try_and_print(message='Installed RAM:', function=show_installed_ram, ns='Unknown', silent_function=False) show_free_space() + if D7_MODE: + try_and_print(message='Temp Size:', + function=show_temp_files_size, silent_function=False) try_and_print(message='Installed Antivirus:', function=get_installed_antivirus, ns='Unknown', other_results=other_results, print_return=True) try_and_print(message='Installed Office:', function=get_installed_office, ns='Unknown', other_results=other_results, print_return=True) + if D7_MODE: + try_and_print(message='Product Keys:', + function=get_product_keys, ns='Unknown', print_return=True) # Play audio, show devices, open Windows updates, and open Activation try_and_print(message='Opening Device Manager...', diff --git a/.bin/Scripts/system_diagnostics.py b/.bin/Scripts/system_diagnostics.py index 9a6e1c0b..4c0fe0a8 100644 --- a/.bin/Scripts/system_diagnostics.py +++ b/.bin/Scripts/system_diagnostics.py @@ -15,6 +15,7 @@ init_global_vars() os.system('title {}: System Diagnostics Tool'.format(KIT_NAME_FULL)) global_vars['LogFile'] = r'{LogDir}\System Diagnostics.log'.format( **global_vars) +D7_MODE = 'd7mode' in sys.argv if __name__ == '__main__': try: @@ -37,23 +38,23 @@ if __name__ == '__main__': # Sanitize Environment print_info('Sanitizing Environment') - # try_and_print(message='Killing processes...', - # function=run_process_killer, cs='Done') - try_and_print(message='Running RKill...', - function=run_rkill, cs='Done', other_results=other_results) - try_and_print(message='Running TDSSKiller...', - function=run_tdsskiller, cs='Done', other_results=other_results) + if not D7_MODE: + try_and_print(message='Running RKill...', + function=run_rkill, cs='Done', other_results=other_results) + try_and_print(message='Running TDSSKiller...', + function=run_tdsskiller, cs='Done', other_results=other_results) # Re-run if earlier process was stopped. stay_awake() # Start diags - print_info('Starting Background Scans') - check_connection() - try_and_print(message='Running HitmanPro...', - function=run_hitmanpro, cs='Started', other_results=other_results) - try_and_print(message='Running Autoruns...', - function=run_autoruns, cs='Started', other_results=other_results) + if not D7_MODE: + print_info('Starting Background Scans') + check_connection() + try_and_print(message='Running HitmanPro...', + function=run_hitmanpro, cs='Started', other_results=other_results) + try_and_print(message='Running Autoruns...', + function=run_autoruns, cs='Started', other_results=other_results) # OS Health Checks print_info('OS Health Checks') @@ -65,9 +66,14 @@ if __name__ == '__main__': try_and_print(message='DISM CheckHealth...', function=run_dism, other_results=other_results, repair=False) - # Scan for supported browsers - print_info('Scanning for browsers') - scan_for_browsers() + + if D7_MODE: + # Archive all browsers for all users + archive_all_users() + else: + # Scan for supported browsers + print_info('Scanning for browsers') + scan_for_browsers() # Export system info print_info('Backup System Information') @@ -75,46 +81,51 @@ if __name__ == '__main__': function=run_aida64, cs='Done', other_results=other_results) try_and_print(message='BleachBit report...', function=run_bleachbit, cs='Done', other_results=other_results) - backup_browsers() + if not D7_MODE: + backup_browsers() try_and_print(message='File listing...', function=backup_file_list, cs='Done', other_results=other_results) try_and_print(message='Power plans...', function=backup_power_plans, cs='Done') try_and_print(message='Product Keys...', function=run_produkey, cs='Done', other_results=other_results) - try_and_print(message='Registry...', - function=backup_registry, cs='Done', other_results=other_results) + if not D7_MODE: + try_and_print(message='Registry...', + function=backup_registry, cs='Done', other_results=other_results) # Summary - print_info('Summary') - try_and_print(message='Operating System:', - function=show_os_name, ns='Unknown', silent_function=False) - try_and_print(message='Activation:', - function=show_os_activation, ns='Unknown', silent_function=False) - try_and_print(message='Installed RAM:', - function=show_installed_ram, ns='Unknown', silent_function=False) - show_free_space() - try_and_print(message='Temp Size:', - function=show_temp_files_size, silent_function=False) - try_and_print(message='Installed Antivirus:', - function=get_installed_antivirus, ns='Unknown', - other_results=other_results, print_return=True) - try_and_print(message='Installed Office:', - function=get_installed_office, ns='Unknown', - other_results=other_results, print_return=True) - try_and_print(message='Product Keys:', - function=get_product_keys, ns='Unknown', print_return=True) + if not D7_MODE: + print_info('Summary') + try_and_print(message='Operating System:', + function=show_os_name, ns='Unknown', silent_function=False) + try_and_print(message='Activation:', + function=show_os_activation, ns='Unknown', silent_function=False) + try_and_print(message='Installed RAM:', + function=show_installed_ram, ns='Unknown', silent_function=False) + show_free_space() + try_and_print(message='Temp Size:', + function=show_temp_files_size, silent_function=False) + try_and_print(message='Installed Antivirus:', + function=get_installed_antivirus, ns='Unknown', + other_results=other_results, print_return=True) + try_and_print(message='Installed Office:', + function=get_installed_office, ns='Unknown', + other_results=other_results, print_return=True) + try_and_print(message='Product Keys:', + function=get_product_keys, ns='Unknown', print_return=True) # User data - print_info('User Data') - try: - show_user_data_summary() - except Exception: - print_error(' Unknown error.') + if not D7_MODE: + print_info('User Data') + try: + show_user_data_summary() + except Exception: + print_error(' Unknown error.') # Done - print_standard('\nDone.') - pause('Press Enter to exit...') + if not D7_MODE: + print_standard('\nDone.') + pause('Press Enter to exit...') exit_script() except SystemExit: pass diff --git a/.bin/Scripts/user_checklist.py b/.bin/Scripts/user_checklist.py index 72697af7..c106c9ef 100644 --- a/.bin/Scripts/user_checklist.py +++ b/.bin/Scripts/user_checklist.py @@ -13,6 +13,7 @@ init_global_vars() os.system('title {}: User Checklist Tool'.format(KIT_NAME_FULL)) global_vars['LogFile'] = r'{LogDir}\User Checklist ({USERNAME}).log'.format( **global_vars, **global_vars['Env']) +D7_MODE = 'd7mode' in sys.argv if __name__ == '__main__': try: @@ -46,8 +47,10 @@ if __name__ == '__main__': list_homepages() # Backup - print_info('Backing up browsers') - backup_browsers() + if not D7_MODE: + # Done during system_diagnostics + print_info('Backing up browsers') + backup_browsers() # Reset if answer_config_browsers and answer_reset_browsers: @@ -77,8 +80,9 @@ if __name__ == '__main__': popen_program(['start', '', 'https://fast.com'], shell=True) # Done - print_standard('\nDone.') - pause('Press Enter to exit...') + if not D7_MODE: + print_standard('\nDone.') + pause('Press Enter to exit...') exit_script() except SystemExit: pass From b42f393a1ae64899045d968c14e484742af9d822 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sat, 18 Aug 2018 15:28:33 -0700 Subject: [PATCH 04/36] Always configure browsers/classicshell/explorer --- .bin/Scripts/user_checklist.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.bin/Scripts/user_checklist.py b/.bin/Scripts/user_checklist.py index c106c9ef..e280567e 100644 --- a/.bin/Scripts/user_checklist.py +++ b/.bin/Scripts/user_checklist.py @@ -25,13 +25,16 @@ if __name__ == '__main__': 'NotInstalledError': 'Not installed', 'NoProfilesError': 'No profiles found', }} - answer_config_browsers = ask('Install adblock?') + #answer_config_browsers = ask('Install adblock?') + answer_config_browsers = True if answer_config_browsers: answer_reset_browsers = ask( 'Reset browsers to safe defaults first?') if global_vars['OS']['Version'] == '10': - answer_config_classicshell = ask('Configure ClassicShell?') - answer_config_explorer_user = ask('Configure Explorer?') + #answer_config_classicshell = ask('Configure ClassicShell?') + #answer_config_explorer_user = ask('Configure Explorer?') + answer_config_classicshell = True + answer_config_explorer_user = True # Cleanup print_info('Cleanup') From 9f77b532b6885af3c141bd949c4053614718ccc6 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sat, 18 Aug 2018 15:49:12 -0700 Subject: [PATCH 05/36] New reset_browsers script for use in d7ii * Adjusted user_checklist as well --- .bin/Scripts/reset_browsers.py | 61 ++++++++++++++++++++++++++++++++++ .bin/Scripts/user_checklist.py | 26 +++++++++------ 2 files changed, 77 insertions(+), 10 deletions(-) create mode 100644 .bin/Scripts/reset_browsers.py diff --git a/.bin/Scripts/reset_browsers.py b/.bin/Scripts/reset_browsers.py new file mode 100644 index 00000000..248b8c72 --- /dev/null +++ b/.bin/Scripts/reset_browsers.py @@ -0,0 +1,61 @@ +# Wizard Kit: Reset Browsers + +import os +import sys + +# Init +os.chdir(os.path.dirname(os.path.realpath(__file__))) +sys.path.append(os.getcwd()) +from functions.browsers import * +from functions.cleanup import * +from functions.setup import * +init_global_vars() +os.system('title {}: Browser Reset Tool'.format(KIT_NAME_FULL)) +global_vars['LogFile'] = r'{LogDir}\Browser Reset ({USERNAME}).log'.format( + **global_vars, **global_vars['Env']) +D7_MODE = 'd7mode' in sys.argv + +if __name__ == '__main__': + try: + stay_awake() + clear_screen() + print_info('{}: Browser Reset\n'.format(KIT_NAME_FULL)) + other_results = { + 'Warning': { + 'NotInstalledError': 'Not installed', + 'NoProfilesError': 'No profiles found', + }} + + # Bail early + if not D7_MODE or ask('Reset browsers to safe defaults first?'): + exit_script() + + # Scan for supported browsers + print_info('Scanning for browsers') + scan_for_browsers() + + # Homepages + print_info('Current homepages') + list_homepages() + + # Backup + print_info('Backing up browsers') + backup_browsers() + + # Reset + print_info('Resetting browsers') + reset_browsers() + + # Configure + print_info('Installing uBlock Origin') + install_adblock() + + # Done + if not D7_MODE: + print_standard('\nDone.') + pause('Press Enter to exit...') + exit_script() + except SystemExit: + pass + except: + major_exception() diff --git a/.bin/Scripts/user_checklist.py b/.bin/Scripts/user_checklist.py index e280567e..70511269 100644 --- a/.bin/Scripts/user_checklist.py +++ b/.bin/Scripts/user_checklist.py @@ -28,38 +28,44 @@ if __name__ == '__main__': #answer_config_browsers = ask('Install adblock?') answer_config_browsers = True if answer_config_browsers: + if D7_MODE: + # This is handled by another script option in d7ii + answer_reset_browsers = False + else: + answer_reset_browsers = ask( + 'Reset browsers to safe defaults first?') answer_reset_browsers = ask( - 'Reset browsers to safe defaults first?') if global_vars['OS']['Version'] == '10': #answer_config_classicshell = ask('Configure ClassicShell?') #answer_config_explorer_user = ask('Configure Explorer?') answer_config_classicshell = True answer_config_explorer_user = True - + # Cleanup print_info('Cleanup') try_and_print(message='Desktop...', function=cleanup_desktop, cs='Done') - + # Scan for supported browsers print_info('Scanning for browsers') scan_for_browsers() - + # Homepages - print_info('Current homepages') - list_homepages() - + if not D7_MODE: + print_info('Current homepages') + list_homepages() + # Backup if not D7_MODE: # Done during system_diagnostics print_info('Backing up browsers') backup_browsers() - + # Reset if answer_config_browsers and answer_reset_browsers: print_info('Resetting browsers') reset_browsers() - + # Configure print_info('Configuring programs') if answer_config_browsers: @@ -81,7 +87,7 @@ if __name__ == '__main__': # Run speedtest popen_program(['start', '', 'https://fast.com'], shell=True) - + # Done if not D7_MODE: print_standard('\nDone.') From 712eeff79e34aaae1f3d472fde21e38b46affd96 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sat, 18 Aug 2018 16:26:17 -0700 Subject: [PATCH 06/36] Set default main.py values for 1201 --- .bin/Scripts/settings/main.py | 71 +++++++++++++++-------------------- 1 file changed, 31 insertions(+), 40 deletions(-) diff --git a/.bin/Scripts/settings/main.py b/.bin/Scripts/settings/main.py index 95be9c40..22e6f955 100644 --- a/.bin/Scripts/settings/main.py +++ b/.bin/Scripts/settings/main.py @@ -8,83 +8,74 @@ ENABLED_UPLOAD_DATA = False # STATIC VARIABLES (also used by BASH and BATCH files) ## NOTE: There are no spaces around the = for easier parsing in BASH and BATCH # Main Kit -ARCHIVE_PASSWORD='Abracadabra' -KIT_NAME_FULL='Wizard Kit' -KIT_NAME_SHORT='WK' -SUPPORT_MESSAGE='Please let 2Shirt know by opening an issue on GitHub' +ARCHIVE_PASSWORD='Sorted1201' +KIT_NAME_FULL='1201-WizardKit' +KIT_NAME_SHORT='1201' +SUPPORT_MESSAGE='Please let support know by opening an issue on Gogs' # Live Linux MPRIME_LIMIT='7' # of minutes to run Prime95 during hw-diags -ROOT_PASSWORD='Abracadabra' -TECH_PASSWORD='Abracadabra' +ROOT_PASSWORD='1201 loves computers!' +TECH_PASSWORD='Sorted1201' # Server IP addresses -OFFICE_SERVER_IP='10.0.0.10' -QUICKBOOKS_SERVER_IP='10.0.0.10' +OFFICE_SERVER_IP='10.11.1.20' +QUICKBOOKS_SERVER_IP='10.11.1.20' # Time Zones LINUX_TIME_ZONE='America/Los_Angeles' # See 'timedatectl list-timezones' for valid values WINDOWS_TIME_ZONE='Pacific Standard Time' # See 'tzutil /l' for valid values # WiFi -WIFI_SSID='SomeWifi' -WIFI_PASSWORD='Abracadabra' +WIFI_SSID='1201 Computers' +WIFI_PASSWORD='12011201' # SERVER VARIABLES ## NOTE: Windows can only use one user per server. This means that if ## one server serves multiple shares then you have to use the same ## user/password for all of those shares. BACKUP_SERVERS = [ - { 'IP': '10.0.0.10', - 'Name': 'ServerOne', + { 'IP': '10.11.1.20', + 'Name': 'Anaconda', 'Mounted': False, 'Share': 'Backups', - 'User': 'restore', - 'Pass': 'Abracadabra', + 'User': 'cx', + 'Pass': 'cx', 'RW-User': 'backup', - 'RW-Pass': 'Abracadabra', - }, - { 'IP': '10.0.0.11', - 'Name': 'ServerTwo', - 'Mounted': False, - 'Share': 'Backups', - 'User': 'restore', - 'Pass': 'Abracadabra', - 'RW-User': 'backup', - 'RW-Pass': 'Abracadabra', + 'RW-Pass': '1201 loves computers!', }, ] CRASH_SERVER = { - 'Name': 'CrashServer', - 'Url': '', - 'User': '', + 'Name': "2Shirt's Nextcloud Server", + 'Url': 'https://nextcloud.2shirt.work/public.php/webdav/WK_Issues', + 'User': 'hgoTCWIL28oGWqJ', 'Pass': '', } OFFICE_SERVER = { 'IP': OFFICE_SERVER_IP, - 'Name': 'ServerOne', + 'Name': 'Anaconda', 'Mounted': False, 'Share': 'Office', - 'User': 'restore', - 'Pass': 'Abracadabra', + 'User': 'cx', + 'Pass': 'cx', 'RW-User': 'backup', - 'RW-Pass': 'Abracadabra', + 'RW-Pass': '1201 loves computers!', } QUICKBOOKS_SERVER = { 'IP': QUICKBOOKS_SERVER_IP, - 'Name': 'ServerOne', + 'Name': 'Anaconda', 'Mounted': False, 'Share': 'QuickBooks', - 'User': 'restore', - 'Pass': 'Abracadabra', + 'User': 'cx', + 'Pass': 'cx', 'RW-User': 'backup', - 'RW-Pass': 'Abracadabra', + 'RW-Pass': '1201 loves computers!', } WINDOWS_SERVER = { - 'IP': '10.0.0.10', - 'Name': 'ServerOne', + 'IP': '10.11.1.20', + 'Name': 'Anaconda', 'Mounted': False, 'Share': 'Windows', - 'User': 'restore', - 'Pass': 'Abracadabra', + 'User': 'cx', + 'Pass': 'cx', 'RW-User': 'backup', - 'RW-Pass': 'Abracadabra', + 'RW-Pass': '1201 loves computers!', } if __name__ == '__main__': From c16a540b3ef07bd4d2967ec2b81c2b7e673741e7 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sat, 18 Aug 2018 16:41:52 -0700 Subject: [PATCH 07/36] Fix D7_MODE logic in reset_browsers.py --- .bin/Scripts/reset_browsers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.bin/Scripts/reset_browsers.py b/.bin/Scripts/reset_browsers.py index 248b8c72..8e889cf2 100644 --- a/.bin/Scripts/reset_browsers.py +++ b/.bin/Scripts/reset_browsers.py @@ -27,7 +27,7 @@ if __name__ == '__main__': }} # Bail early - if not D7_MODE or ask('Reset browsers to safe defaults first?'): + if D7_MODE or ask('Reset browsers to safe defaults first?'): exit_script() # Scan for supported browsers From b57374b177fcc283a82519888a649851e750cf0e Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sat, 18 Aug 2018 16:47:09 -0700 Subject: [PATCH 08/36] Fix D7_MODE logic in reset_browsers (again) * Went wrong direction last time --- .bin/Scripts/reset_browsers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.bin/Scripts/reset_browsers.py b/.bin/Scripts/reset_browsers.py index 8e889cf2..900263ee 100644 --- a/.bin/Scripts/reset_browsers.py +++ b/.bin/Scripts/reset_browsers.py @@ -27,7 +27,7 @@ if __name__ == '__main__': }} # Bail early - if D7_MODE or ask('Reset browsers to safe defaults first?'): + if not D7_MODE and not ask('Reset browsers to safe defaults first?'): exit_script() # Scan for supported browsers From 90a9751883d659bc54d51adee9c51b79c02017cf Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sat, 18 Aug 2018 17:09:55 -0700 Subject: [PATCH 09/36] More bugfixes for reset_browser split --- .bin/Scripts/functions/browsers.py | 2 +- .bin/Scripts/reset_browsers.py | 7 ------- .bin/Scripts/user_checklist.py | 1 - 3 files changed, 1 insertion(+), 9 deletions(-) diff --git a/.bin/Scripts/functions/browsers.py b/.bin/Scripts/functions/browsers.py index 7efa4af8..7e963032 100644 --- a/.bin/Scripts/functions/browsers.py +++ b/.bin/Scripts/functions/browsers.py @@ -150,7 +150,7 @@ def archive_browser(name): """Create backup of Browser saved in the BackupDir.""" source = '{}*'.format(browser_data[name]['user_data_path']) dest = r'{BackupDir}\Browsers ({USERNAME})'.format( - **global_vars, **env) + **global_vars, **global_vars['Env']) archive = r'{}\{}.7z'.format(dest, name) os.makedirs(dest, exist_ok=True) cmd = [ diff --git a/.bin/Scripts/reset_browsers.py b/.bin/Scripts/reset_browsers.py index 900263ee..e47cecbe 100644 --- a/.bin/Scripts/reset_browsers.py +++ b/.bin/Scripts/reset_browsers.py @@ -46,14 +46,7 @@ if __name__ == '__main__': print_info('Resetting browsers') reset_browsers() - # Configure - print_info('Installing uBlock Origin') - install_adblock() - # Done - if not D7_MODE: - print_standard('\nDone.') - pause('Press Enter to exit...') exit_script() except SystemExit: pass diff --git a/.bin/Scripts/user_checklist.py b/.bin/Scripts/user_checklist.py index 70511269..e71b4e96 100644 --- a/.bin/Scripts/user_checklist.py +++ b/.bin/Scripts/user_checklist.py @@ -34,7 +34,6 @@ if __name__ == '__main__': else: answer_reset_browsers = ask( 'Reset browsers to safe defaults first?') - answer_reset_browsers = ask( if global_vars['OS']['Version'] == '10': #answer_config_classicshell = ask('Configure ClassicShell?') #answer_config_explorer_user = ask('Configure Explorer?') From 241f5cb897b032b4d4aad72d1ca72312c512c636 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sat, 18 Aug 2018 17:15:10 -0700 Subject: [PATCH 10/36] Always open the uBlock store page for FF * If d7 defaults are run then uBO may still need installed --- .bin/Scripts/functions/browsers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.bin/Scripts/functions/browsers.py b/.bin/Scripts/functions/browsers.py index 7e963032..485a4ef5 100644 --- a/.bin/Scripts/functions/browsers.py +++ b/.bin/Scripts/functions/browsers.py @@ -421,7 +421,7 @@ def install_adblock(indent=8, width=32): 'firefox.exe', r'distribution\extensions\uBlock0@raymondhill.net') if os.path.exists(ubo): - urls = ['about:addons'] + urls = ['about:addons', UBO_MOZILLA] elif browser_data[browser]['base'] == 'ie': urls.append(IE_GALLERY) From ceba2e5ff239ace2b08ad01ee5711245b784cf6f Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sat, 18 Aug 2018 17:53:50 -0700 Subject: [PATCH 11/36] Add d7/Firefox workaround * When Firefox is run from d7ii all tabs crash thus preventing installing uBO * Added d7_forefix_fix.py to install uBO just for mozilla-type browsers --- .bin/Scripts/d7_firefox_fix.py | 44 ++++++++++++++++++++++++++++++ .bin/Scripts/functions/browsers.py | 10 +++++-- 2 files changed, 51 insertions(+), 3 deletions(-) create mode 100644 .bin/Scripts/d7_firefox_fix.py diff --git a/.bin/Scripts/d7_firefox_fix.py b/.bin/Scripts/d7_firefox_fix.py new file mode 100644 index 00000000..27b33112 --- /dev/null +++ b/.bin/Scripts/d7_firefox_fix.py @@ -0,0 +1,44 @@ +# Wizard Kit: Install uBlock Origin for Firefox + +import os +import sys + +# Init +os.chdir(os.path.dirname(os.path.realpath(__file__))) +sys.path.append(os.getcwd()) +from functions.browsers import * +from functions.cleanup import * +from functions.setup import * +init_global_vars() +os.system('title {}: User Checklist Tool'.format(KIT_NAME_FULL)) +global_vars['LogFile'] = r'{LogDir}\User Checklist ({USERNAME}).log'.format( + **global_vars, **global_vars['Env']) +D7_MODE = 'd7mode' in sys.argv + +if __name__ == '__main__': + try: + stay_awake() + clear_screen() + print_info('{}: Firefox Fix for d7') + other_results = { + 'Warning': { + 'NotInstalledError': 'Not installed', + 'NoProfilesError': 'No profiles found', + }} + + # Scan for Firefox browsers + print_info('Scanning for Firefox browsers') + scan_for_browsers(just_firefox=True) + + # Install uBlock Origin + print_info('Installing uBlock Origin') + install_adblock(just_firefox=True) + + # Done + print_standard('\nDone.') + pause('Press Enter to exit...') + exit_script() + except SystemExit: + pass + except: + major_exception() diff --git a/.bin/Scripts/functions/browsers.py b/.bin/Scripts/functions/browsers.py index 485a4ef5..50d0a990 100644 --- a/.bin/Scripts/functions/browsers.py +++ b/.bin/Scripts/functions/browsers.py @@ -374,9 +374,11 @@ def get_mozilla_profiles(search_path, dev=False): return profiles -def install_adblock(indent=8, width=32): +def install_adblock(indent=8, width=32, just_firefox=False): """Install adblock for all supported browsers.""" for browser in sorted(browser_data): + if just_firefox and browser_data[browser]['base'] != 'mozilla': + continue exe_path = browser_data[browser].get('exe_path', None) function=run_program if not exe_path: @@ -483,9 +485,11 @@ def reset_browsers(indent=8, width=32): indent=indent, width=width, function=function, other_results=other_results, profile=profile) -def scan_for_browsers(): +def scan_for_browsers(just_firefox=False): """Scan system for any supported browsers.""" - for name in sorted(SUPPORTED_BROWSERS): + for name, details in sorted(SUPPORTED_BROWSERS.items()): + if just_firefox and details['base'] != 'mozilla': + continue try_and_print(message='{}...'.format(name), function=get_browser_details, cs='Detected', other_results=other_results, name=name) From 2369786b6674771316b2f4f8d0f93ac779ef776d Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sat, 18 Aug 2018 18:10:54 -0700 Subject: [PATCH 12/36] Bugfix: d7_firefox_fix.py --- .bin/Scripts/d7_firefox_fix.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.bin/Scripts/d7_firefox_fix.py b/.bin/Scripts/d7_firefox_fix.py index 27b33112..7fe1f244 100644 --- a/.bin/Scripts/d7_firefox_fix.py +++ b/.bin/Scripts/d7_firefox_fix.py @@ -19,7 +19,7 @@ if __name__ == '__main__': try: stay_awake() clear_screen() - print_info('{}: Firefox Fix for d7') + print_info('{}: Firefox Fix for d7\n'.format(KIT_NAME_FULL)) other_results = { 'Warning': { 'NotInstalledError': 'Not installed', From 298222c9fc2250e6146d9ac6bfa71b7f989b4bc3 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sat, 18 Aug 2018 18:46:17 -0700 Subject: [PATCH 13/36] Password protect browser backups --- .bin/Scripts/functions/browsers.py | 1 + 1 file changed, 1 insertion(+) diff --git a/.bin/Scripts/functions/browsers.py b/.bin/Scripts/functions/browsers.py index 50d0a990..a374e54b 100644 --- a/.bin/Scripts/functions/browsers.py +++ b/.bin/Scripts/functions/browsers.py @@ -156,6 +156,7 @@ def archive_browser(name): cmd = [ global_vars['Tools']['SevenZip'], 'a', '-aoa', '-bso0', '-bse0', '-mx=1', + '-mhe=on', '-p{}'.format(ARCHIVE_PASSWORD), archive, source] run_program(cmd) From 1244b7f5e5f6d0035341412a3a4c4462c4952fc0 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sun, 19 Aug 2018 11:53:33 -0700 Subject: [PATCH 14/36] New SW Bundles * Removed Air, Java, & Silverlight * Added SumatraPDF --- .bin/Scripts/settings/sources.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.bin/Scripts/settings/sources.py b/.bin/Scripts/settings/sources.py index 3560b092..195a10bb 100644 --- a/.bin/Scripts/settings/sources.py +++ b/.bin/Scripts/settings/sources.py @@ -71,9 +71,8 @@ VCREDIST_SOURCES = { } NINITE_SOURCES = { 'Bundles': { - 'Runtimes.exe': '.net4.7.1-air-java8-silverlight', - 'Legacy.exe': '.net4.7.1-7zip-air-chrome-firefox-java8-silverlight-vlc', - 'Modern.exe': '.net4.7.1-7zip-air-chrome-classicstart-firefox-java8-silverlight-vlc', + 'Legacy.exe': '.net4.7.2-7zip-chrome-firefox-sumatrapdf-vlc', + 'Modern.exe': '.net4.7.2-7zip-chrome-classicstart-firefox-sumatrapdf-vlc', }, 'Audio-Video': { 'AIMP.exe': 'aimp', @@ -202,3 +201,5 @@ RST_SOURCES = { if __name__ == '__main__': print("This file is not meant to be called directly.") + +# vim: sts=4 sw=4 ts=4 tw=0 nowrap From 31a3d5a43bddcd0644e3911e3892de8a351c71c9 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sun, 19 Aug 2018 12:04:11 -0700 Subject: [PATCH 15/36] Added D7_MODE to install_sw_bundle.py --- .bin/Scripts/install_sw_bundle.py | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/.bin/Scripts/install_sw_bundle.py b/.bin/Scripts/install_sw_bundle.py index d98eb8d2..e35760c3 100644 --- a/.bin/Scripts/install_sw_bundle.py +++ b/.bin/Scripts/install_sw_bundle.py @@ -10,6 +10,7 @@ from functions.setup import * init_global_vars() os.system('title {}: SW Bundle Tool'.format(KIT_NAME_FULL)) global_vars['LogFile'] = r'{LogDir}\Install SW Bundle.log'.format(**global_vars) +D7_MODE = 'd7mode' in sys.argv if __name__ == '__main__': try: @@ -25,10 +26,13 @@ if __name__ == '__main__': 'GenericRepair': 'Repaired', 'UnsupportedOSError': 'Unsupported OS', }} - answer_extensions = ask('Install Extensions?') - answer_adobe_reader = ask('Install Adobe Reader?') - answer_vcr = ask('Install Visual C++ Runtimes?') - answer_ninite = ask('Install Ninite Bundle?') + answer_extensions = D7_MODE or ask('Install Extensions?') + if D7_MODE: + answer_adobe_reader = False + else: + answer_adobe_reader = ask('Install Adobe Reader?') + answer_vcr = D7_MODE or ask('Install Visual C++ Runtimes?') + answer_ninite = D7_MODE or ask('Install Ninite Bundle?') if answer_ninite and global_vars['OS']['Version'] in ['7']: # Vista is dead, not going to check for it answer_mse = ask('Install MSE?') @@ -62,3 +66,5 @@ if __name__ == '__main__': pass except: major_exception() + +# vim: sts=4 sw=4 ts=4 From 4e022ed843036ef3a2d6e55e4bf2b876c99eba9b Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sun, 19 Aug 2018 12:14:34 -0700 Subject: [PATCH 16/36] Run DISM RestoreHealth in D7_MODE --- .bin/Scripts/system_diagnostics.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/.bin/Scripts/system_diagnostics.py b/.bin/Scripts/system_diagnostics.py index 4c0fe0a8..de5409b8 100644 --- a/.bin/Scripts/system_diagnostics.py +++ b/.bin/Scripts/system_diagnostics.py @@ -63,8 +63,12 @@ if __name__ == '__main__': function=run_chkdsk, other_results=other_results) try_and_print(message='SFC scan...', function=run_sfc_scan, other_results=other_results) - try_and_print(message='DISM CheckHealth...', - function=run_dism, other_results=other_results, repair=False) + if D7_MODE: + try_and_print(message='DISM RestoreHealth...', + function=run_dism, other_results=other_results, repair=True) + else: + try_and_print(message='DISM CheckHealth...', + function=run_dism, other_results=other_results, repair=False) if D7_MODE: @@ -131,3 +135,5 @@ if __name__ == '__main__': pass except: major_exception() + +# vim: sts=4 sw=4 ts=4 From 39f947bdd1d862354733814998dced9ffc40d99b Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sun, 19 Aug 2018 12:26:58 -0700 Subject: [PATCH 17/36] Leave SW Diags window open in D7_MODE on error(s) --- .bin/Scripts/system_diagnostics.py | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/.bin/Scripts/system_diagnostics.py b/.bin/Scripts/system_diagnostics.py index de5409b8..7709c5de 100644 --- a/.bin/Scripts/system_diagnostics.py +++ b/.bin/Scripts/system_diagnostics.py @@ -16,6 +16,17 @@ os.system('title {}: System Diagnostics Tool'.format(KIT_NAME_FULL)) global_vars['LogFile'] = r'{LogDir}\System Diagnostics.log'.format( **global_vars) D7_MODE = 'd7mode' in sys.argv +ERRORS = 0 + +def check_result(result, other_results): + """Check result for warnings and errors.""" + if not result['CS']: + for warning in other_results.get('Warning', {}).keys(): + if warning in str(result['Error']): + # Ignore warnings and repair statements + return + # Error is not a warning + ERRORS += 1 if __name__ == '__main__': try: @@ -58,14 +69,17 @@ if __name__ == '__main__': # OS Health Checks print_info('OS Health Checks') - try_and_print( + result = try_and_print( message='CHKDSK ({SYSTEMDRIVE})...'.format(**global_vars['Env']), function=run_chkdsk, other_results=other_results) - try_and_print(message='SFC scan...', + check_result(result, other_results) + result = try_and_print(message='SFC scan...', function=run_sfc_scan, other_results=other_results) + check_result(result, other_results) if D7_MODE: - try_and_print(message='DISM RestoreHealth...', + result = try_and_print(message='DISM RestoreHealth...', function=run_dism, other_results=other_results, repair=True) + check_result(result, other_results) else: try_and_print(message='DISM CheckHealth...', function=run_dism, other_results=other_results, repair=False) @@ -127,7 +141,7 @@ if __name__ == '__main__': print_error(' Unknown error.') # Done - if not D7_MODE: + if not D7_MODE or ERRORS > 0: print_standard('\nDone.') pause('Press Enter to exit...') exit_script() From 251c232a6e4302fa78b8ccd2d4d3617dd39637ab Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sun, 19 Aug 2018 12:50:36 -0700 Subject: [PATCH 18/36] Added Emsisoft a2cmd to system_checklist cleanup --- .bin/Scripts/functions/cleanup.py | 19 +++++++++++++++++++ .bin/Scripts/system_checklist.py | 6 ++++-- 2 files changed, 23 insertions(+), 2 deletions(-) diff --git a/.bin/Scripts/functions/cleanup.py b/.bin/Scripts/functions/cleanup.py index 1bac4c6c..bd2e3ec2 100644 --- a/.bin/Scripts/functions/cleanup.py +++ b/.bin/Scripts/functions/cleanup.py @@ -87,5 +87,24 @@ def cleanup_desktop(): except OSError: pass +def cleanup_emsisoft(): + """Remove EmsisoftCmd files from drive root.""" + source_path = r'{}\EmsisoftCmd'.format(global_vars['Env']['SYSTEMDRIVE']) + source_quarantine = r'{}\Quarantine'.format(source_path) + + # Quarantine + if os.path.exists(source_quarantine): + os.makedirs(global_vars['QuarantineDir'], exist_ok=True) + dest_name = r'{QuarantineDir}\Emsisoft_{Date-Time}'.format( + **global_vars) + dest_name = non_clobber_rename(dest_name) + shutil.move(source_quarantine, dest_name) + + # Remove program + if os.path.exists(source_path): + shutil.rmtree(source_path) + if __name__ == '__main__': print("This file is not meant to be called directly.") + +# vim: sts=4 sw=4 ts=4 diff --git a/.bin/Scripts/system_checklist.py b/.bin/Scripts/system_checklist.py index 33865daa..788af936 100644 --- a/.bin/Scripts/system_checklist.py +++ b/.bin/Scripts/system_checklist.py @@ -44,10 +44,12 @@ if __name__ == '__main__': # Cleanup print_info('Cleanup') - try_and_print(message='Desktop...', - function=cleanup_desktop, cs='Done') try_and_print(message='AdwCleaner...', function=cleanup_adwcleaner, cs='Done', other_results=other_results) + try_and_print(message='Desktop...', + function=cleanup_desktop, cs='Done') + try_and_print(message='Emsisoft a2cmd...', + function=cleanup_emsisoft, cs='Done') # Export system info if not D7_MODE: From 4f2f696d60e84b4a8ee5864a21429e4cd2c62d22 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sun, 19 Aug 2018 12:55:55 -0700 Subject: [PATCH 19/36] Adjust backup paths for cleanup functions --- .bin/Scripts/functions/cleanup.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.bin/Scripts/functions/cleanup.py b/.bin/Scripts/functions/cleanup.py index bd2e3ec2..a604a47c 100644 --- a/.bin/Scripts/functions/cleanup.py +++ b/.bin/Scripts/functions/cleanup.py @@ -24,7 +24,7 @@ def cleanup_adwcleaner(): # Main folder if os.path.exists(source_path): os.makedirs(global_vars['ProgBackupDir'], exist_ok=True) - dest_name = r'{ProgBackupDir}\AdwCleaner_{Date-Time}'.format( + dest_name = r'{ProgBackupDir}\{Date}\AdwCleaner\{Date-Time}'.format( **global_vars) dest_name = non_clobber_rename(dest_name) shutil.move(source_path, dest_name) @@ -70,7 +70,7 @@ def cleanup_cbs(dest_folder): def cleanup_desktop(): """Move known backup files and reports into the ClientDir.""" - dest_folder = r'{ProgBackupDir}\Desktop_{Date-Time}'.format(**global_vars) + dest_folder = r'{ProgBackupDir}\{Date}\Desktop\{Date-Time}'.format(**global_vars) os.makedirs(dest_folder, exist_ok=True) desktop_path = r'{USERPROFILE}\Desktop'.format(**global_vars['Env']) From 42c5e918b6aad693bc40a14eb449a257a855e604 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sun, 19 Aug 2018 13:12:03 -0700 Subject: [PATCH 20/36] Added Registry backups to system_checklist cleanup --- .bin/Scripts/functions/cleanup.py | 25 +++++++++++++++++++++++++ .bin/Scripts/system_checklist.py | 2 ++ 2 files changed, 27 insertions(+) diff --git a/.bin/Scripts/functions/cleanup.py b/.bin/Scripts/functions/cleanup.py index a604a47c..945938a9 100644 --- a/.bin/Scripts/functions/cleanup.py +++ b/.bin/Scripts/functions/cleanup.py @@ -104,6 +104,31 @@ def cleanup_emsisoft(): if os.path.exists(source_path): shutil.rmtree(source_path) +def cleanup_regbackups(): + """Move d7ii regbackups into backup folder.""" + source_path = r'{}\Support\RegBackups'.format( + global_vars['Env']['SYSTEMDRIVE']) + + # Bail early + if not os.path.exists(source_path): + return + + # Move to backup folder + for entry in os.scandir(source_path): + os.makedirs(global_vars['ProgBackupDir'], exist_ok=True) + dest_path = r'{ProgBackupDir}\{Date}\Registry\{name}'.format( + name=entry.name, + **global_vars) + dest_path = non_clobber_rename(dest_path) + shutil.move(entry.path, dest_path) + + # Delete source folders if empty + try: + os.rmdir(source_path) + os.rmdir(r'{}\Support'.format(global_vars['Env']['SYSTEMDRIVE'])) + except OSError: + pass + if __name__ == '__main__': print("This file is not meant to be called directly.") diff --git a/.bin/Scripts/system_checklist.py b/.bin/Scripts/system_checklist.py index 788af936..6fdbcf79 100644 --- a/.bin/Scripts/system_checklist.py +++ b/.bin/Scripts/system_checklist.py @@ -50,6 +50,8 @@ if __name__ == '__main__': function=cleanup_desktop, cs='Done') try_and_print(message='Emsisoft a2cmd...', function=cleanup_emsisoft, cs='Done') + try_and_print(message='Registry Backup(s)...', + function=cleanup_regbackups, cs='Done') # Export system info if not D7_MODE: From edb82df4d3d7c96a9b3bd8b1b04385ef999cb55f Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sun, 19 Aug 2018 13:24:39 -0700 Subject: [PATCH 21/36] Move AdwCleaner/Desktop to LogDir during cleanup * Instead of ProgBackupDir --- .bin/Scripts/functions/cleanup.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.bin/Scripts/functions/cleanup.py b/.bin/Scripts/functions/cleanup.py index 945938a9..c02e3665 100644 --- a/.bin/Scripts/functions/cleanup.py +++ b/.bin/Scripts/functions/cleanup.py @@ -23,8 +23,8 @@ def cleanup_adwcleaner(): # Main folder if os.path.exists(source_path): - os.makedirs(global_vars['ProgBackupDir'], exist_ok=True) - dest_name = r'{ProgBackupDir}\{Date}\AdwCleaner\{Date-Time}'.format( + os.makedirs(global_vars['LogDir'], exist_ok=True) + dest_name = r'{LogDir}\{Date}\AdwCleaner'.format( **global_vars) dest_name = non_clobber_rename(dest_name) shutil.move(source_path, dest_name) @@ -70,7 +70,7 @@ def cleanup_cbs(dest_folder): def cleanup_desktop(): """Move known backup files and reports into the ClientDir.""" - dest_folder = r'{ProgBackupDir}\{Date}\Desktop\{Date-Time}'.format(**global_vars) + dest_folder = r'{ProgBackupDir}\{Date}\Desktop'.format(**global_vars) os.makedirs(dest_folder, exist_ok=True) desktop_path = r'{USERPROFILE}\Desktop'.format(**global_vars['Env']) From 9c1c8b90be797a0b8026bf4ab66ea3323e0ecea8 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sun, 19 Aug 2018 14:10:37 -0700 Subject: [PATCH 22/36] Added d7II Cleanup sections * Renamed d7_firefox_fix.py to post_d7.py * This will include all items that need to be run outside d7II --- .bin/Scripts/functions/cleanup.py | 67 +++++++++++++++++++ .../Scripts/{d7_firefox_fix.py => post_d7.py} | 12 ++-- 2 files changed, 75 insertions(+), 4 deletions(-) rename .bin/Scripts/{d7_firefox_fix.py => post_d7.py} (78%) diff --git a/.bin/Scripts/functions/cleanup.py b/.bin/Scripts/functions/cleanup.py index c02e3665..f2986571 100644 --- a/.bin/Scripts/functions/cleanup.py +++ b/.bin/Scripts/functions/cleanup.py @@ -68,6 +68,73 @@ def cleanup_cbs(dest_folder): r'{}\CbsPersist*'.format(temp_folder)] run_program(cmd) +def cleanup_d7ii(): + """Sort d7II logs and remove temp items.""" + d7_path = r'{}\d7II'.format(global_vars['ClientDir']) + d7_reports = r'{}_Reports'.format(d7_path) + d7_temp = r'{}\Temp'.format(d7_path) + + # Logs & Reports + if os.path.exists(d7_reports): + for entry in os.scandir(d7_reports): + r = re.match(r'(\d+)-(\d+)-(\d+)', entry.name) + d7_date = '{}-{:02d}-{:02d}'.format( + r.group(1), int(r.group(2)), int(r.group(3))) + d7_mlogs = r'{}\Malware Logs'.format(entry.path) + log_dest = r'{SYSTEMDRIVE}\{prefix}\Info\{date}'.format( + prefix=KIT_NAME_SHORT, + date=d7_date, + **global_vars['Env']) + + # Remove empty folders + for f in ('Malware Logs', 'Screen Shots'): + try: + os.rmdir(r'{}\{}'.format(entry.path, f)) + except FileNotFoundError: + pass + except OSError: + pass + + # Malware Logs + if os.path.exists(d7_mlogs): + for m_entry in os.scandir(d7_mlogs): + prefix = '' + if m_entry.name == 'MalwareScan_Report.txt': + prefix = 'd7II_' + dest_path = r'{log_dest}\{prefix}{name}'.format( + log_dest=log_dest, + prefix=prefix, + name=m_entry.name) + dest_path = non_clobber_rename(dest_path) + shutil.move(entry.path, dest_path) + try: + os.rmdir(d7_mlogs) + except OSError: + pass + + # Other items + for o_entry in os.scandir(entry.path): + dest_path = r'{log_dest}\d7II_{name}'.format( + log_dest=log_dest, + name=m_entry.name) + dest_path = non_clobber_rename(dest_path) + shutil.move(entry.path, dest_path) + + # Remove folder if empty + try: + os.rmdir(entry.path) + except OSError: + pass + + # Temp items + if os.path.exists(d7_path): + if os.path.exists(d7_temp): + shutil.rmtree(d7_temp) + try: + os.rmdir(d7_path) + except OSError: + pass + def cleanup_desktop(): """Move known backup files and reports into the ClientDir.""" dest_folder = r'{ProgBackupDir}\{Date}\Desktop'.format(**global_vars) diff --git a/.bin/Scripts/d7_firefox_fix.py b/.bin/Scripts/post_d7.py similarity index 78% rename from .bin/Scripts/d7_firefox_fix.py rename to .bin/Scripts/post_d7.py index 7fe1f244..1bdfc4f3 100644 --- a/.bin/Scripts/d7_firefox_fix.py +++ b/.bin/Scripts/post_d7.py @@ -1,4 +1,4 @@ -# Wizard Kit: Install uBlock Origin for Firefox +# Wizard Kit: Post-d7II items import os import sys @@ -10,16 +10,15 @@ from functions.browsers import * from functions.cleanup import * from functions.setup import * init_global_vars() -os.system('title {}: User Checklist Tool'.format(KIT_NAME_FULL)) +os.system('title {}: Post-d7II Work'.format(KIT_NAME_FULL)) global_vars['LogFile'] = r'{LogDir}\User Checklist ({USERNAME}).log'.format( **global_vars, **global_vars['Env']) -D7_MODE = 'd7mode' in sys.argv if __name__ == '__main__': try: stay_awake() clear_screen() - print_info('{}: Firefox Fix for d7\n'.format(KIT_NAME_FULL)) + print_info('{}: Post-d7II Work\n'.format(KIT_NAME_FULL)) other_results = { 'Warning': { 'NotInstalledError': 'Not installed', @@ -34,6 +33,11 @@ if __name__ == '__main__': print_info('Installing uBlock Origin') install_adblock(just_firefox=True) + # Cleanup + print_info('Cleanup') + try_and_print(message='d7II...', + function=cleanup_d7ii, cs='Done') + # Done print_standard('\nDone.') pause('Press Enter to exit...') From 6f3a1ee55f933959ec8a82b438ba1d88eae4ce59 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sun, 19 Aug 2018 15:18:29 -0700 Subject: [PATCH 23/36] Run BleachBit cleaners directly and allow cleaning * Using the cleaner names to ensure desired cleanup * Using the --preset option could lead to unintended deletions * Cleaning is automatic in D7_MODE --- .bin/Scripts/functions/info.py | 59 +++++++++++++++---------- .bin/Scripts/system_diagnostics.py | 69 +++++++++++++++++++++++++++++- 2 files changed, 104 insertions(+), 24 deletions(-) diff --git a/.bin/Scripts/functions/info.py b/.bin/Scripts/functions/info.py index b81a4922..5f7f3631 100644 --- a/.bin/Scripts/functions/info.py +++ b/.bin/Scripts/functions/info.py @@ -162,7 +162,7 @@ def get_installed_office(): def get_shell_path(folder, user='current'): """Get shell path using SHGetKnownFolderPath via knownpaths, returns str. - + NOTE: Only works for the current user. Code based on https://gist.github.com/mkropat/7550097 """ @@ -175,14 +175,14 @@ def get_shell_path(folder, user='current'): except AttributeError: # Unknown folder ID, ignore and return None pass - + if folderid: try: path = knownpaths.get_path(folderid, getattr(knownpaths.UserHandle, user)) except PathNotFoundError: # Folder not found, ignore and return None pass - + return path def get_user_data_paths(user): @@ -196,7 +196,7 @@ def get_user_data_paths(user): 'Extra Folders': {}, } unload_hive = False - + if user['Name'] == global_vars['Env']['USERNAME']: # We can use SHGetKnownFolderPath for the current user paths['Profile']['Path'] = get_shell_path('Profile') @@ -212,7 +212,7 @@ def get_user_data_paths(user): except Exception: # Profile path not found, leaving as None. pass - + # Shell folders (Prep) if not reg_path_exists(HKU, hive_path) and paths['Profile']['Path']: # User not logged-in, loading hive @@ -226,7 +226,7 @@ def get_user_data_paths(user): except subprocess.CalledProcessError: # Failed to load user hive pass - + # Shell folders shell_folders = r'{}\{}'.format(hive_path, REG_SHELL_FOLDERS) if (reg_path_exists(HKU, hive_path) @@ -252,7 +252,7 @@ def get_user_data_paths(user): if (folder not in paths['Shell Folders'] and os.path.exists(folder_path)): paths['Shell Folders'][folder] = {'Path': folder_path} - + # Extra folders if paths['Profile']['Path']: for folder in EXTRA_FOLDERS: @@ -260,12 +260,12 @@ def get_user_data_paths(user): folder=folder, **paths['Profile']) if os.path.exists(folder_path): paths['Extra Folders'][folder] = {'Path': folder_path} - + # Shell folders (cleanup) if unload_hive: cmd = ['reg', 'unload', r'HKU\{}'.format(TMP_HIVE_PATH)] run_program(cmd, check=False) - + # Done return paths @@ -277,7 +277,7 @@ def get_user_folder_sizes(users): with winreg.OpenKey(HKCU, r'Software\Sysinternals\Du', access=winreg.KEY_WRITE) as key: winreg.SetValueEx(key, 'EulaAccepted', 0, winreg.REG_DWORD, 1) - + for u in users: u.update(get_user_data_paths(u)) if u['Profile']['Path']: @@ -292,7 +292,7 @@ def get_user_folder_sizes(users): def get_user_list(): """Get user list via WMIC, returns list of dicts.""" users = [] - + # Get user info from WMI cmd = ['wmic', 'useraccount', 'get', '/format:csv'] try: @@ -300,10 +300,10 @@ def get_user_list(): except subprocess.CalledProcessError: # Meh, return empty list to avoid a full crash return users - + entries = out.stdout.decode().splitlines() entries = [e.strip().split(',') for e in entries if e.strip()] - + # Add user(s) to dict keys = entries[0] for e in entries[1:]: @@ -314,10 +314,10 @@ def get_user_list(): # Assume SIDs ending with 1000+ are "Standard" and others are "System" e['Type'] = 'Standard' if re.search(r'-1\d+$', e['SID']) else 'System' users.append(e) - + # Sort list users.sort(key=itemgetter('Name')) - + # Done return users @@ -368,23 +368,38 @@ def run_aida64(): '/TEXT', '/SILENT', '/SAFEST'] run_program(cmd, check=False) -def run_bleachbit(): +def run_bleachbit(cleaners=None, preview=True): """Run BleachBit preview and save log. - + This is a preview so no files should be deleted.""" if not os.path.exists(global_vars['LogDir']+r'\BleachBit.log'): + debug_path = r'{}\BleachBit.debug'.format(global_vars['LogDir']) + error_path = debug_path.replace('debug', 'err') + log_path = debug_path.replace('debug', 'log') extract_item('BleachBit', silent=True) - cmd = [global_vars['Tools']['BleachBit'], '--preview', '--preset'] + + # Safety check + if not cleaners: + # Disable cleaning and use preset config + cleaners = ['--preset'] + preview = True + + # Run + cmd = [ + global_vars['Tools']['BleachBit'], + '--preview' if preview else '--clean', + '--debug-log="{}"'.format(debug_path)] + cmd.extend(cleaners) out = run_program(cmd, check=False) + # Save stderr if out.stderr.decode().splitlines(): - with open(global_vars['LogDir']+r'\BleachBit.err', 'a', - encoding='utf-8') as f: + with open(error_path, 'a', encoding='utf-8') as f: for line in out.stderr.decode().splitlines(): f.write(line.strip() + '\n') + # Save stdout - with open(global_vars['LogDir']+r'\BleachBit.log', 'a', - encoding='utf-8') as f: + with open(log_path, 'a', encoding='utf-8') as f: for line in out.stdout.decode().splitlines(): f.write(line.strip() + '\n') diff --git a/.bin/Scripts/system_diagnostics.py b/.bin/Scripts/system_diagnostics.py index 7709c5de..535b14ef 100644 --- a/.bin/Scripts/system_diagnostics.py +++ b/.bin/Scripts/system_diagnostics.py @@ -18,6 +18,65 @@ global_vars['LogFile'] = r'{LogDir}\System Diagnostics.log'.format( D7_MODE = 'd7mode' in sys.argv ERRORS = 0 +# Static Variables +BLEACH_BIT_CLEANERS = { + 'Applications': ( + 'adobe_reader.cache', + 'adobe_reader.tmp', + 'amule.tmp', + 'flash.cache', + 'gimp.tmp', + 'hippo_opensim_viewer.cache', + 'java.cache', + 'libreoffice.cache', + 'liferea.cache', + 'miro.cache', + 'openofficeorg.cache', + 'pidgin.cache', + 'secondlife_viewer.Cache', + 'thunderbird.cache', + 'vuze.backup_files', + 'vuze.cache', + 'vuze.tmp', + 'yahoo_messenger.cache', + ), + 'Browsers': ( + 'chromium.cache', + 'chromium.current_session', + 'chromium.history', + 'firefox.cache', + 'firefox.download_history', + 'firefox.session_restore', + 'firefox.url_history', + 'google_chrome.cache', + 'google_chrome.history', + 'google_chrome.session', + 'google_earth.temporary_files', + 'google_toolbar.search_history', + 'internet_explorer.history', + 'internet_explorer.temporary_files', + 'opera.cache', + 'opera.current_session', + 'opera.download_history', + 'opera.url_history', + 'safari.cache', + 'safari.history', + 'seamonkey.cache', + 'seamonkey.download_history', + 'seamonkey.history', + ), + 'System': ( + 'system.clipboard', + 'system.tmp', + 'winapp2_windows.jump_lists', + 'winapp2_windows.ms_search', + 'windows_explorer.run', + 'windows_explorer.search_history', + 'windows_explorer.thumbnails', + ), +} + + def check_result(result, other_results): """Check result for warnings and errors.""" if not result['CS']: @@ -93,12 +152,18 @@ if __name__ == '__main__': print_info('Scanning for browsers') scan_for_browsers() + # Run BleachBit cleaners + print_info('BleachBit Cleanup') + for k, v in sorted(BLEACH_BIT_CLEANERS.items()): + try_and_print(message=' {}...'.format(k), + function=run_bleachbit, + cs='Done', other_results=other_results, + cleaners=v, preview=bool(not D7_MODE)) + # Export system info print_info('Backup System Information') try_and_print(message='AIDA64 reports...', function=run_aida64, cs='Done', other_results=other_results) - try_and_print(message='BleachBit report...', - function=run_bleachbit, cs='Done', other_results=other_results) if not D7_MODE: backup_browsers() try_and_print(message='File listing...', From 84120f150528454e6b33fa2d898046f5fc875168 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sun, 19 Aug 2018 15:59:58 -0700 Subject: [PATCH 24/36] Adjusted launchers for d7II --- .bin/Scripts/settings/launchers.py | 65 +++++++++++++++++++++++------- 1 file changed, 50 insertions(+), 15 deletions(-) diff --git a/.bin/Scripts/settings/launchers.py b/.bin/Scripts/settings/launchers.py index 6e011691..2b7de0e6 100644 --- a/.bin/Scripts/settings/launchers.py +++ b/.bin/Scripts/settings/launchers.py @@ -14,16 +14,45 @@ LAUNCHERS = { 'L_ITEM': 'system_checklist.py', 'L_ELEV': 'True', }, + 'User Checklist': { + 'L_TYPE': 'PyScript', + 'L_PATH': 'Scripts', + 'L_ITEM': 'user_checklist.py', + }, + }, + r'.bin\Scripts\launchers_for_d7': { + 'Browser Reset': { + 'L_TYPE': 'PyScript', + 'L_PATH': 'Scripts', + 'L_ITEM': 'reset_browsers.py', + 'L_ARGS': 'd7mode', + }, + 'Install SW Bundle': { + 'L_TYPE': 'PyScript', + 'L_PATH': 'Scripts', + 'L_ITEM': 'install_sw_bundle.py', + 'L_ARGS': 'd7mode', + 'L_ELEV': 'True', + }, + 'System Checklist': { + 'L_TYPE': 'PyScript', + 'L_PATH': 'Scripts', + 'L_ITEM': 'system_checklist.py', + 'L_ARGS': 'd7mode', + 'L_ELEV': 'True', + }, 'System Diagnostics': { 'L_TYPE': 'PyScript', 'L_PATH': 'Scripts', 'L_ITEM': 'system_diagnostics.py', + 'L_ARGS': 'd7mode', 'L_ELEV': 'True', }, 'User Checklist': { 'L_TYPE': 'PyScript', 'L_PATH': 'Scripts', 'L_ITEM': 'user_checklist.py', + 'L_ARGS': 'd7mode', }, }, r'Data Recovery': { @@ -188,17 +217,10 @@ LAUNCHERS = { }, }, r'Diagnostics': { - 'HWiNFO': { + 'AIDA64': { 'L_TYPE': 'Executable', - 'L_PATH': 'HWiNFO', - 'L_ITEM': 'HWiNFO.exe', - 'Extra Code': [ - r'for %%a in (32 64) do (', - r' copy /y "%bin%\HWiNFO\general.ini" "%bin%\HWiNFO\HWiNFO%%a.ini"', - r' (echo SensorsOnly=0)>>"%bin%\HWiNFO\HWiNFO%%a.ini"', - r' (echo SummaryOnly=0)>>"%bin%\HWiNFO\HWiNFO%%a.ini"', - r')', - ], + 'L_PATH': 'AIDA64', + 'L_ITEM': 'aida64.exe', }, 'ProduKey': { 'L_TYPE': 'Executable', @@ -212,13 +234,14 @@ LAUNCHERS = { r')', ], }, + 'System Diagnostics': { + 'L_TYPE': 'PyScript', + 'L_PATH': 'Scripts', + 'L_ITEM': 'system_diagnostics.py', + 'L_ELEV': 'True', + }, }, r'Diagnostics\Extras': { - 'AIDA64': { - 'L_TYPE': 'Executable', - 'L_PATH': 'AIDA64', - 'L_ITEM': 'aida64.exe', - }, 'Autoruns (with VirusTotal Scan)': { 'L_TYPE': 'Executable', 'L_PATH': 'Autoruns', @@ -265,6 +288,18 @@ LAUNCHERS = { r'call "%bin%\Scripts\init_client_dir.cmd" /Info', ], }, + 'HWiNFO': { + 'L_TYPE': 'Executable', + 'L_PATH': 'HWiNFO', + 'L_ITEM': 'HWiNFO.exe', + 'Extra Code': [ + r'for %%a in (32 64) do (', + r' copy /y "%bin%\HWiNFO\general.ini" "%bin%\HWiNFO\HWiNFO%%a.ini"', + r' (echo SensorsOnly=0)>>"%bin%\HWiNFO\HWiNFO%%a.ini"', + r' (echo SummaryOnly=0)>>"%bin%\HWiNFO\HWiNFO%%a.ini"', + r')', + ], + }, 'HWiNFO (Sensors)': { 'L_TYPE': 'Executable', 'L_PATH': 'HWiNFO', From 2301c89b8c9cce14dbbd454683a7ed7279fd886b Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sun, 19 Aug 2018 17:32:55 -0700 Subject: [PATCH 25/36] Add ESET NOD32 AV install sections * Installs with custom config --- .bin/Scripts/functions/setup.py | 30 +- .bin/Scripts/functions/update.py | 7 + .bin/Scripts/install_eset_nod32_av.py | 26 + .bin/Scripts/settings/launchers.py | 6 + .bin/Scripts/settings/sources.py | 1 + .../ESETConfigs/eset-config-no-pup.xml | 1668 +++++++++++++++++ .cbin/_include/ESETConfigs/eset-config.xml | 1668 +++++++++++++++++ 7 files changed, 3404 insertions(+), 2 deletions(-) create mode 100644 .bin/Scripts/install_eset_nod32_av.py create mode 100644 .cbin/_include/ESETConfigs/eset-config-no-pup.xml create mode 100644 .cbin/_include/ESETConfigs/eset-config.xml diff --git a/.bin/Scripts/functions/setup.py b/.bin/Scripts/functions/setup.py index d08692b5..8de759bc 100644 --- a/.bin/Scripts/functions/setup.py +++ b/.bin/Scripts/functions/setup.py @@ -1,6 +1,8 @@ # Wizard Kit: Functions - Setup from functions.common import * +from functions.update import * +from settings.sources import * # STATIC VARIABLES HKCU = winreg.HKEY_CURRENT_USER @@ -180,7 +182,7 @@ def write_registry_settings(settings, all_users=False): if 'WOW64_32' in v: access = access | winreg.KEY_WOW64_32KEY winreg.CreateKeyEx(hive, k, 0, access) - + # Create values with winreg.OpenKeyEx(hive, k, 0, access) as key: for name, value in v.get('DWORD Items', {}).items(): @@ -237,6 +239,30 @@ def install_classicstart_skin(): os.makedirs(dest_path, exist_ok=True) shutil.copy(source, dest) +def install_eset_nod32_av(scan_pups=True): + """Install ESET NOD32 AV with custom config.""" + extract_item('ESETConfigs', silent=True) + config_file = '{BinDir}\ESETConfigs\{config_file}.xml'.format( + config_file='eset-config' if scan_pups else 'eset-config-no-pup', + **global_vars) + + # Download + result = try_and_print(message='Downloading Setup...', cs='Done', + other_results=OTHER_RESULTS, function=download_generic, + out_dir=global_vars['ClientDir'], + out_name='eav_nt64.exe', + source_url=SOURCE_URLS['ESET NOD32']) + if not result['CS']: + raise GenericError('Failed to download ESET NOD32') + + # Install + cmd = [r'{ClientDir}\eav_nt64.exe'.format(**global_vars), + '--silent', '--accepteula', '--msi-property', + 'PRODUCTTYPE=eav', 'PRODUCT_LANG=1033', 'PRODUCT_LANG_CODE=en-US', + 'ADMINCFG="{}"'.format(config_file)] + try_and_print(message='Installing ESET NOD32 AV...', + other_results=OTHER_RESULTS, function=run_program, cmd=cmd) + def install_firefox_extensions(): """Extract Firefox extensions to installation folder.""" dist_path = r'{PROGRAMFILES}\Mozilla Firefox\distribution\extensions'.format( @@ -244,7 +270,7 @@ def install_firefox_extensions(): source_path = r'{CBinDir}\FirefoxExtensions.7z'.format(**global_vars) if not os.path.exists(source_path): raise FileNotFoundError - + # Extract extension(s) to distribution folder cmd = [ global_vars['Tools']['SevenZip'], 'x', '-aos', '-bso0', '-bse0', diff --git a/.bin/Scripts/functions/update.py b/.bin/Scripts/functions/update.py index 6825f9ba..b324b2c8 100644 --- a/.bin/Scripts/functions/update.py +++ b/.bin/Scripts/functions/update.py @@ -551,6 +551,13 @@ def update_adobe_reader_dc(): download_generic( dest, 'Adobe Reader DC.exe', SOURCE_URLS['Adobe Reader DC']) +def update_eset_config(): + """Copy config files to .cbin before compress_item""" + dest = r'{}\ESETConfigs'.format(global_vars['cbindir']) + include_path = r'{}\_include\ESETConfigs'.format(global_vars['CBinDir']) + if os.path.exists(include_path): + shutil.copytree(include_path, dest) + def update_office(): # Remove existing folders remove_from_kit('_Office') diff --git a/.bin/Scripts/install_eset_nod32_av.py b/.bin/Scripts/install_eset_nod32_av.py new file mode 100644 index 00000000..1bb45d9a --- /dev/null +++ b/.bin/Scripts/install_eset_nod32_av.py @@ -0,0 +1,26 @@ +# Wizard Kit: Install ESET NOD32 AV + +import os +import sys + +# Init +os.chdir(os.path.dirname(os.path.realpath(__file__))) +sys.path.append(os.getcwd()) +from functions.setup import * +init_global_vars() +os.system('title {}: Install ESET NOD32 AV'.format(KIT_NAME_FULL)) +global_vars['LogFile'] = r'{LogDir}\Install ESET NOD32 AV.log'.format(**global_vars) + +if __name__ == '__main__': + try: + stay_awake() + clear_screen() + print_info('{}: Install ESET NOD32 AV\n'.format(KIT_NAME_FULL)) + scan_pups = ask('Enable PUP scans in ESET?') + install_eset_nod32_av(scan_pups) + print_standard('\nDone.') + exit_script() + except SystemExit: + pass + except: + major_exception() diff --git a/.bin/Scripts/settings/launchers.py b/.bin/Scripts/settings/launchers.py index 2b7de0e6..ac4e9da5 100644 --- a/.bin/Scripts/settings/launchers.py +++ b/.bin/Scripts/settings/launchers.py @@ -8,6 +8,12 @@ LAUNCHERS = { 'L_ITEM': 'activate.py', 'L_ELEV': 'True', }, + 'Install ESET NOD32 AV': { + 'L_TYPE': 'PyScript', + 'L_PATH': 'Scripts', + 'L_ITEM': 'install_eset_nod32_av.py', + 'L_ELEV': 'True', + }, 'System Checklist': { 'L_TYPE': 'PyScript', 'L_PATH': 'Scripts', diff --git a/.bin/Scripts/settings/sources.py b/.bin/Scripts/settings/sources.py index 195a10bb..8fc17af8 100644 --- a/.bin/Scripts/settings/sources.py +++ b/.bin/Scripts/settings/sources.py @@ -12,6 +12,7 @@ SOURCE_URLS = { 'ClassicStartSkin': 'http://www.classicshell.net/forum/download/file.php?id=3001&sid=9a195960d98fd754867dcb63d9315335', 'Du': 'https://download.sysinternals.com/files/DU.zip', 'ERUNT': 'http://www.aumha.org/downloads/erunt.zip', + 'ESET NOD32 AV': 'https://download.eset.com/com/eset/apps/home/eav/windows/latest/eav_nt64.exe', 'Everything32': 'https://www.voidtools.com/Everything-1.4.1.895.x86.zip', 'Everything64': 'https://www.voidtools.com/Everything-1.4.1.895.x64.zip', 'FastCopy32': 'http://ftp.vector.co.jp/69/93/2323/FastCopy341.zip', diff --git a/.cbin/_include/ESETConfigs/eset-config-no-pup.xml b/.cbin/_include/ESETConfigs/eset-config-no-pup.xml new file mode 100644 index 00000000..ac4e010e --- /dev/null +++ b/.cbin/_include/ESETConfigs/eset-config-no-pup.xml @@ -0,0 +1,1668 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/.cbin/_include/ESETConfigs/eset-config.xml b/.cbin/_include/ESETConfigs/eset-config.xml new file mode 100644 index 00000000..31804d40 --- /dev/null +++ b/.cbin/_include/ESETConfigs/eset-config.xml @@ -0,0 +1,1668 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 33d1f42002f6e252ae4d442f98c83dc5ddeb782d Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Sun, 19 Aug 2018 18:09:39 -0700 Subject: [PATCH 26/36] Add WinAIO Repair --- .bin/Scripts/functions/update.py | 255 ++++++++++++---------- .bin/Scripts/settings/launchers.py | 6 + .bin/Scripts/settings/sources.py | 1 + .bin/Scripts/update_kit.py | 1 + .cbin/_include/WinAIO Repair/settings.ini | Bin 0 -> 10338 bytes 5 files changed, 147 insertions(+), 116 deletions(-) create mode 100644 .cbin/_include/WinAIO Repair/settings.ini diff --git a/.bin/Scripts/functions/update.py b/.bin/Scripts/functions/update.py index b324b2c8..a879560a 100644 --- a/.bin/Scripts/functions/update.py +++ b/.bin/Scripts/functions/update.py @@ -28,7 +28,7 @@ def compress_item(item): wd = os.path.abspath(r'{}\{}'.format(wd, os.path.pardir)) include_str = item.name os.chdir(wd) - + # Compress cmd = [ global_vars['Tools']['SevenZip'], @@ -38,7 +38,7 @@ def compress_item(item): include_str, ] run_program(cmd) - + # Done os.chdir(prev_dir) @@ -96,7 +96,7 @@ def generate_launcher(section, name, options): dest = global_vars['BaseDir'] full_path = r'{}\{}.cmd'.format(dest, name) template = r'{}\Scripts\Launcher_Template.cmd'.format(global_vars['BinDir']) - + # Format options f_options = {} for opt in options.keys(): @@ -106,7 +106,7 @@ def generate_launcher(section, name, options): elif re.search(r'^L_\w+', opt, re.IGNORECASE): new_opt = 'set {}='.format(opt) f_options[new_opt] = ['set {}={}'.format(opt, options[opt])] - + # Read template and update using f_options out_text = [] with open(template, 'r') as f: @@ -118,7 +118,7 @@ def generate_launcher(section, name, options): out_text.extend(f_options[line]) else: out_text.append(line) - + # Write file os.makedirs(dest, exist_ok=True) with open(full_path, 'w') as f: @@ -172,7 +172,7 @@ def scan_for_net_installers(server, family_name, min_year): """Scan network shares for installers.""" if not server['Mounted']: mount_network_share(server) - + if server['Mounted']: for year in os.scandir(r'\\{IP}\{Share}'.format(**server)): try: @@ -204,13 +204,13 @@ def update_testdisk(): for exe in ['fidentify_win.exe', 'photorec_win.exe', 'qphotorec_win.exe', 'testdisk_win.exe']: kill_process(exe) - + # Remove existing folders remove_from_kit('TestDisk') - + # Download download_to_temp('testdisk_wip.zip', SOURCE_URLS['TestDisk']) - + # Extract files extract_temp_to_cbin('testdisk_wip.zip', 'TestDisk') dest = r'{}\TestDisk'.format(global_vars['CBinDir']) @@ -220,7 +220,7 @@ def update_testdisk(): shutil.move(item.path, dest_item) shutil.rmtree( r'{}\TestDisk\testdisk-7.1-WIP'.format(global_vars['CBinDir'])) - + # Cleanup remove_from_temp('testdisk_wip.zip') @@ -230,21 +230,21 @@ def update_fastcopy(): # Stop running processes for process in ['FastCopy.exe', 'FastCopy64.exe']: kill_process(process) - + # Remove existing folders remove_from_kit('FastCopy') - + # Download download_to_temp('FastCopy32.zip', SOURCE_URLS['FastCopy32']) download_to_temp('FastCopy64.zip', SOURCE_URLS['FastCopy64']) - + # Extract extract_temp_to_bin('FastCopy64.zip', 'FastCopy', sz_args=['FastCopy.exe']) shutil.move( r'{}\FastCopy\FastCopy.exe'.format(global_vars['BinDir']), r'{}\FastCopy\FastCopy64.exe'.format(global_vars['BinDir'])) extract_temp_to_bin('FastCopy32.zip', 'FastCopy', sz_args=[r'-x!setup.exe', r'-x!*.dll']) - + # Cleanup remove_from_temp('FastCopy32.zip') remove_from_temp('FastCopy64.zip') @@ -252,14 +252,14 @@ def update_fastcopy(): def update_wimlib(): # Stop running processes kill_process('wimlib-imagex.exe') - + # Remove existing folders remove_from_kit('wimlib') - + # Download download_to_temp('wimlib32.zip', SOURCE_URLS['wimlib32']) download_to_temp('wimlib64.zip', SOURCE_URLS['wimlib64']) - + # Extract extract_generic( r'{}\wimlib32.zip'.format(global_vars['TmpDir']), @@ -267,7 +267,7 @@ def update_wimlib(): extract_generic( r'{}\wimlib64.zip'.format(global_vars['TmpDir']), r'{}\wimlib\x64'.format(global_vars['CBinDir'])) - + # Cleanup remove_from_temp('wimlib32.zip') remove_from_temp('wimlib64.zip') @@ -275,16 +275,16 @@ def update_wimlib(): def update_xyplorer(): # Stop running processes kill_process('XYplorerFree.exe') - + # Remove existing folders remove_from_kit('XYplorerFree') - + # Download download_to_temp('xyplorer_free.zip', SOURCE_URLS['XYplorerFree']) - + # Extract files extract_temp_to_cbin('xyplorer_free.zip', 'XYplorerFree') - + # Cleanup remove_from_temp('xyplorer_free.zip') @@ -292,16 +292,16 @@ def update_xyplorer(): def update_aida64(): # Stop running processes kill_process('notepadplusplus.exe') - + # Remove existing folders remove_from_kit('AIDA64') - + # Download download_to_temp('aida64.zip', SOURCE_URLS['AIDA64']) - + # Extract files extract_temp_to_cbin('aida64.zip', 'AIDA64') - + # Cleanup remove_from_temp('aida64.zip') @@ -309,37 +309,37 @@ def update_autoruns(): # Stop running processes kill_process('Autoruns.exe') kill_process('Autoruns64.exe') - + # Remove existing folders remove_from_kit('Autoruns') - + # Download download_to_temp('Autoruns.zip', SOURCE_URLS['Autoruns']) - + # Extract files extract_temp_to_cbin('Autoruns.zip', 'Autoruns') - + # Cleanup remove_from_temp('Autoruns.zip') def update_bleachbit(): # Stop running processes kill_process('bleachbit.exe') - + # Remove existing folders remove_from_kit('BleachBit') - + # Download download_to_temp('bleachbit.zip', SOURCE_URLS['BleachBit']) download_to_temp('Winapp2.zip', SOURCE_URLS['Winapp2']) - + # Extract files extract_temp_to_cbin('bleachbit.zip', 'BleachBit') extract_generic( r'{}\Winapp2.zip'.format(global_vars['TmpDir']), r'{}\BleachBit\cleaners'.format(global_vars['CBinDir']), mode='e', sz_args=[r'Winapp2-master\Non-CCleaner\Winapp2.ini']) - + # Move files into place dest = r'{}\BleachBit'.format(global_vars['CBinDir']) for item in os.scandir(r'{}\BleachBit-Portable'.format(dest)): @@ -348,7 +348,7 @@ def update_bleachbit(): shutil.move(item.path, dest_item) shutil.rmtree( r'{}\BleachBit\BleachBit-Portable'.format(global_vars['CBinDir'])) - + # Cleanup remove_from_temp('bleachbit.zip') remove_from_temp('Winapp2.zip') @@ -357,21 +357,21 @@ def update_bluescreenview(): # Stop running processes for exe in ['BlueScreenView.exe', 'BlueScreenView64.exe']: kill_process(exe) - + # Remove existing folders remove_from_kit('BlueScreenView') - + # Download download_to_temp('bluescreenview32.zip', SOURCE_URLS['BlueScreenView32']) download_to_temp('bluescreenview64.zip', SOURCE_URLS['BlueScreenView64']) - + # Extract files extract_temp_to_cbin('bluescreenview64.zip', 'BlueScreenView', sz_args=['BlueScreenView.exe']) shutil.move( r'{}\BlueScreenView\BlueScreenView.exe'.format(global_vars['CBinDir']), r'{}\BlueScreenView\BlueScreenView64.exe'.format(global_vars['CBinDir'])) extract_temp_to_cbin('bluescreenview32.zip', 'BlueScreenView') - + # Cleanup remove_from_temp('bluescreenview32.zip') remove_from_temp('bluescreenview64.zip') @@ -379,16 +379,16 @@ def update_bluescreenview(): def update_erunt(): # Stop running processes kill_process('ERUNT.EXE') - + # Remove existing folders remove_from_kit('ERUNT') - + # Download download_to_temp('erunt.zip', SOURCE_URLS['ERUNT']) - + # Extract files extract_temp_to_cbin('erunt.zip', 'ERUNT') - + # Cleanup remove_from_temp('erunt.zip') @@ -396,10 +396,10 @@ def update_hitmanpro(): # Stop running processes for exe in ['HitmanPro.exe', 'HitmanPro64.exe']: kill_process(exe) - + # Remove existing folders remove_from_kit('HitmanPro') - + # Download dest = r'{}\HitmanPro'.format(global_vars['CBinDir']) download_generic(dest, 'HitmanPro.exe', SOURCE_URLS['HitmanPro32']) @@ -410,13 +410,13 @@ def update_hwinfo(): # Stop running processes for exe in ['HWiNFO32.exe', 'HWiNFO64.exe']: kill_process(exe) - + # Download download_to_temp('HWiNFO.zip', SOURCE_URLS['HWiNFO']) - + # Extract files extract_temp_to_bin('HWiNFO.zip', 'HWiNFO') - + # Cleanup remove_from_temp('HWiNFO.zip') @@ -424,21 +424,21 @@ def update_produkey(): # Stop running processes for exe in ['ProduKey.exe', 'ProduKey64.exe']: kill_process(exe) - + # Remove existing folders remove_from_kit('ProduKey') - + # Download download_to_temp('produkey32.zip', SOURCE_URLS['ProduKey32']) download_to_temp('produkey64.zip', SOURCE_URLS['ProduKey64']) - + # Extract files extract_temp_to_cbin('produkey64.zip', 'ProduKey', sz_args=['ProduKey.exe']) shutil.move( r'{}\ProduKey\ProduKey.exe'.format(global_vars['CBinDir']), r'{}\ProduKey\ProduKey64.exe'.format(global_vars['CBinDir'])) extract_temp_to_cbin('produkey32.zip', 'ProduKey') - + # Cleanup remove_from_temp('produkey32.zip') remove_from_temp('produkey64.zip') @@ -447,14 +447,14 @@ def update_produkey(): def update_intel_rst(): # Remove existing folders remove_from_kit('Intel RST') - + # Prep dest = r'{}\_Drivers\Intel RST'.format(global_vars['CBinDir']) include_path = r'{}\_include\_Drivers\Intel RST'.format( global_vars['CBinDir']) if os.path.exists(include_path): shutil.copytree(include_path, dest) - + # Download for name, url in RST_SOURCES.items(): download_generic(dest, name, url) @@ -462,7 +462,7 @@ def update_intel_rst(): def update_intel_ssd_toolbox(): # Remove existing folders remove_from_kit('Intel SSD Toolbox.exe') - + # Download download_generic( r'{}\_Drivers\Intel SSD Toolbox'.format(global_vars['CBinDir']), @@ -472,7 +472,7 @@ def update_intel_ssd_toolbox(): def update_samsung_magician(): # Remove existing folders remove_from_kit('Samsung Magician.exe') - + # Download download_generic( r'{}\_Drivers\Samsung Magician'.format(global_vars['CBinDir']), @@ -486,7 +486,7 @@ def update_sdi_origin(): aria_dest = r'{}\aria2'.format(global_vars['TmpDir']) aria = r'{}\aria2c.exe'.format(aria_dest) extract_generic(aria_source, aria_dest, mode='e') - + # Prep for torrent download download_to_temp('sdio.torrent', SOURCE_URLS['SDIO Torrent']) sdio_torrent = r'{}\sdio.torrent'.format(global_vars['TmpDir']) @@ -497,7 +497,7 @@ def update_sdi_origin(): if r and not re.search(r'(\.(bat|inf)|Video|Server|Printer|XP)', line, re.IGNORECASE): indexes.append(int(r.group(1))) indexes = [str(i) for i in sorted(indexes)] - + # Download SDI Origin cmd = [ aria, @@ -510,13 +510,13 @@ def update_sdi_origin(): run_program(cmd, pipe=False, check=False, shell=True) sleep(1) wait_for_process('aria2c') - + # Download SDI Origin extra themes download_to_temp('sdio_themes.zip', SOURCE_URLS['SDIO Themes']) theme_source = r'{}\sdio_themes.zip'.format(global_vars['TmpDir']) theme_dest = r'{}\SDIO_Update\tools\SDI\themes'.format(aria_dest) extract_generic(theme_source, theme_dest) - + # Move files into place for item in os.scandir(r'{}\SDIO_Update'.format(aria_dest)): dest_item = '{}\_Drivers\SDIO\{}'.format( @@ -528,7 +528,7 @@ def update_sdi_origin(): if (not os.path.exists(dest_item) and not re.search(r'\.(inf|bat)$', item.name, re.IGNORECASE)): shutil.move(item.path, dest_item) - + # Cleanup remove_from_temp('aria2') remove_from_temp('aria2.zip') @@ -540,13 +540,13 @@ def update_adobe_reader_dc(): # Prep dest = r'{}\Installers\Extras\Office'.format( global_vars['BaseDir']) - + # Remove existing installer try: os.remove(r'{}\Adobe Reader DC.exe'.format(dest)) except FileNotFoundError: pass - + # Download download_generic( dest, 'Adobe Reader DC.exe', SOURCE_URLS['Adobe Reader DC']) @@ -561,13 +561,13 @@ def update_eset_config(): def update_office(): # Remove existing folders remove_from_kit('_Office') - + # Prep dest = r'{}\_Office'.format(global_vars['CBinDir']) include_path = r'{}\_include\_Office'.format(global_vars['CBinDir']) if os.path.exists(include_path): shutil.copytree(include_path, dest) - + # Download and extract for year in ['2013', '2016']: name = 'odt{}.exe'.format(year) @@ -582,7 +582,7 @@ def update_office(): shutil.move( r'{}\{}'.format(global_vars['TmpDir'], year), r'{}\_Office\{}'.format(global_vars['CBinDir'], year)) - + # Cleanup remove_from_temp('odt2013.exe') remove_from_temp('odt2016.exe') @@ -590,7 +590,7 @@ def update_office(): def update_classic_start_skin(): # Remove existing folders remove_from_kit('ClassicStartSkin') - + # Download download_generic( r'{}\ClassicStartSkin'.format(global_vars['CBinDir']), @@ -600,13 +600,13 @@ def update_classic_start_skin(): def update_vcredists(): # Remove existing folders remove_from_kit('_vcredists') - + # Prep dest = r'{}\_vcredists'.format(global_vars['CBinDir']) include_path = r'{}\_include\_vcredists'.format(global_vars['CBinDir']) if os.path.exists(include_path): shutil.copytree(include_path, dest) - + # Download for year in VCREDIST_SOURCES.keys(): for bit in ['32', '64']: @@ -620,10 +620,10 @@ def update_vcredists(): def update_one_ninite(section, dest, name, url, indent=8, width=40): # Prep url = 'https://ninite.com/{}/ninite.exe'.format(url) - + # Download download_generic(out_dir=dest, out_name=name, source_url=url) - + # Copy to Installers folder installer_parent = r'{}\Installers\Extras\{}'.format( global_vars['BaseDir'], section) @@ -647,16 +647,16 @@ def update_all_ninite(indent=8, width=40, other_results={}): def update_caffeine(): # Stop running processes kill_process('caffeine.exe') - + # Remove existing folders remove_from_kit('Caffeine') - + # Download download_to_temp('caffeine.zip', SOURCE_URLS['Caffeine']) - + # Extract files extract_temp_to_cbin('caffeine.zip', 'Caffeine') - + # Cleanup remove_from_temp('caffeine.zip') @@ -664,16 +664,16 @@ def update_du(): # Stop running processes kill_process('du.exe') kill_process('du64.exe') - + # Remove existing folders remove_from_kit('Du') - + # Download download_to_temp('du.zip', SOURCE_URLS['Du']) - + # Extract files extract_temp_to_cbin('du.zip', 'Du') - + # Cleanup remove_from_temp('du.zip') @@ -681,21 +681,21 @@ def update_everything(): # Stop running processes for exe in ['Everything.exe', 'Everything64.exe']: kill_process(exe) - + # Remove existing folders remove_from_kit('Everything') - + # Download download_to_temp('everything32.zip', SOURCE_URLS['Everything32']) download_to_temp('everything64.zip', SOURCE_URLS['Everything64']) - + # Extract files extract_temp_to_cbin('everything64.zip', 'Everything', sz_args=['Everything.exe']) shutil.move( r'{}\Everything\Everything.exe'.format(global_vars['CBinDir']), r'{}\Everything\Everything64.exe'.format(global_vars['CBinDir'])) extract_temp_to_cbin('everything32.zip', 'Everything') - + # Cleanup remove_from_temp('everything32.zip') remove_from_temp('everything64.zip') @@ -703,86 +703,86 @@ def update_everything(): def update_firefox_ublock_origin(): # Remove existing folders remove_from_kit('FirefoxExtensions') - + # Download download_to_temp('ff-uBO.xpi', SOURCE_URLS['Firefox uBO']) - + # Extract files extract_generic( r'{}\ff-uBO.xpi'.format(global_vars['TmpDir']), r'{}\FirefoxExtensions\uBlock0@raymondhill.net'.format( global_vars['CBinDir'])) - + # Cleanup remove_from_temp('ff-uBO.xpi') def update_notepadplusplus(): # Stop running processes kill_process('notepadplusplus.exe') - + # Remove existing folders remove_from_kit('NotepadPlusPlus') - + # Download download_to_temp('npp.7z', SOURCE_URLS['NotepadPlusPlus']) - + # Extract files extract_temp_to_cbin('npp.7z', 'NotepadPlusPlus') shutil.move( r'{}\NotepadPlusPlus\notepad++.exe'.format(global_vars['CBinDir']), r'{}\NotepadPlusPlus\notepadplusplus.exe'.format(global_vars['CBinDir']) ) - + # Cleanup remove_from_temp('npp.7z') def update_putty(): # Stop running processes kill_process('PUTTY.EXE') - + # Remove existing folders remove_from_kit('PuTTY') - + # Download download_to_temp('putty.zip', SOURCE_URLS['PuTTY']) - + # Extract files extract_temp_to_cbin('putty.zip', 'PuTTY') - + # Cleanup remove_from_temp('putty.zip') def update_treesizefree(): # Stop running processes kill_process('TreeSizeFree.exe') - + # Remove existing folders remove_from_kit('TreeSizeFree') - + # Download download_to_temp( 'treesizefree.zip', SOURCE_URLS['TreeSizeFree']) - + # Extract files extract_temp_to_cbin('treesizefree.zip', 'TreeSizeFree') - + # Cleanup remove_from_temp('treesizefree.zip') def update_xmplay(): # Stop running processes kill_process('xmplay.exe') - + # Remove existing folders remove_from_kit('XMPlay') - + # Download download_to_temp('xmplay.zip', SOURCE_URLS['XMPlay']) download_to_temp('xmp-7z.zip', SOURCE_URLS['XMPlay 7z']) download_to_temp('xmp-gme.zip', SOURCE_URLS['XMPlay Game']) download_to_temp('xmp-rar.zip', SOURCE_URLS['XMPlay RAR']) download_to_temp('WAModern.zip', SOURCE_URLS['XMPlay WAModern']) - + # Extract files extract_temp_to_cbin('xmplay.zip', 'XMPlay', mode='e', sz_args=['xmplay.exe', 'xmplay.txt']) @@ -794,7 +794,7 @@ def update_xmplay(): r'{}\{}.zip'.format(global_vars['TmpDir'], item), r'{}\XMPlay\plugins'.format(global_vars['CBinDir']), mode='e', sz_args=filter) - + # Download Music dest = r'{}\XMPlay\music_tmp\MOD'.format(global_vars['CBinDir']) for mod in MUSIC_MOD: @@ -806,7 +806,7 @@ def update_xmplay(): name = '{}.rsn'.format(game) url = 'http://snesmusic.org/v2/download.php?spcNow={}'.format(game) download_generic(dest, name, url) - + # Compress Music cmd = [ global_vars['Tools']['SevenZip'], @@ -815,7 +815,7 @@ def update_xmplay(): r'{}\XMPlay\music_tmp\*'.format(global_vars['CBinDir']), ] run_program(cmd) - + # Cleanup remove_item(r'{}\XMPlay\music_tmp'.format(global_vars['CBinDir'])) remove_from_temp('xmplay.zip') @@ -828,10 +828,10 @@ def update_xmplay(): def update_adwcleaner(): # Stop running processes kill_process('AdwCleaner.exe') - + # Remove existing folders remove_from_kit('AdwCleaner') - + # Download url = resolve_dynamic_url( SOURCE_URLS['AdwCleaner'], @@ -842,10 +842,10 @@ def update_adwcleaner(): def update_kvrt(): # Stop running processes kill_process('KVRT.exe') - + # Remove existing folders remove_from_kit('KVRT') - + # Download download_generic( r'{}\KVRT'.format(global_vars['CBinDir']), @@ -855,10 +855,10 @@ def update_kvrt(): def update_rkill(): # Stop running processes kill_process('RKill.exe') - + # Remove existing folders remove_from_kit('RKill') - + # Download url = resolve_dynamic_url( SOURCE_URLS['RKill'], @@ -869,36 +869,59 @@ def update_rkill(): def update_tdsskiller(): # Stop running processes kill_process('TDSSKiller.exe') - + # Remove existing folders remove_from_kit('TDSSKiller') - + # Download download_generic( r'{}\TDSSKiller'.format(global_vars['CBinDir']), 'TDSSKiller.exe', SOURCE_URLS['TDSSKiller']) +def update_winaiorepair(): + # Stop running processes + kill_process('Repair_Windows.exe') + + # Remove existing folders + remove_from_kit('WinAIO Repair') + + # Download + download_to_temp('winaio.zip', SOURCE_URLS['WinAIO Repair']) + + # Extract + extract_temp_to_cbin('winaio.zip', 'WinAIO Repair') + dest = r'{}\WinAIO Repair'.format(global_vars['CBinDir']) + for item in os.scandir(r'{}\Tweaking.com - Windows Repair'.format(dest)): + dest_item = '{}\{}'.format(dest, item.name) + if not os.path.exists(dest_item): + shutil.move(item.path, dest_item) + shutil.rmtree( + r'{}\WinAIO Repair\Tweaking.com - Windows Repair'.format(global_vars['CBinDir'])) + + # Cleanup + remove_from_temp('winaio.zip') + ## Uninstallers ## def update_iobit_uninstaller(): # Stop running processes kill_process('IObitUninstallerPortable.exe') - + # Remove existing folders remove_from_kit('IObitUninstallerPortable') - + # Download download_generic( global_vars['CBinDir'], 'IObitUninstallerPortable.exe', SOURCE_URLS['IOBit_Uninstaller']) - + # "Install" cmd = r'{}\IObitUninstallerPortable.exe'.format(global_vars['CBinDir']) popen_program(cmd) sleep(1) wait_for_process('IObitUninstallerPortable') - + # Cleanup remove_from_kit('IObitUninstallerPortable.exe') diff --git a/.bin/Scripts/settings/launchers.py b/.bin/Scripts/settings/launchers.py index ac4e9da5..2baeb1ea 100644 --- a/.bin/Scripts/settings/launchers.py +++ b/.bin/Scripts/settings/launchers.py @@ -619,6 +619,12 @@ LAUNCHERS = { r'mkdir "%q_dir%">nul 2>&1', ], }, + 'WinAIO Repair': { + 'L_TYPE': 'Executable', + 'L_PATH': 'WinAIO Repair', + 'L_ITEM': 'Repair_Windows.exe', + 'L_ELEV': 'True', + }, }, r'Uninstallers': { 'IObit Uninstaller': { diff --git a/.bin/Scripts/settings/sources.py b/.bin/Scripts/settings/sources.py index 8fc17af8..2b7822ff 100644 --- a/.bin/Scripts/settings/sources.py +++ b/.bin/Scripts/settings/sources.py @@ -39,6 +39,7 @@ SOURCE_URLS = { 'TreeSizeFree': 'https://www.jam-software.com/treesize_free/TreeSizeFree-Portable.zip', 'wimlib32': 'https://wimlib.net/downloads/wimlib-1.12.0-windows-i686-bin.zip', 'wimlib64': 'https://wimlib.net/downloads/wimlib-1.12.0-windows-x86_64-bin.zip', + 'WinAIO Repair': 'http://www.tweaking.com/files/setups/tweaking.com_windows_repair_aio.zip', 'Winapp2': 'https://github.com/MoscaDotTo/Winapp2/archive/master.zip', 'XMPlay 7z': 'http://support.xmplay.com/files/16/xmp-7z.zip?v=800962', 'XMPlay Game': 'http://support.xmplay.com/files/12/xmp-gme.zip?v=515637', diff --git a/.bin/Scripts/update_kit.py b/.bin/Scripts/update_kit.py index 6a5cdf82..c3e4e3e2 100644 --- a/.bin/Scripts/update_kit.py +++ b/.bin/Scripts/update_kit.py @@ -79,6 +79,7 @@ if __name__ == '__main__': try_and_print(message='KVRT...', function=update_kvrt, other_results=other_results, width=40) try_and_print(message='RKill...', function=update_rkill, other_results=other_results, width=40) try_and_print(message='TDSSKiller...', function=update_tdsskiller, other_results=other_results, width=40) + try_and_print(message='WinAIO Repair...', function=update_winaiorepair, other_results=other_results, width=40) # Uninstallers print_info(' Uninstallers') diff --git a/.cbin/_include/WinAIO Repair/settings.ini b/.cbin/_include/WinAIO Repair/settings.ini new file mode 100644 index 0000000000000000000000000000000000000000..76a72c4f884c58ddce96a1552b5c26d91df66192 GIT binary patch literal 10338 zcmbuFZBJXt8HVR`rT&MbN?WCBw@Dz$rj_`RkPzsGC5lP%VYgZlV;mHNSsNC%KfdjK z&CSD{Hx7wc76#9md0y}5ZOs4v`(rvu2kAJSrhlhDraz>&X_BVtU0Uk*B5l;xzSqic z*DIrRu2T!W@9X_Q>pN+j=AyEZ9^^Bd>66w^MQf5?>&Y~~kF|C#ZuOnFJw=*l=|cPG z>4knQ*>h1Cr_WkHyWusK4u_KXlXhKd^#}c4WW8ot7C%4J8k~7Q&zfvY>Q`wy??DRa z!sSdnjHdNvoo`)MRy(EL!JFKbpsy4bamwsd}$Jq3mC8GLi06Sm|`lWVfjrXv|Q!v zD0BN&e8$-hU(S7+CB)K;Y&SghWp)p|R_R096{h=qQ{RIxj4ZH#w)hNm%=8*Qy`!_1 z@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J2pLC~1BB5d7U4qeYpo?&3-|DmOLQ z`!`VypQ1$_&FB_cvW=L2?OrsbDK{Hbj#48drkwTB(%*SU*TGE)_X?h|!^50E=$N?n*kb^O5#GNb7mO@A$w()LFFRekS%mO8?N#2kE;^6@TJ|^8BIh3EA^h zzt=<+-oE>o-ypD0zPi<@2WPe2kHznaUc4K5&D|jzyw}D1v0hKa9o`{X-8Q%Hirsw@ z(m$MM47BCz)4A*>O0l3b5|PC>=j(bQ=OevrrE;Q4e@(mXP56XA%kDn|#**;qZ1**<>dV#U^8=vs>NY*5u4NF1}AC`n2bsBBl2Zeq~ zc=~0M)a_j=LXoYjW&a81ELY2}<@?WE)og$r(b3orMAqZsDn}&s8P9Zibfdd|x`{ng fXvgy~g+4s?;eD9OkWY7YyTYu+bW?7%N+tO}2a?j- literal 0 HcmV?d00001 From 7bce6076c8411f7bdd4727bd9136b5b77daa48ec Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Mon, 20 Aug 2018 02:30:50 -0700 Subject: [PATCH 27/36] Added more d7II launchers --- .bin/Scripts/settings/launchers.py | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/.bin/Scripts/settings/launchers.py b/.bin/Scripts/settings/launchers.py index 2baeb1ea..a76e5438 100644 --- a/.bin/Scripts/settings/launchers.py +++ b/.bin/Scripts/settings/launchers.py @@ -8,6 +8,11 @@ LAUNCHERS = { 'L_ITEM': 'activate.py', 'L_ELEV': 'True', }, + 'd7II': { + 'L_TYPE': 'Executable', + 'L_PATH': 'd7II', + 'L_ITEM': 'd7II.exe', + }, 'Install ESET NOD32 AV': { 'L_TYPE': 'PyScript', 'L_PATH': 'Scripts', @@ -84,6 +89,11 @@ LAUNCHERS = { }, }, r'Data Transfers': { + "Fab's Autobackup Pro": { + 'L_TYPE': 'Executable', + 'L_PATH': 'AutoBackupPro', + 'L_ITEM': 'autobackup6pro.exe', + }, 'FastCopy (as ADMIN)': { 'L_TYPE': 'Executable', 'L_PATH': 'FastCopy', @@ -196,6 +206,12 @@ LAUNCHERS = { r'mkdir "%q_dir%">nul 2>&1', ], }, + 'Mac & Linux Reader': { + 'L_TYPE': 'Executable', + 'L_PATH': 'LinuxReader', + 'L_ITEM': 'LinuxReader.exe', + 'L_ELEV': 'True', + }, 'Transferred Keys': { 'L_TYPE': 'PyScript', 'L_PATH': 'Scripts', @@ -570,6 +586,11 @@ LAUNCHERS = { 'L_ITEM': 'dism.py', 'L_ELEV': 'True', }, + 'ESET Online Scanner': { + 'L_TYPE': 'Executable', + 'L_PATH': 'ESET', + 'L_ITEM': 'ESET.exe', + }, 'KVRT': { 'L_TYPE': 'Executable', 'L_PATH': 'KVRT', From 887cfd9f92525a3bdcfe4710a772f79e013d1e77 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Mon, 20 Aug 2018 02:31:22 -0700 Subject: [PATCH 28/36] Bugfix: typo --- .bin/Scripts/Launcher_Template.cmd | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.bin/Scripts/Launcher_Template.cmd b/.bin/Scripts/Launcher_Template.cmd index 90b15482..01d1758d 100644 --- a/.bin/Scripts/Launcher_Template.cmd +++ b/.bin/Scripts/Launcher_Template.cmd @@ -17,7 +17,7 @@ call :SetTitle Launcher rem EXTRA_CODE :DefineLaunch -:: See %bin%\SCripts\Launch.cmd for details under :Usage label +:: See %bin%\Scripts\Launch.cmd for details under :Usage label set L_TYPE= set L_PATH= set L_ITEM= @@ -110,4 +110,4 @@ goto Exit :: Cleanup and exit :: :Exit endlocal -exit /b %errorlevel% \ No newline at end of file +exit /b %errorlevel% From 84f3a4e819d41324843003c326509e653efef182 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Mon, 20 Aug 2018 02:44:46 -0700 Subject: [PATCH 29/36] Removed LICENSE.txt --- LICENSE.txt | 7 ------- 1 file changed, 7 deletions(-) delete mode 100644 LICENSE.txt diff --git a/LICENSE.txt b/LICENSE.txt deleted file mode 100644 index d02f5a6e..00000000 --- a/LICENSE.txt +++ /dev/null @@ -1,7 +0,0 @@ -Copyright (c) 2018 Alan Mason - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \ No newline at end of file From 5b08a3b4b4445cdf931b6c7c63581fe4fac78cb9 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Mon, 20 Aug 2018 02:44:52 -0700 Subject: [PATCH 30/36] Updated README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 37c7f431..6228b18a 100644 --- a/README.md +++ b/README.md @@ -57,7 +57,7 @@ A collection of scripts to help technicians service Windows systems. * _(Recommended)_ Install and configure `sudo` * See the [wiki page](https://wiki.archlinux.org/index.php/Sudo) for details. * Login to the user added above -* Download the Github repo $ `git clone https://github.com/2Shirt/WizardKit.git` +* Download the Github repo $ `git clone https://1201north.ddns.net:3000/2Shirt/WizardKit.git` * Run the build script * $ `cd WizardKit` * $ `./Build\ Linux -b` From c25a46b49f2148e2f60cc95edc2bd5edaeff657c Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Tue, 21 Aug 2018 12:03:31 -0700 Subject: [PATCH 31/36] Let's not remove browser history --- .bin/Scripts/system_diagnostics.py | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/.bin/Scripts/system_diagnostics.py b/.bin/Scripts/system_diagnostics.py index 535b14ef..7ce0f639 100644 --- a/.bin/Scripts/system_diagnostics.py +++ b/.bin/Scripts/system_diagnostics.py @@ -43,27 +43,16 @@ BLEACH_BIT_CLEANERS = { 'Browsers': ( 'chromium.cache', 'chromium.current_session', - 'chromium.history', 'firefox.cache', - 'firefox.download_history', 'firefox.session_restore', - 'firefox.url_history', 'google_chrome.cache', - 'google_chrome.history', 'google_chrome.session', 'google_earth.temporary_files', - 'google_toolbar.search_history', - 'internet_explorer.history', 'internet_explorer.temporary_files', 'opera.cache', 'opera.current_session', - 'opera.download_history', - 'opera.url_history', 'safari.cache', - 'safari.history', 'seamonkey.cache', - 'seamonkey.download_history', - 'seamonkey.history', ), 'System': ( 'system.clipboard', From 3875d4b2bdbd40f04e9fe4bd81c0286276c60cbe Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Tue, 21 Aug 2018 12:14:17 -0700 Subject: [PATCH 32/36] Fix error detection in SW Diags --- .bin/Scripts/system_diagnostics.py | 35 +++++++++++++++--------------- 1 file changed, 18 insertions(+), 17 deletions(-) diff --git a/.bin/Scripts/system_diagnostics.py b/.bin/Scripts/system_diagnostics.py index 7ce0f639..c13147d4 100644 --- a/.bin/Scripts/system_diagnostics.py +++ b/.bin/Scripts/system_diagnostics.py @@ -16,7 +16,6 @@ os.system('title {}: System Diagnostics Tool'.format(KIT_NAME_FULL)) global_vars['LogFile'] = r'{LogDir}\System Diagnostics.log'.format( **global_vars) D7_MODE = 'd7mode' in sys.argv -ERRORS = 0 # Static Variables BLEACH_BIT_CLEANERS = { @@ -68,13 +67,15 @@ BLEACH_BIT_CLEANERS = { def check_result(result, other_results): """Check result for warnings and errors.""" + result_ok = True if not result['CS']: for warning in other_results.get('Warning', {}).keys(): if warning in str(result['Error']): # Ignore warnings and repair statements - return + return True # Error is not a warning - ERRORS += 1 + result_ok = False + return result_ok if __name__ == '__main__': try: @@ -82,6 +83,7 @@ if __name__ == '__main__': clear_screen() print_info('{}: System Diagnostics Tool\n'.format(KIT_NAME_FULL)) ticket_number = get_ticket_number() + system_ok = True other_results = { 'Error': { 'CalledProcessError': 'Unknown Error', @@ -94,7 +96,7 @@ if __name__ == '__main__': if ENABLED_TICKET_NUMBERS: print_info('Starting System Diagnostics for Ticket #{}\n'.format( ticket_number)) - + # Sanitize Environment print_info('Sanitizing Environment') if not D7_MODE: @@ -102,10 +104,10 @@ if __name__ == '__main__': function=run_rkill, cs='Done', other_results=other_results) try_and_print(message='Running TDSSKiller...', function=run_tdsskiller, cs='Done', other_results=other_results) - + # Re-run if earlier process was stopped. stay_awake() - + # Start diags if not D7_MODE: print_info('Starting Background Scans') @@ -114,25 +116,24 @@ if __name__ == '__main__': function=run_hitmanpro, cs='Started', other_results=other_results) try_and_print(message='Running Autoruns...', function=run_autoruns, cs='Started', other_results=other_results) - + # OS Health Checks print_info('OS Health Checks') result = try_and_print( message='CHKDSK ({SYSTEMDRIVE})...'.format(**global_vars['Env']), function=run_chkdsk, other_results=other_results) - check_result(result, other_results) + system_ok &= check_result(result, other_results) result = try_and_print(message='SFC scan...', function=run_sfc_scan, other_results=other_results) - check_result(result, other_results) + system_ok &= check_result(result, other_results) if D7_MODE: result = try_and_print(message='DISM RestoreHealth...', function=run_dism, other_results=other_results, repair=True) - check_result(result, other_results) + system_ok &= check_result(result, other_results) else: try_and_print(message='DISM CheckHealth...', function=run_dism, other_results=other_results, repair=False) - - + if D7_MODE: # Archive all browsers for all users archive_all_users() @@ -140,7 +141,7 @@ if __name__ == '__main__': # Scan for supported browsers print_info('Scanning for browsers') scan_for_browsers() - + # Run BleachBit cleaners print_info('BleachBit Cleanup') for k, v in sorted(BLEACH_BIT_CLEANERS.items()): @@ -148,7 +149,7 @@ if __name__ == '__main__': function=run_bleachbit, cs='Done', other_results=other_results, cleaners=v, preview=bool(not D7_MODE)) - + # Export system info print_info('Backup System Information') try_and_print(message='AIDA64 reports...', @@ -164,7 +165,7 @@ if __name__ == '__main__': if not D7_MODE: try_and_print(message='Registry...', function=backup_registry, cs='Done', other_results=other_results) - + # Summary if not D7_MODE: print_info('Summary') @@ -185,7 +186,7 @@ if __name__ == '__main__': other_results=other_results, print_return=True) try_and_print(message='Product Keys:', function=get_product_keys, ns='Unknown', print_return=True) - + # User data if not D7_MODE: print_info('User Data') @@ -193,7 +194,7 @@ if __name__ == '__main__': show_user_data_summary() except Exception: print_error(' Unknown error.') - + # Done if not D7_MODE or ERRORS > 0: print_standard('\nDone.') From b9b7b0456a71f8e4df08592ae0e968407b25cf3f Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Thu, 30 Aug 2018 10:58:31 -0700 Subject: [PATCH 33/36] Fix error detection in SW Diags (again) --- .bin/Scripts/system_diagnostics.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.bin/Scripts/system_diagnostics.py b/.bin/Scripts/system_diagnostics.py index c13147d4..1ee42ffa 100644 --- a/.bin/Scripts/system_diagnostics.py +++ b/.bin/Scripts/system_diagnostics.py @@ -196,7 +196,7 @@ if __name__ == '__main__': print_error(' Unknown error.') # Done - if not D7_MODE or ERRORS > 0: + if not D7_MODE or not system_ok: print_standard('\nDone.') pause('Press Enter to exit...') exit_script() From b043b63d2d3b051a9d656c3dfbfd4f946c4ce7a8 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Thu, 30 Aug 2018 10:59:46 -0700 Subject: [PATCH 34/36] Don't ask to install MSE in D7_MODE --- .bin/Scripts/install_sw_bundle.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.bin/Scripts/install_sw_bundle.py b/.bin/Scripts/install_sw_bundle.py index e35760c3..cc0c9a7f 100644 --- a/.bin/Scripts/install_sw_bundle.py +++ b/.bin/Scripts/install_sw_bundle.py @@ -33,7 +33,8 @@ if __name__ == '__main__': answer_adobe_reader = ask('Install Adobe Reader?') answer_vcr = D7_MODE or ask('Install Visual C++ Runtimes?') answer_ninite = D7_MODE or ask('Install Ninite Bundle?') - if answer_ninite and global_vars['OS']['Version'] in ['7']: + if not D7_MODE and ( + answer_ninite and global_vars['OS']['Version'] in ['7']): # Vista is dead, not going to check for it answer_mse = ask('Install MSE?') else: From 7d1850a48028e48fcdf82f4c8bdde4f8070c4a57 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Thu, 30 Aug 2018 11:27:47 -0700 Subject: [PATCH 35/36] Allow BleachBit to be run more than once per day --- .bin/Scripts/functions/info.py | 51 ++++++++++++++++------------------ 1 file changed, 24 insertions(+), 27 deletions(-) diff --git a/.bin/Scripts/functions/info.py b/.bin/Scripts/functions/info.py index 5f7f3631..e306d767 100644 --- a/.bin/Scripts/functions/info.py +++ b/.bin/Scripts/functions/info.py @@ -371,38 +371,35 @@ def run_aida64(): def run_bleachbit(cleaners=None, preview=True): """Run BleachBit preview and save log. - This is a preview so no files should be deleted.""" - if not os.path.exists(global_vars['LogDir']+r'\BleachBit.log'): - debug_path = r'{}\BleachBit.debug'.format(global_vars['LogDir']) - error_path = debug_path.replace('debug', 'err') - log_path = debug_path.replace('debug', 'log') - extract_item('BleachBit', silent=True) + If preview is True then no files should be deleted.""" + error_path = r'{}\BleachBit.err'.format(global_vars['LogDir']) + log_path = error_path.replace('err', 'log') + extract_item('BleachBit', silent=True) - # Safety check - if not cleaners: - # Disable cleaning and use preset config - cleaners = ['--preset'] - preview = True + # Safety check + if not cleaners: + # Disable cleaning and use preset config + cleaners = ['--preset'] + preview = True - # Run - cmd = [ - global_vars['Tools']['BleachBit'], - '--preview' if preview else '--clean', - '--debug-log="{}"'.format(debug_path)] - cmd.extend(cleaners) - out = run_program(cmd, check=False) + # Run + cmd = [ + global_vars['Tools']['BleachBit'], + '--preview' if preview else '--clean'] + cmd.extend(cleaners) + out = run_program(cmd, check=False) - # Save stderr - if out.stderr.decode().splitlines(): - with open(error_path, 'a', encoding='utf-8') as f: - for line in out.stderr.decode().splitlines(): - f.write(line.strip() + '\n') - - # Save stdout - with open(log_path, 'a', encoding='utf-8') as f: - for line in out.stdout.decode().splitlines(): + # Save stderr + if out.stderr.decode().splitlines(): + with open(error_path, 'a', encoding='utf-8') as f: + for line in out.stderr.decode().splitlines(): f.write(line.strip() + '\n') + # Save stdout + with open(log_path, 'a', encoding='utf-8') as f: + for line in out.stdout.decode().splitlines(): + f.write(line.strip() + '\n') + def show_disk_usage(disk): """Show free and used space for a specified disk.""" print_standard('{:5}'.format(disk.device.replace('/', ' ')), From 79ad9f1412c63a7752a6e5dc617ae0ff496cfdf6 Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Tue, 25 Sep 2018 21:06:23 -0600 Subject: [PATCH 36/36] Added 1201 specific boot entries --- .../include/EFI/boot/icons/1201_eset.png | Bin 0 -> 7848 bytes .../include/EFI/boot/icons/1201_hdclone.png | Bin 0 -> 3133 bytes .../include/EFI/boot/icons/1201_mac-dgpu.png | Bin 0 -> 3086 bytes .linux_items/include/EFI/boot/refind.conf | 15 +++++++++++++++ .linux_items/include/syslinux/1201_eset.cfg | 9 +++++++++ .linux_items/include/syslinux/1201_hdclone.cfg | 9 +++++++++ .linux_items/include/syslinux/wk.cfg | 2 +- .linux_items/include/syslinux/wk_head.cfg | 14 +++++++------- .linux_items/include/syslinux/wk_sys.cfg | 4 +++- .linux_items/include/syslinux/wk_sys_extras.cfg | 2 ++ 10 files changed, 46 insertions(+), 9 deletions(-) create mode 100644 .linux_items/include/EFI/boot/icons/1201_eset.png create mode 100644 .linux_items/include/EFI/boot/icons/1201_hdclone.png create mode 100644 .linux_items/include/EFI/boot/icons/1201_mac-dgpu.png create mode 100644 .linux_items/include/syslinux/1201_eset.cfg create mode 100644 .linux_items/include/syslinux/1201_hdclone.cfg diff --git a/.linux_items/include/EFI/boot/icons/1201_eset.png b/.linux_items/include/EFI/boot/icons/1201_eset.png new file mode 100644 index 0000000000000000000000000000000000000000..5f41417f7d3b3dfc61775f12a770b2b7c34d1fc7 GIT binary patch literal 7848 zcmV;Z9#`RsP)0b000McNliru;t3fSFfZDt)Di#y02y>e zSad^gZEa<4bO1wgWnpw>WFU8GbZ8()Nlj2!fese{03HxYL_t(|+U=cpa2(g2=RdEz zCt)zifye+!fS{O3F^Wl4)+$-SmUXh$F8jQ-vd^LH^?A>AEAV!`TX#-%wYGMBc6lAN zmQ2gCL`9pTNK2w5<^(X40Ej>ULxjQPp6TxUV}`U$2{V|P1_q??t$Hd^BJjF@zwi5{ z_uj8z8q=7@G^R0)X-s1p)0oCb3nJ5B(9+T(rp1^&w6wGslS+WN!UZ73hcJUk(?|mn??pNafO&>22L<-7R zo_OMk#lXJIrfkl-QUB_JA47gHjD1XzLPQ{`6+jDnTG(7+GCX?Wy$HK}P%qcIYsVrtGCYcIWKnA3imKO10*+8;Npfp)e zIvfmgs&9bTj-TP3u5ONcee^{&va9YCEfx?k3<8k|U6Ba;4jsdF_&BvTD~pN>xqrc2 zRy5R7m7j++c~&9eL`u3pXqHdE=<~7TbUVL0+Qz%?A$p?PH5H0`4TH8&n6} za+i}kXEku&!nrh-mSVRkS$)2&%x(bwaF{IzkMPXlHntCW&<%rY9UAbS$IE*Mj_{MC z$9be_CV#zhDUD^ND3bKiAb@Td?Cm(u5B{`^=XwXS?$fh{E>-3Kw4G$jnRdRpatV*F zSVoT3dTkTH8xFH&-yy!eYY!cf$fW!C@%XgKd?v#%Xb*+>@|*ARPJ0*MxMc%#XOvHB zpg3s+7zqS;;^l4p;`BK@nm!@Ql>`(h7Rqc^O05TNdaolffV^QbN=psBo+ImJcfI~-Uo3N}T- zBFiX}gorC!2oXzbu1Lp>_&*E`48uS-Vy;Tpb)vdXI2uKbL9!NJ`TV3}6E3JKUwr;$e)frv zv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cqOPtE7cN{t zd3m`pGnjg@0BUgb=+T6n*Is)qV?Tk@>C|Kc%6xsVz!WY(4IV#!yy+zp+4d7;dL0}S zzyJgwBD#0)UeWXuFab>7PXHtK1E>Y}6BxW7Ku-iPWHiqG01QLd0vJpH1`|LzxSzn} z1mJ#x+^2kXy$W!-TzK%{LE4up6eFV1D5|TgF*!MD?p46#;SORat-%yr>rb28NMQ4qyeqk`fCb@cbDbg3=&xjV;f34h@TE8+4g90oDo$RscWo zJQ@~1NjjvhNRW*M_?G9ID91OZ#kU>uw)RjcHmP0{{`UYc{K$70pPZ@gkMra07#~T0Q?8QD1ds&Eim+l zX#jr*a8p_VENo@^<*f4sDUw`^2YwIWIDl3Fe_}G|VyX8p00RKNldSbK$?vZq!~24> zP4ozowRlM)!pnHkYqkw9GKO4ME)3$5iGMDQ1pqO;$osEmQobAltbJCLh+xD2Q^g`U zV^}DVM1r+c@3N%$cs9z1Ld6M5WDqtCMt+r_JmN@`@X?Y0xsbt7M+63g!C){L3|aUe XvbZLKwJhH#00000NkvXXu0mjf{e95N literal 0 HcmV?d00001 diff --git a/.linux_items/include/EFI/boot/icons/1201_mac-dgpu.png b/.linux_items/include/EFI/boot/icons/1201_mac-dgpu.png new file mode 100644 index 0000000000000000000000000000000000000000..e9770abd1ba2487b1e3d08e9a643004f94d019c3 GIT binary patch literal 3086 zcmV+p4Ds`cP)Tvy7{wCK`mp%wa=cJ5>U=$&R3OXpGM z&Y8LAo7|+G%$>*nxBwb z4BQ{8JP-;11=u3fGGVnf$j6AY0JjCm05D&s+Kt+$ewm&ekjOF4Y_FfA=D zBHiK;kZolF+T~0R6#=CA!3pMevuxQicI?=}qD6}^O%p{?Fin#mfBaE6MngpacL?)k zi(eo?6otaVLdwd@n3$MAQIzS=gW(Xgh0wJ8G$V}w5&+=(>#wJ#riS$NbS5V!|IhSb zUA%ZvQ~-=fBS1J+L`Uf9r=Mocnl+ea=suUTXU`^HmL@H}ysE0I$j!|S%Y1;7Cr=8S zgGm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C{g?my6okT8fK{Z5>5zD*%TM9g=Q`0Ab6PEi^SXv2x|gU_9$BrG7i$>0%ufP7<)|td{1HkY1vuDp9>G&mYzujpP*OeO%A3iL{ z3kK<%Z@#g8{lK^{-SN^(FG=SCP1EACdT87M`0A^#=r+_S-^adBSZUA9y<&8X8DVO-)Jwe*XDqwr<^O*X0st`}km`rl!)^ z*qC(7%xap(#*G{8+#fJ;$^gNdn3!PKu3bq5fN7d++O)~`%^?%23=pjD?rzG<%VRd7 z#5BzrkC^1Oio%W^JA~OQXga$U{jF(lZ%0uS%F4>-{N|XZNlHozr%s)sv$K;kXU_1; zFTYH$C>l$OW)bb04WwALLj?j$r4_D z^;O(%cSMGmrishtqNk^a=H_NT`Q($Zm#oRm%%r%um^<&hGpaR@P19s>aF8dSc!K`^ z{&*$b9{>%QjIa(=>cOA9Zzg?BBotieKC7^|EW%E(!_?@OV6^s*0+r)4=)tewv$`*}HeI2uXDj z$g#}#M*;vA09OI^K%t1`165T?PfsT+D+`~`$Kc=~nx@&ZE}^0*(}&ybM%Q%=!-#1? zG77Z<{{TiU03s>`2A<+$Q2{UvgOQPuxRk7ejTU$rypJ#Ol1L(e3V5yX-vKN{Dv@*+ z_zQ3W7zd0<+W|}~Y-qrCnVt!!?UsN3*&;xw7M8$?=Ycc8UuC)`g#HP%SXKDRxd4C_ zI!vGkI1UtuRx6O2RzI)}IAYZRe3uLT;gkV_zvB)n4`c%O14Tf-gh7a^-oJr^K!X*n zFIxG&Hrv}DE&ze=xtQu9^jgPN){%nXeF{k|!wT`E*5L!jnCkh{Lzy250DL};3{{R3007*qoM6N<$f`+B;Bme*a literal 0 HcmV?d00001 diff --git a/.linux_items/include/EFI/boot/refind.conf b/.linux_items/include/EFI/boot/refind.conf index de83e78c..8a5cb3e2 100644 --- a/.linux_items/include/EFI/boot/refind.conf +++ b/.linux_items/include/EFI/boot/refind.conf @@ -37,3 +37,18 @@ menuentry "Linux" { #UFD# icon /EFI/boot/icons/wk_win.png #UFD# loader /EFI/microsoft/bootx64.efi #UFD#} +#UFD#menuentry "ESET SysRescue Live" { +#UFD# icon /EFI/boot/icons/1201_eset.png +#UFD# loader /EFI/ESET/grubx64.efi +#UFD#} +#UFD#menuentry "HDClone" { +#UFD# icon /EFI/boot/icons/1201_hdclone.png +#UFD# loader /EFI/HDClone/grub.efi +#UFD#} +#UFD#menuentry "Mac dGPU Disable Tool" { +#UFD# icon /EFI/boot/icons/1201_mac-dgpu.png +#UFD# loader /dgpu/boot/x86_64/vmlinuz +#UFD# initrd /dgpu/boot/intel_ucode.img +#UFD# initrd /dgpu/boot/x86_64/archiso.img +#UFD# options "archisobasedir=dgpu archisolabel=1201_UFD nomodeset" +#UFD#} diff --git a/.linux_items/include/syslinux/1201_eset.cfg b/.linux_items/include/syslinux/1201_eset.cfg new file mode 100644 index 00000000..59f2de32 --- /dev/null +++ b/.linux_items/include/syslinux/1201_eset.cfg @@ -0,0 +1,9 @@ +LABEL eset +TEXT HELP +ESET SysRescue Live + * Offline AV scanner +ENDTEXT +MENU LABEL ESET SysRescue Live +LINUX ../casper/vmlinuz +INITRD ../casper/initrd.lz +APPEND boot=casper live-media=/dev/disk/by-label/1201_UFD splash diff --git a/.linux_items/include/syslinux/1201_hdclone.cfg b/.linux_items/include/syslinux/1201_hdclone.cfg new file mode 100644 index 00000000..a97b3db9 --- /dev/null +++ b/.linux_items/include/syslinux/1201_hdclone.cfg @@ -0,0 +1,9 @@ +LABEL hdclone +TEXT HELP +HDClone by Miray Software + * Backups, cloning, etc +ENDTEXT +MENU LABEL HDClone 6 +LINUX boot/syslinux/memdisk +INITRD ../sources/hdclone.iso +APPEND iso diff --git a/.linux_items/include/syslinux/wk.cfg b/.linux_items/include/syslinux/wk.cfg index b9163e25..14e95ca2 100644 --- a/.linux_items/include/syslinux/wk.cfg +++ b/.linux_items/include/syslinux/wk.cfg @@ -8,4 +8,4 @@ LABEL pxe CONFIG boot/syslinux/wk_pxe.cfg LABEL sys -CONFIG boot/syslinux/wk_sys.cfg +CONFIG boot/syslinux/wk_sys_extras.cfg diff --git a/.linux_items/include/syslinux/wk_head.cfg b/.linux_items/include/syslinux/wk_head.cfg index 7562755a..d2f1ee9f 100644 --- a/.linux_items/include/syslinux/wk_head.cfg +++ b/.linux_items/include/syslinux/wk_head.cfg @@ -15,15 +15,15 @@ MENU TABMSG # Refer to http://syslinux.zytor.com/wiki/index.php/Doc/menu -MENU COLOR screen 30;44 #a0000000 #a0000000 none -MENU COLOR border 30;44 #a0000000 #a0000000 none -MENU COLOR title 1;36;44 #9033ccff #a0000000 none +MENU COLOR screen 30;41 #a0000000 #a0000000 none +MENU COLOR border 30;41 #a0000000 #a0000000 none +MENU COLOR title 1;35;41 #90ff6666 #a0000000 none MENU COLOR sel 7;37;40 #e0ffffff #a0000000 std -MENU COLOR disabled 37;44 #50ffffff #a0000000 none -MENU COLOR unsel 37;44 #50ffffff #a0000000 none +MENU COLOR disabled 37;41 #50ffffff #a0000000 none +MENU COLOR unsel 37;41 #50ffffff #a0000000 none MENU COLOR help 37;40 #c0ffffff #a0000000 none -MENU COLOR tabmsg 30;44 #a0000000 #a0000000 none -menu color cmdmark 1;36;44 #9033ccff #a0000000 none +MENU COLOR tabmsg 30;41 #a0000000 #a0000000 none +menu color cmdmark 1;35;41 #90ff6666 #a0000000 none menu color cmdline 37;40 #c0ffffff #a0000000 none MENU COLOR timeout_msg 37;40 #80ffffff #a0000000 none MENU COLOR timeout 1;37;40 #c0ffffff #a0000000 none diff --git a/.linux_items/include/syslinux/wk_sys.cfg b/.linux_items/include/syslinux/wk_sys.cfg index 0d375cf3..e8d1393c 100644 --- a/.linux_items/include/syslinux/wk_sys.cfg +++ b/.linux_items/include/syslinux/wk_sys.cfg @@ -2,6 +2,8 @@ INCLUDE boot/syslinux/wk_head.cfg INCLUDE boot/syslinux/wk_sys_linux.cfg #UFD#INCLUDE boot/syslinux/wk_sys_winpe.cfg -INCLUDE boot/syslinux/wk_sys_extras_entry.cfg +#UFD#INCLUDE boot/syslinux/1201_hdclone.cfg +#UFD#INCLUDE boot/syslinux/1201_eset.cfg +INCLUDE boot/syslinux/wk_hdt.cfg INCLUDE boot/syslinux/wk_tail.cfg diff --git a/.linux_items/include/syslinux/wk_sys_extras.cfg b/.linux_items/include/syslinux/wk_sys_extras.cfg index 3e5af215..9d77c1d8 100644 --- a/.linux_items/include/syslinux/wk_sys_extras.cfg +++ b/.linux_items/include/syslinux/wk_sys_extras.cfg @@ -3,6 +3,8 @@ INCLUDE boot/syslinux/wk_head.cfg INCLUDE boot/syslinux/wk_sys_linux.cfg INCLUDE boot/syslinux/wk_sys_linux_extras.cfg #UFD#INCLUDE boot/syslinux/wk_sys_winpe.cfg +#UFD#INCLUDE boot/syslinux/1201_hdclone.cfg +#UFD#INCLUDE boot/syslinux/1201_eset.cfg INCLUDE boot/syslinux/wk_hdt.cfg INCLUDE boot/syslinux/wk_tail.cfg