TMAegisBeta
Más reglas para macos

macOS

TMA-MACOS15-2.2.2

Ensure Firewall Stealth Mode Is Enabled

AltaNivel 1Automatizadamacos

Descripción

While in Stealth mode, the computer will not respond to unsolicited probes, dropping that traffic. Audit: Passes when EnableStealthMode is true in a profile or socketfilterfw reports stealth mode on.

Cómo se verifica

Método de auditoría: Comando de shell

shell
[ -x /usr/bin/osascript ] || exit 1
p=$(/usr/bin/osascript -l JavaScript <<'EOS'
$.NSUserDefaults.alloc.initWithSuiteName('com.apple.security.firewall').objectForKey('EnableStealthMode').js
EOS
)
s=$(/usr/libexec/ApplicationFirewall/socketfilterfw --getstealthmode 2>/dev/null)
if [ "$p" = true ] || printf '%s' "$s" | /usr/bin/grep -q 'stealth mode is on'; then echo compliant; else echo "EnableStealthMode=${p:-unset}; $s"; fi
Salida esperada
compliant

Cómo se corrige

Método de corrección: Guía o parche de infraestructura

Profile (preferred): com.apple.security.firewall EnableStealthMode = <true/>. Terminal: sudo /usr/libexec/ApplicationFirewall/socketfilterfw --setstealthmode on. GUI: System Settings > Network > Firewall > Options > Set Enabled stealth mode to enabled.

Propiedades

Sistemas operativos
macos-15
Etiquetas
macossystem-settings
Referencia
CIS Apple macOS 15.0 Sequoia Benchmark v2.1.0 - 2.2.2 Ensure Firewall Stealth Mode Is Enabled

Verificar este host

Ejecute esto en un equipo que tenga permiso para auditar. El escaneo es de solo lectura.

shell
tmaegis scan --target macos