{"description": "systemd's <tt>debug-shell</tt> service is intended to\ndiagnose systemd related boot issues with various <tt>systemctl</tt>\ncommands. Once enabled and following a system reboot, the root shell\nwill be available on <tt>tty9</tt> which is access by pressing\n<tt>CTRL-ALT-F9</tt>. The <tt>debug-shell</tt> service should only be used\nfor systemd related issues and should otherwise be disabled.\n<br /><br />\nBy default, the <tt>debug-shell</tt> systemd service is already disabled.\n\nEnsure the debug-shell is not enabled by the <tt>systemd.debug-shel=1</tt>\nboot parameter option.\n\nCheck that the line <pre>GRUB_CMDLINE_LINUX=\"...\"</pre> within <tt>/etc/default/grub</tt>\ndoesn't contain the argument <tt>systemd.debug-shell</tt>.\nRun the following command to update command line for already installed kernels:\n<pre># grubby --update-kernel=ALL --remove-args=\"systemd.debug-shell\"</pre>", "rationale": "This prevents attackers with physical access from trivially bypassing security\non the machine through valid troubleshooting configurations and gaining root\naccess when the system is rebooted.", "severity": "medium", "references": {"ospp": ["FIA_UAU.1"]}, "control_references": {}, "components": [], "identifiers": {}, "ocil_clause": "the command returns a line", "ocil": "Ensure that debug-shell service is not enabled with the following command:\n<pre>grep systemd\\.debug-shell=1 /boot/grub2/grubenv /etc/default/grub</pre>\nIf the command returns a line, it means that debug-shell service is being enabled.", "oval_external_content": null, "fixtext": "Update the GRUB_CMDLINE_LINUX line in '/etc/default/grub' so that it does not contain any occurrence of debug-shell using the following command:\n\n$ sudo sed -i 's/\\(^GRUB_CMDLINE_LINUX=\".*\\)debug-shell=?[^[:space:]]*\\(.*\"\\)/\\1 \\2/' '/etc/default/grub'Run the following command:\n\n$ sudo update-grub ", "checktext": "", "vuldiscussion": "", "srg_requirement": "", "warnings": [], "conflicts": [], "requires": [], "policy_specific_content": {}, "platform": null, "platforms": [], "sce_metadata": {}, "inherited_platforms": ["grub2 and system_with_kernel"], "cpe_platform_names": [], "inherited_cpe_platform_names": ["grub2_and_system_with_kernel"], "bash_conditional": null, "fixes": {}, "title": "Ensure debug-shell service is not enabled during boot", "definition_location": "/aptdata/openscap/scap-security-guide/linux_os/guide/system/bootloader-grub2/grub2_systemd_debug-shell_argument_absent/rule.yml", "template": {"name": "grub2_bootloader_argument_absent", "vars": {"arg_name": "systemd.debug-shell"}, "backends": {}}}