![]() See the timestamp_type and timestamp_timeout options in sudoers(5) for more information. By default, the sudoers policy caches credentials on a per-terminal basis for 5 minutes. Security policies may support credential caching to allow the user to run sudo again for a period of time without requiring authentication. This limit is policy-specific the default password prompt timeout for the sudoers security policy is 5 minutes. If authentication is required, sudo will exit if the user's password is not entered within a configurable time limit. The policy may require that users authenticate themselves with a password or another authentication mechanism. The security policy determines what privileges, if any, a user has to run sudo. See the Plugins section for more information. The default security policy is sudoers, which is configured via the file /etc/sudoers, or via LDAP. Third parties can develop and distribute their own plugins to work seamlessly with the sudo front-end. Sudo supports a plugin architecture for security policies, auditing, and input/output logging. ![]() The invoking user's real ( not effective) user-ID is used to determine the user name with which to query the security policy. Sudo allows a permitted user to execute a command as the superuser or another user, as specified by the security policy. List the allowed (and forbidden) commands for the invoking user: sudo -list bash_profile, etc.): sudo -login -user= user Launch the default shell as the specified user, loading the user's environment and reading login-specific files (. Launch the default shell with superuser privileges without changing the environment: sudo -shell ![]() Launch the default shell with superuser privileges and run login-specific files (. Repeat the last command prefixed with sudo (only in bash, zsh, etc.): sudo !! Run a command as another user and/or group: sudo -user= user -group= group id -a Run a command as the superuser: sudo less /var/log/syslogĮdit a file as the superuser with your default editor: sudo -edit /etc/fstab Execute a command as another user Examples (TL DR) ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |