From 92199c2b47a09095972c6d81bb5f70a84b047211 Mon Sep 17 00:00:00 2001 From: Saqib <70284132+saqib-s@users.noreply.github.com> Date: Wed, 22 Nov 2023 12:25:03 -0500 Subject: [PATCH 1/2] Update procative-remediation-creation.ps1 added following switch to detection switch to bypass source agreements when detesting upgrades (initial run) --accept-source-agreements --- .../procative-remediation-creation.ps1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Proactive Remediation/winget app update - automated/procative-remediation-creation.ps1 b/Proactive Remediation/winget app update - automated/procative-remediation-creation.ps1 index a2f1238..63bffd8 100644 --- a/Proactive Remediation/winget app update - automated/procative-remediation-creation.ps1 +++ b/Proactive Remediation/winget app update - automated/procative-remediation-creation.ps1 @@ -79,7 +79,7 @@ $app_2upgrade = "WINGETPROGRAMID" $Winget = Get-ChildItem -Path (Join-Path -Path (Join-Path -Path $env:ProgramFiles -ChildPath "WindowsApps") -ChildPath "Microsoft.DesktopAppInstaller*_x64*\winget.exe") -if ($(&$winget upgrade) -like "* $app_2upgrade *") { +if ($(&$winget upgrade --accept-source-agreements) -like "* $app_2upgrade *") { Write-Host "Upgrade available for: $app_2upgrade" exit 1 # upgrade available, remediation needed } @@ -212,5 +212,5 @@ $AADGroupID = (Get-AzureADGroup -All $true | where-object DisplayName -eq $PAR_A Write-Host "Complete" -ForegroundColor Green }else{ - Write-Host "Group $PAR_AADGroup not found, PAR createt but not assigned" -ForegroundColor Yellow + Write-Host "Group $PAR_AADGroup not found, PAR create but not assigned" -ForegroundColor Yellow } From a3ba8660ab64e86bb1ab0028b00a3877046adebc Mon Sep 17 00:00:00 2001 From: Saqib <70284132+saqib-s@users.noreply.github.com> Date: Wed, 22 Nov 2023 12:28:43 -0500 Subject: [PATCH 2/2] Update procative-remediation-creation.ps1 --- .../procative-remediation-creation.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Proactive Remediation/winget app update - automated/procative-remediation-creation.ps1 b/Proactive Remediation/winget app update - automated/procative-remediation-creation.ps1 index 63bffd8..27dbce7 100644 --- a/Proactive Remediation/winget app update - automated/procative-remediation-creation.ps1 +++ b/Proactive Remediation/winget app update - automated/procative-remediation-creation.ps1 @@ -212,5 +212,5 @@ $AADGroupID = (Get-AzureADGroup -All $true | where-object DisplayName -eq $PAR_A Write-Host "Complete" -ForegroundColor Green }else{ - Write-Host "Group $PAR_AADGroup not found, PAR create but not assigned" -ForegroundColor Yellow + Write-Host "Group $PAR_AADGroup not found, PAR created but not assigned" -ForegroundColor Yellow }