Windows (desktop and server)
TMA-WIN2022-18.10.16.4
Ensure 'Enable OneSettings Auditing' is set to 'Enabled'
MittelStufe 2Automatisiertwindows
Beschreibung
This policy setting controls whether Windows records attempts to connect with the OneSettings service to the Event Log. The recommended state for this setting is: Enabled.
So wird geprüft
Prüfmethode: Windows-Registrierung
registry
$bad = @(); $v = (Get-ItemProperty -Path 'Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\DataCollection' -Name 'EnableOneSettingsAuditing' -ErrorAction SilentlyContinue).'EnableOneSettingsAuditing'; if (-not ($null -ne $v -and @(1) -contains [int64]$v)) { $bad += 'EnableOneSettingsAuditing=' + $v }; if ($bad.Count -eq 0) { 'compliant' } else { 'non-compliant: ' + ($bad -join ', ') }- Erwartete Ausgabe
compliant
So wird behoben
Behebungsmethode: Shell-Befehl
shell
if (-not (Test-Path 'Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\DataCollection')) { New-Item -Path 'Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\DataCollection' -Force | Out-Null }; New-ItemProperty -Path 'Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\DataCollection' -Name 'EnableOneSettingsAuditing' -Value 1 -PropertyType DWord -Force | Out-NullEigenschaften
- Betriebssysteme
- windows-server-2022-dc, windows-server-2022-ms
- Tags
- cis-convertedregistrywindows
- Referenz
- CIS Microsoft Windows Server 2022 Benchmark v5.1.0 - 18.10.16.4
Diesen Host prüfen
Führen Sie dies auf einem Rechner aus, den Sie prüfen dürfen. Der Scan ist schreibgeschützt.
shell
tmaegis scan --target windows --level 2