Forrest logo
back to the --list tool

sudo:tldr:76d02

sudo: List the allowed (and forbidden) commands for the invoking user.
$ sudo --list
try on your machine

The command "sudo --list" is used to display the privileges or permissions granted to the current user by the "sudo" command.

"sudo" stands for "SuperUser Do", and it allows a user with administrative privileges to execute commands or programs as the root user or another user with higher privileges.

The "--list" option is used to list or display the privileges granted to the current user by means of the "sudoers" file. This file contains a list of user permissions that determine which users can execute commands with "sudo" and what commands they are allowed to run.

When you run "sudo --list", it prompts you to enter your password. After successfully authenticating, it displays a list of the user's elevated privileges, showcasing the commands or programs they are allowed to run with "sudo".

This command is particularly useful for users who want to check what actions they can perform with elevated privileges or to verify if their "sudo" permissions have been properly configured.

This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the --list tool