Merge pull request #256159 from YtvwlD/yama
nixos/sysctl: Stop disabling yama by default
This commit is contained in:
@@ -69,9 +69,6 @@ in
|
||||
# users as these make it easier to exploit kernel vulnerabilities.
|
||||
boot.kernel.sysctl."kernel.kptr_restrict" = mkDefault 1;
|
||||
|
||||
# Disable YAMA by default to allow easy debugging.
|
||||
boot.kernel.sysctl."kernel.yama.ptrace_scope" = mkDefault 0;
|
||||
|
||||
# Improve compatibility with applications that allocate
|
||||
# a lot of memory, like modern games
|
||||
boot.kernel.sysctl."vm.max_map_count" = mkDefault 1048576;
|
||||
|
||||
@@ -79,10 +79,6 @@ with lib;
|
||||
"ufs"
|
||||
];
|
||||
|
||||
# Restrict ptrace() usage to processes with a pre-defined relationship
|
||||
# (e.g., parent/child)
|
||||
boot.kernel.sysctl."kernel.yama.ptrace_scope" = mkOverride 500 1;
|
||||
|
||||
# Hide kptrs even for processes with CAP_SYSLOG
|
||||
boot.kernel.sysctl."kernel.kptr_restrict" = mkOverride 500 2;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user