SV-257811r1198253_rule
V-257811
SRG-OS-000132-GPOS-00067
RHEL-09-213080
CAT II
10
Configure RHEL 9 to restrict the usage of ptrace to descendant processes.
Create the drop-in if it doesn't already exist:
$ sudo vi /etc/sysctl.d/99-kernel_yama.ptrace_scope.conf
Add the following line to the file:
kernel.yama.ptrace_scope = 1
Reload settings from all system configuration files with the following command:
$ sudo sysctl --system
Verify RHEL 9 restricts the usage of ptrace to descendant processes.
Check the status of the "kernel.yama.ptrace_scope" kernel parameter with the following command:
$ sysctl kernel.yama.ptrace_scope
kernel.yama.ptrace_scope = 1
If the network parameter "kernel.yama.ptrace_scope" is not equal to "1", or nothing is returned, this is a finding.
V-257811
False
RHEL-09-213080
Verify RHEL 9 restricts the usage of ptrace to descendant processes.
Check the status of the "kernel.yama.ptrace_scope" kernel parameter with the following command:
$ sysctl kernel.yama.ptrace_scope
kernel.yama.ptrace_scope = 1
If the network parameter "kernel.yama.ptrace_scope" is not equal to "1", or nothing is returned, this is a finding.
M
5551