From 14f313f94dcc4644c2dc1a21006ee0a591404b68 Mon Sep 17 00:00:00 2001 From: Xyueta Date: Sun, 10 Mar 2024 01:07:33 +0100 Subject: [PATCH] New folder structure --- src/Configuration/custom.yml | 16 +-- src/Configuration/features/languages/lang.yml | 97 -------------- src/Configuration/langs.txt | 4 - .../{features/base => tasks}/appx.yml | 118 ++++++++---------- .../{features/base => tasks}/components.yml | 12 +- .../{features/base => tasks}/config.yml | 4 +- .../{features/base => tasks}/dotnet.yml | 4 +- .../{features/base => tasks}/files.yml | 3 +- .../{features/base => tasks}/regedits.yml | 2 +- .../{features/base => tasks}/services.yml | 2 + .../{features/base => tasks}/software.yml | 0 src/playbook.conf | 2 +- 12 files changed, 77 insertions(+), 187 deletions(-) delete mode 100644 src/Configuration/features/languages/lang.yml delete mode 100644 src/Configuration/langs.txt rename src/Configuration/{features/base => tasks}/appx.yml (90%) rename src/Configuration/{features/base => tasks}/components.yml (99%) rename src/Configuration/{features/base => tasks}/config.yml (94%) rename src/Configuration/{features/base => tasks}/dotnet.yml (91%) rename src/Configuration/{features/base => tasks}/files.yml (99%) rename src/Configuration/{features/base => tasks}/regedits.yml (99%) rename src/Configuration/{features/base => tasks}/services.yml (97%) rename src/Configuration/{features/base => tasks}/software.yml (100%) diff --git a/src/Configuration/custom.yml b/src/Configuration/custom.yml index a2c73f4..1e770da 100644 --- a/src/Configuration/custom.yml +++ b/src/Configuration/custom.yml @@ -3,11 +3,11 @@ title: Custom description: Custom AME configuration privilege: Admin actions: [] -features: -- features\base\regedits.yml -- features\base\appx.yml -- features\base\services.yml -- features\base\components.yml -- features\base\files.yml -- features\base\config.yml -- features\base\software.yml \ No newline at end of file +tasks: +- tasks\base\regedits.yml +- tasks\base\appx.yml +- tasks\base\services.yml +- tasks\base\components.yml +- tasks\base\files.yml +- tasks\base\config.yml +- tasks\base\software.yml \ No newline at end of file diff --git a/src/Configuration/features/languages/lang.yml b/src/Configuration/features/languages/lang.yml deleted file mode 100644 index 6b01768..0000000 --- a/src/Configuration/features/languages/lang.yml +++ /dev/null @@ -1,97 +0,0 @@ -!UTask -title: Language installation -description: Installs the files for the languages selected in the GUI -minVersion: -maxVersion: -status: ToDo -actions: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/basic_de-de.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/speech_de-de.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/tts_de-de.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/ocr_de-de.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/hw_de-de.cab - standardError: - standardOutput: -- !powershell - command: $OldList = Get-WinUserLanguageList; $OldList.Add(de-DE); Set-WinUserLanguageList -LanguageList $OldList -Force -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/basic_en-us.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/speech_en-us.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/tts_en-us.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/ocr_en-us.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/hw_en-us.cab - standardError: - standardOutput: -- !powershell - command: $OldList = Get-WinUserLanguageList; $OldList.Add(en-US); Set-WinUserLanguageList -LanguageList $OldList -Force -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/basic_es-es.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/speech_es-es.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/tts_es-es.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/ocr_es-es.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/hw_es-es.cab - standardError: - standardOutput: -- !powershell - command: $OldList = Get-WinUserLanguageList; $OldList.Add(es-ES); Set-WinUserLanguageList -LanguageList $OldList -Force -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/basic_fi-fi.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/speech_fi-fi.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/tts_fi-fi.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/ocr_fi-fi.cab - standardError: - standardOutput: -- !cmd - command: Dism /online /Add-Package /PackagePath:%temp%/AME/Languages/hw_fi-fi.cab - standardError: - standardOutput: -- !powershell - command: $OldList = Get-WinUserLanguageList; $OldList.Add(fi-FI); Set-WinUserLanguageList -LanguageList $OldList -Force -priority: 1 -features: [] diff --git a/src/Configuration/langs.txt b/src/Configuration/langs.txt deleted file mode 100644 index 5f86d73..0000000 --- a/src/Configuration/langs.txt +++ /dev/null @@ -1,4 +0,0 @@ -de-DE -en-US -es-ES -fi-FI diff --git a/src/Configuration/features/base/appx.yml b/src/Configuration/tasks/appx.yml similarity index 90% rename from src/Configuration/features/base/appx.yml rename to src/Configuration/tasks/appx.yml index 9735003..00b698d 100644 --- a/src/Configuration/features/base/appx.yml +++ b/src/Configuration/tasks/appx.yml @@ -4,96 +4,82 @@ description: Removal of APPX packages privilege: TrustedInstaller actions: - !writeStatus: {status: 'Removing APPX packages'} - - !appx: {name: '*Microsoft.549981C3F5F10*', type: family} - !appx: {name: '*3DViewer*', type: family} + - !appx: {name: '*Apprep.Chx*', type: family} - !appx: {name: '*AssignedAccessLockApp*', type: family} - - !appx: {name: '*PinningConfirmationDialog*', type: family} - - !appx: {name: '*SecureAssessmentBrowser*', type: family} + - !appx: {name: '*Bing*', type: family} + - !appx: {name: '*CamoStudio*', type: family} + - !appx: {name: '*Client.WebExperience*', type: family} + - !appx: {name: '*Clipchamp*', type: family} + - !appx: {name: '*CloudExperienceHost*', type: family} + - !appx: {name: '*CommsPhone*', type: family} + - !appx: {name: '*ConnectivityStore*', type: family} + - !appx: {name: '*ContentDeliveryManager*', type: family} + - !appx: {name: '*Disney*', type: family} - !appx: {name: '*FeedbackHub*', type: family} - - !appx: {name: '*MixedReality*', type: family} + - !appx: {name: '*GamingApp*', type: family} + - !appx: {name: '*Getstarted*', type: family} + - !appx: {name: '*Microsoft.549981C3F5F10*', type: family} - !appx: {name: '*Microsoft.Calculator*', type: family} - - !appx: {name: '*Microsoft.WindowsAlarms*', type: family} - !appx: {name: '*Microsoft.GetHelp*', type: family} - - !appx: {name: '*Getstarted*', type: family} - - !appx: {name: '*disney*', type: family} + - !appx: {name: '*Microsoft.Messaging*', type: family} - !appx: {name: '*Microsoft.OneConnect*', type: family} - - !appx: {name: '*WindowsCamera*', type: family} - - !appx: {name: '*bing*', type: family} - - !appx: {name: '*Sticky*', type: family} + - !appx: {name: '*Microsoft.People*', type: family} + - !appx: {name: '*Microsoft.Todos*', type: family} + - !appx: {name: '*Microsoft.WindowsAlarms*', type: family} - !appx: {name: '*Microsoft.WindowsStore*', type: family} - - - !appx: {name: '*StorePurchaseApp*', type: family} - + - !appx: {name: '*MicrosoftEdge*', type: family} - !appx: {name: '*MicrosoftOfficeHub*', type: family} -# - !appx: {name: '*Paint*', type: family} - - !appx: {name: '*wallet*', type: family} + - !appx: {name: '*MicrosoftTeams*', type: family} + - !appx: {name: '*MixedReality*', type: family} + - !appx: {name: '*OneDrive*', type: family} - !appx: {name: '*OneNote*', type: family} - - !appx: {name: '*Microsoft.People*', type: family} - - !appx: {name: '*WindowsPhone*', type: family} - - !appx: {name: '*YourPhone*', type: family} - - !appx: {name: '*photos*', type: family} + - !appx: {name: '*OOBENetwork*', type: family} + - !appx: {name: '*OutlookForWindows*', type: family} + - !appx: {name: '*Parental*', type: family} + - !appx: {name: '*PeopleExperienceHost*', type: family} + - !appx: {name: '*Photos*', type: family} + - !appx: {name: '*PinningConfirmationDialog*', type: family} + - !appx: {name: '*PowerAutomate*', type: family} + - !appx: {name: '*QuickAssist*', type: family} + - !appx: {name: '*SecHealthUI*', type: family} + - !appx: {name: '*SecureAssessmentBrowser*', type: family} - !appx: {name: '*SkypeApp*', type: family} - - !appx: {name: '*solit*', type: family} - - !appx: {name: '*spotify*', type: family} - - !appx: {name: '*WindowsSoundRecorder*', type: family} - - !appx: {name: '*windowscommunicationsapps*', type: family} - - !appx: {name: '*zune*', type: family} -# - !appx: {name: '*WindowsCalculator*', type: family} - - !appx: {name: '*WindowsMaps*', type: family} + - !appx: {name: '*Solit*', type: family} + - !appx: {name: '*Spotify*', type: family} + - !appx: {name: '*Sticky*', type: family} + - !appx: {name: '*StorePurchaseApp*', type: family} - !appx: {name: '*Sway*', type: family} - - !appx: {name: '*CommsPhone*', type: family} - - !appx: {name: '*ConnectivityStore*', type: family} - - !appx: {name: '*Microsoft.Messaging*', type: family} - - !appx: {name: '*Microsoft.WindowsStore*', type: family} - - !appx: {name: '*XboxApp*', type: family} - - - !appx: {name: '*GamingApp*', type: family} - - - !appx: {name: '*XboxSpeechToTextOverlay*', type: family} - - !appx: {name: '*XboxGamingOverlay*', type: family} - + - !appx: {name: '*Wallet*', type: family} - !appx: {name: '*WebExperienceHost*', type: app} - - - !appx: {name: '*XboxGameOverlay*', type: family} - + - !appx: {name: '*Windows.DevHome*', type: family} + - !appx: {name: '*WindowsCamera*', type: family} + - !appx: {name: '*windowscommunicationsapps*', type: family} + - !appx: {name: '*WindowsMaps*', type: family} + - !appx: {name: '*WindowsPhone*', type: family} + - !appx: {name: '*WindowsSoundRecorder*', type: family} - !appx: {name: '*Xbox.TCUI*', type: family} + - !appx: {name: '*XboxApp*', type: family} - !appx: {name: '*XboxGameCallableUI*', type: family} + - !appx: {name: '*XboxGameOverlay*', type: family} + - !appx: {name: '*XboxGamingOverlay*', type: family} - !appx: {name: '*XboxIdenitity*', type: family} - - - !appx: {name: '*SecHealthUI*', type: family} - - - !appx: {name: '*Microsoft.Todos*', type: family} - - !appx: {name: '*PowerAutomate*', type: family} - - !appx: {name: '*MicrosoftEdge*', type: family} - - - !appx: {name: '*OneDrive*', type: family} -# - !appx: {name: '*DesktopAppInstaller*', type: family} - - !appx: {name: '*PeopleExperienceHost*', type: family} - - !appx: {name: '*Parental*', type: family} - - !appx: {name: '*CloudExperienceHost*', type: family} - - !appx: {name: '*ContentDeliveryManager*', type: family} - - !appx: {name: '*Client.WebExperience*', type: family} - - !appx: {name: '*Apprep.Chx*', type: family} - - !appx: {name: '*OOBENetwork*', type: family} - - - !appx: {name: '*MicrosoftTeams*', type: family} - - !appx: {name: '*Clipchamp*', type: family} - - !appx: {name: '*QuickAssist*', type: family} - - - !appx: {name: '*Windows.DevHome*', type: family} - - !appx: {name: '*OutlookForWindows*', type: family} - - !appx: {name: '*CamoStudio*', type: family} - - - !appx: {name: '*WindowsBackup*', type: app} + - !appx: {name: '*XboxSpeechToTextOverlay*', type: family} + - !appx: {name: '*YourPhone*', type: family} + - !appx: {name: '*Zune*', type: family} - !appx: {name: '*Global.IrisService*', type: app} - !appx: {name: '*Global.Accounts*', type: app} - !appx: {name: '*Global.ValueBanner*', type: app} - !appx: {name: '*Global.DesktopSpotlight*', type: app} + - !appx: {name: '*WindowsBackup*', type: app} - !appx: {name: '*Client.CBS*', operation: clearCache} - !appx: {name: '*StartMenuExperienceHost*', operation: clearCache} - !appx: {name: '*Windows.Search*', operation: clearCache} +# - !appx: {name: '*DesktopAppInstaller*', type: family} +# - !appx: {name: '*Paint*', type: family} +# - !appx: {name: '*WindowsCalculator*', type: family} # - !appx: {name: 'SystemSettingsExtensions.dll', type: Extension *Client.CBS*} # - !appx: {name: 'SearchUx.InternalWebAPi.dll', type: Extension *Client.CBS*} \ No newline at end of file diff --git a/src/Configuration/features/base/components.yml b/src/Configuration/tasks/components.yml similarity index 99% rename from src/Configuration/features/base/components.yml rename to src/Configuration/tasks/components.yml index a026092..70af610 100644 --- a/src/Configuration/features/base/components.yml +++ b/src/Configuration/tasks/components.yml @@ -1,5 +1,6 @@ +--- title: Components -description: Remove certain windows components +description: Removal of certain Windows components privilege: TrustedInstaller actions: - !taskKill: {name: "explorer"} @@ -15,6 +16,7 @@ actions: - !taskKill: {name: "SkypeBackgroundHost"} - !taskKill: {name: "MsMpEng"} - !taskKill: {name: "msiexec"} + - !file: {path: "%windir%\\System32\\smartscreen.exe"} - !file: {path: "%windir%\\System32\\smartscreenps.dll"} - !file: {path: "%windir%\\System32\\SecurityHealthSystray.exe"} @@ -31,8 +33,8 @@ actions: - !file: {path: "%windir%\\System32\\drivers\\WdNisDrv.sys"} - !file: {path: "%ProgramW6432%\\Windows Defender Advanced Threat Protection"} - !file: {path: "%SystemDrive%\\ProgramData\\Microsoft\\Windows Defender Advanced Threat Protection"} - - !file: - path: "%windir%\\System32\\drivers\\cldflt.sys" + - !file: {path: "%windir%\\System32\\drivers\\cldflt.sys"} + - !scheduledTask: path: "\\Microsoft\\Windows\\Windows Defender\\Windows Defender Cache Maintenance" operation: delete @@ -130,9 +132,6 @@ actions: - !registryKey: {path: 'HKCU\SOFTWARE\Microsoft\Active Setup\Installed Components\{9459C573-B17A-45AE-9F64-1857B5D58CEE}'} - !registryKey: {path: 'HKCU\SOFTWARE\Microsoft\Edge'} - # WebView - - !registryKey: {path: 'HKCU\SOFTWARE\Microsoft\EdgeWebView'} - - !run: {exeDir: true, exe: "EDGE.bat", weight: 20} - !file: @@ -149,6 +148,7 @@ actions: - !file: {path: "%ProgramFiles(x86)%\\Microsoft\\EdgeCore", weight: 10} # WebView + - !registryKey: {path: 'HKCU\SOFTWARE\Microsoft\EdgeWebView'} - !file: {path: "%ProgramFiles(x86)%\\Microsoft\\EdgeWebView", weight: 10} # ---------- OneDrive diff --git a/src/Configuration/features/base/config.yml b/src/Configuration/tasks/config.yml similarity index 94% rename from src/Configuration/features/base/config.yml rename to src/Configuration/tasks/config.yml index 07e7758..f36fafc 100644 --- a/src/Configuration/features/base/config.yml +++ b/src/Configuration/tasks/config.yml @@ -1,4 +1,6 @@ +--- title: Configuration +description: Main part of amelioration process privilege: TrustedInstaller actions: # Sync time and set to more reliable time servers @@ -26,7 +28,7 @@ actions: - !run: {exe: "explorer.exe", wait: false, runas: currentUser} - - !writeStatus: {status: 'Configuring permissions', option: "security-enhanced"} + - !writeStatus: {status: 'Configuring security permissions', option: "security-enhanced"} - !registryValue: {path: 'HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System', value: 'ConsentPromptBehaviorAdmin', type: REG_DWORD, data: '5', option: "security-enhanced"} - !registryValue: {path: 'HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System', value: 'ConsentPromptBehaviorUser', type: REG_DWORD, data: '3', option: "security-enhanced"} - !registryValue: {path: 'HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System', value: 'EnableInstallerDetection', type: REG_DWORD, data: '1', option: "security-enhanced"} diff --git a/src/Configuration/features/base/dotnet.yml b/src/Configuration/tasks/dotnet.yml similarity index 91% rename from src/Configuration/features/base/dotnet.yml rename to src/Configuration/tasks/dotnet.yml index ec22e7d..61dfe7c 100644 --- a/src/Configuration/features/base/dotnet.yml +++ b/src/Configuration/tasks/dotnet.yml @@ -1,14 +1,14 @@ --- title: Dotnet +description: Installs essential prerequsities privilege: TrustedInstaller actions: - !writeStatus: {status: 'Installing Chocolatey'} - # Install Chocolatey - !powerShell: command: 'Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString(''https://community.chocolatey.org/install.ps1''))' weight: 30 + - !writeStatus: {status: 'Installing .NET 3.5'} - # Install .NET Framework 3.5 - !cmd: command: '"%ProgramData%\chocolatey\bin\choco.exe" install -y --force --allow-empty-checksums dotnet3.5' weight: 250 diff --git a/src/Configuration/features/base/files.yml b/src/Configuration/tasks/files.yml similarity index 99% rename from src/Configuration/features/base/files.yml rename to src/Configuration/tasks/files.yml index 507041c..f67a528 100644 --- a/src/Configuration/features/base/files.yml +++ b/src/Configuration/tasks/files.yml @@ -1,5 +1,6 @@ +--- title: Files -description: Deletes files +description: Deletes certain Windows files privilege: TrustedInstaller actions: - !writeStatus: {status: 'Removing files'} diff --git a/src/Configuration/features/base/regedits.yml b/src/Configuration/tasks/regedits.yml similarity index 99% rename from src/Configuration/features/base/regedits.yml rename to src/Configuration/tasks/regedits.yml index 7dff41c..a92612b 100644 --- a/src/Configuration/features/base/regedits.yml +++ b/src/Configuration/tasks/regedits.yml @@ -1,6 +1,6 @@ --- title: Registry Edits -description: Base AME Registry Edits +description: Base AME registry edits privilege: TrustedInstaller actions: - !writeStatus: {status: 'Modifying registry'} diff --git a/src/Configuration/features/base/services.yml b/src/Configuration/tasks/services.yml similarity index 97% rename from src/Configuration/features/base/services.yml rename to src/Configuration/tasks/services.yml index 8277357..9a00d04 100644 --- a/src/Configuration/features/base/services.yml +++ b/src/Configuration/tasks/services.yml @@ -1,4 +1,6 @@ +--- title: Services +description: Modification of Windows services privilege: TrustedInstaller actions: - !writeStatus: {status: 'Configuring services'} diff --git a/src/Configuration/features/base/software.yml b/src/Configuration/tasks/software.yml similarity index 100% rename from src/Configuration/features/base/software.yml rename to src/Configuration/tasks/software.yml diff --git a/src/playbook.conf b/src/playbook.conf index 2cf8ee1..23a9d27 100644 --- a/src/playbook.conf +++ b/src/playbook.conf @@ -96,7 +96,7 @@ - +