{"description": "The sudo <tt>timestamp_timeout</tt> tag sets the amount of time sudo password prompt waits.\nThe default <tt>timestamp_timeout</tt> value is 5 minutes.\nThe timestamp_timeout should be configured by making sure that the\n<tt>timestamp_timeout</tt> tag exists in\n<tt>/etc/sudoers</tt> configuration file or any sudo configuration snippets\nin <tt>/etc/sudoers.d/</tt>.\nIf the value is set to an integer less than 0, the user's time stamp will not expire\nand the user will not have to re-authenticate for privileged actions until the user's session is terminated.", "rationale": "Without re-authentication, users may access resources or perform tasks for which they\ndo not have authorization.\n<br /><br />\nWhen operating systems provide the capability to escalate a functional capability, it\nis critical that the user re-authenticate.", "severity": "medium", "references": {"nist": ["IA-11"], "srg": ["SRG-OS-000373-GPOS-00156", "SRG-OS-000373-GPOS-00157", "SRG-OS-000373-GPOS-00158"], "cis": ["5.2.6"], "pcidss4": ["2.2.6", "2.2"]}, "control_references": {"cis": ["5.2.6"], "pcidss4": ["2.2.6", "2.2"]}, "components": [], "identifiers": {}, "ocil_clause": "timestamp_timeout is not set with the appropriate value for sudo", "ocil": "Verify the operating system requires re-authentication\nwhen using the \"sudo\" command to elevate privileges, run the following command:\n<pre>sudo grep -ri '^Defaults.*timestamp_timeout' /etc/sudoers /etc/sudoers.d</pre>\nThe output should be:\n<pre>/etc/sudoers:Defaults timestamp_timeout=0</pre> or \"timestamp_timeout\" is set to a positive number.\nIf conflicting results are returned, this is a finding.", "oval_external_content": null, "fixtext": "Configure Ubuntu 22.04 to re-authenticate \"sudo\" commands after the specified timeout:\n\nAdd the following line to \"/etc/sudoers\":\n\nDefaults timestamp_timeout=<sub idref=\"var_sudo_timestamp_timeout\" />\n\nRemove any duplicate or conflicting lines from /etc/sudoers and /etc/sudoers.d/ files.", "checktext": "", "vuldiscussion": "", "srg_requirement": "Ubuntu 22.04 must require re-authentication when using the \"sudo\" command.", "warnings": [], "conflicts": [], "requires": [], "policy_specific_content": {"stig": {"srg_requirement": "Ubuntu 22.04 must require reauthentication when using the \"sudo\" command.", "vuldiscussion": "Without reauthentication, users may access resources or perform tasks for which they do not have authorization.\n\nWhen operating systems provide the capability to escalate a functional capability, it is critical the organization requires the user to reauthenticate when using the \"sudo\" command.\n\nIf the value is set to an integer less than \"0\", the user's time stamp will not expire and the user will not have to reauthenticate for privileged actions until the user's session is terminated.", "checktext": "Verify Ubuntu 22.04 requires reauthentication when using the \"sudo\" command to elevate privileges with the following command:\n\n$ sudo grep -ir 'timestamp_timeout' /etc/sudoers /etc/sudoers.d/\n\n/etc/sudoers:Defaults timestamp_timeout=0\n\nIf results are returned from more than one file location, this is a finding.\n\nIf \"timestamp_timeout\" is set to a negative number, is commented out, or no results are returned, this is a finding.", "fixtext": "Configure Ubuntu 22.04 to reauthenticate \"sudo\" commands after the specified timeout:\n\nAdd the following line to \"/etc/sudoers\" or a file in \"/etc/sudoers.d\":\n\nDefaults timestamp_timeout=0"}}, "platform": "package[sudo]", "platforms": ["package[sudo]"], "sce_metadata": {}, "inherited_platforms": ["system_with_kernel"], "cpe_platform_names": ["package_sudo"], "inherited_cpe_platform_names": ["system_with_kernel"], "bash_conditional": null, "fixes": {}, "title": "Require Re-Authentication When Using the sudo Command", "definition_location": "/aptdata/openscap/scap-security-guide/linux_os/guide/system/software/sudo/sudo_require_reauthentication/rule.yml", "template": null}