freedomofpress / securedrop-workstation

Qubes-based SecureDrop Journalist Workstation environment for submission handling
GNU Affero General Public License v3.0
137 stars 41 forks source link

sysctl configuration hardening #678

Open eloquence opened 3 years ago

eloquence commented 3 years ago

Identified as an medium finding in the December 2020 Workstation audit (TOB-SDW-025, medium severity), our kernel runtime parameters are not adequately configured.

Parameter Current Value Recommended Value Rationale
kernel.grsecurity.grsec_lock 0 1 make grsecurity sysctl values immutable at runtime
kernel.grsecurity.deny_new_usb 0 1 If the VM does not need USB, consider setting to 1
kernel.kptr_restrict 1 set to 2
fs.protected_fifos 0 set to 1 or 2
fs.protected_regular 0 set to 1 or 2
kernel.pid_max 32768 Increase limit to decrease the likelihood of PID-reuse scenario.

They also recommend disabling the bpf in Linux Kernel if not required by any running application.

[Based on internal issue originally filed by @emkll]

eloquence commented 3 years ago

The next workstation & server kernel releases may be a good opportunity to evaluate these changes.

rocodes commented 5 months ago

backlog pruning: