Superuser Privileges (sudo)
Concept & Overview
Imagine working on your computer with a standard account to prevent accidentally deleting critical operating system files. When you need to install software or modify system settings, your computer asks for admin authorization. In Linux, we use sudo (short for "superuser do") as our administrative key card.
- The root user is the master administrator account with full control over the system.
- Standard users are blocked from reading sensitive files (like the password database /etc/shadow). By typing sudo before a command, you run it with temporary administrator powers to bypass these blocks.
cat /etc/shadow to see the permission error. Then bypass it by running the command with admin privileges: sudo cat /etc/shadow.Command Syntax Reference
| Command / Syntax | Description |
|---|---|
sudo cat /etc/shadow | Run a command with administrator/superuser privileges |
cat /etc/shadow | Read password hashes database (restricted) |
Verification Objectives
These conditions will be automatically verified when you run commands inside the interactive terminal simulator:
- ○Try "cat /etc/shadow" and observe permission error
- ○Run "sudo cat /etc/shadow" successfully
Ready to complete Quest 41?
Test your skills live in the browser terminal with an emulated Linux filesystem, real-time command evaluation, and instant step-by-step hints.