Uac Detecteer App Installations

💼 Management Samenvatting

Deze security regelen waarborgt de correcte configuratie van beveiligingsinstellingen op Windows endpoints.

Aanbeveling
IMPLEMENT
Risico zonder
High
Risk Score
7/10
Implementatie
2u (tech: 1u)
Van toepassing op:
Windows

Deze instelling is onderdeel van de Windows security baseline en beschermt tegen bekende aanvalsvectoren door het afdwingen van veilige configuraties.

PowerShell Modules Vereist
Primary API: Graph
Connection: Connect-MgGraph
Required Modules: Microsoft.Graph.DeviceManagement

Implementatie

Dit regelen configureert uac detecteer app installations via Microsoft Intune apparaat configuratie beleid of compliance policies om Windows endpoints te beveiligen volgens security best practices.

Vereisten

Microsoft Intune via device configuratiebeleidsregels

Implementatie

Gebruik PowerShell-script uac-detecteer-app-installations.ps1 (functie Invoke-Monitoring) – Monitoren.

monitoring

Gebruik PowerShell-script uac-detect-app-installations.ps1 (functie Invoke-Monitoring) – Controleren.

Remediatie

Gebruik PowerShell-script uac-detect-app-installations.ps1 (functie Invoke-Remediation) – Herstellen.

Compliance en Auditing

Beleid documentatie

Compliance & Frameworks

Automation

Gebruik het onderstaande PowerShell script om deze security control te monitoren en te implementeren. Het script bevat functies voor zowel monitoring (-Monitoring) als remediation (-Remediation).

PowerShell
<# .SYNOPSIS UAC: Detect Application Installations .DESCRIPTION OMA-URI: ./Vendor/MSFT/Policy/Config/LocalPoliciesSecurityOptions/UserAccountControl_DetectApplicationInstallationsAndPromptForElevation .NOTES Filename: uac-detect-app-installations.ps1 Author: Nederlandse Baseline voor Veilige Cloud CIS: 2.3.17.2 #> #Requires -Version 5.1 #Requires -Modules Microsoft.Graph.DeviceManagement [CmdletBinding()] param([Parameter(Mandatory = $true, ParameterSetName = 'Monitoring')][switch]$Monitoring, [Parameter(Mandatory = $true, ParameterSetName = 'Remediation')][switch]$Remediation, [Parameter(Mandatory = $true, ParameterSetName = 'Revert')][switch]$Revert, [switch]$WhatIf) $ErrorActionPreference = 'Stop' function Invoke-Monitoring { Connect-MgGraph -Scopes 'DeviceManagementConfiguration.Read.All' -NoWelcome; $uri = "https://graph.microsoft.com/beta/deviceManagement/deviceConfigurations"; $configs = (Invoke-MgGraphRequest -Method GET -Uri $uri).value | Where-Object { $_.displayName -match 'UAC.*Detect.*App' }; return @{ isCompliant = ($configs.Count -gt 0) } } function Invoke-Remediation { Connect-MgGraph -Scopes 'DeviceManagementConfiguration.ReadWrite.All' -NoWelcome; $policyBody = @{ '@odata.type' = '#microsoft.graph.windows10CustomConfiguration'; displayName = "Baseline: UAC Detect App Installations"; omaSettings = @(@{ '@odata.type' = '#microsoft.graph.omaSettingInteger'; displayName = 'Detect App Installations'; omaUri = './Vendor/MSFT/Policy/Config/LocalPoliciesSecurityOptions/UserAccountControl_DetectApplicationInstallationsAndPromptForElevation'; value = 1 }) }; Invoke-MgGraphRequest -Method POST -Uri "https://graph.microsoft.com/beta/deviceManagement/deviceConfigurations" -Body ($policyBody | ConvertTo-Json -Depth 10) | Out-Null; Write-Host "[OK] Created" -ForegroundColor Green } function Invoke-Revert { Connect-MgGraph -Scopes 'DeviceManagementConfiguration.ReadWrite.All' -NoWelcome; $uri = "https://graph.microsoft.com/beta/deviceManagement/deviceConfigurations"; (Invoke-MgGraphRequest -Method GET -Uri $uri).value | Where-Object { $_.displayName -match 'Baseline.*UAC.*Detect' } | ForEach-Object { Invoke-MgGraphRequest -Method DELETE -Uri "$uri/$($_.id)" } } try { switch ($PSCmdlet.ParameterSetName) { 'Monitoring' { $r = Invoke-Monitoring; exit $(if ($r.isCompliant) { 0 } else { 1 }) } 'Remediation' { Invoke-Remediation } 'Revert' { Invoke-Revert } } } catch { Write-Error $_; exit 2 }

Risico zonder implementatie

Risico zonder implementatie
High: No auth tracking.

Management Samenvatting

Schakel in audit logging.