Prevent user from disabling the screen lock
An XCCDF Rule
Description
The tmux
terminal multiplexer is used to implement
automatic session locking. It should not be listed in
/etc/shells
.
Rationale
Not listing tmux
among permitted shells
prevents malicious program running as user
from lowering security by disabling the screen lock.
- ID
- xccdf_org.ssgproject.content_rule_no_tmux_in_shells
- Severity
- Low
- References
- Updated
Remediation - Ansible
- name: Gather the package facts
package_facts:
manager: auto
tags:
- NIST-800-53-CM-6
- low_complexity
Remediation - Shell Script
# Remediation is applicable only in certain platforms
if rpm --quiet -q kernel; then
if grep -q 'tmux\s*$' /etc/shells ; then
sed -i '/tmux\s*$/d' /etc/shells
fi