🔐 Linux Security Challenge

Week 6 - File Permissions & User Management

30:00

Time Remaining

0
Score
0/5
Completed
0
Mistakes

📋 Scenario:

You're a system administrator for a small company. The previous admin left suddenly, and you've discovered several security issues. Fix them quickly!

Task 1: Fix Dangerous File Permissions (20 points)

You found a file with permissions that let ANYONE modify it:

-rw-rw-rw- 1 root finance 2048 Nov 20 10:30 payroll.xlsx

Question: What chmod command would make this file readable and writable ONLY by the owner?

Task 2: Secure a Script (20 points)

A backup script has wrong permissions:

-rwxrwxrwx 1 admin admin 1024 Nov 20 10:31 backup.sh

Question: What numeric permission should this script have so that:

  • Owner can read, write, and execute
  • Group can read and execute only
  • Others have no access

Task 3: Remove User from Group (20 points)

An employee "john" left the company but is still in the "sudo" group:

$ groups john john : john sudo developers

Question: Write the command to remove john from the sudo group.

Task 4: Identify the Problem (20 points)

Look at these file permissions:

-rw------- 1 root root 512 Nov 20 10:32 database_password.txt -rwxr-xr-x 1 root root 1024 Nov 20 10:33 system_check.sh -rw-rw-rw- 1 admin users 2048 Nov 20 10:34 employee_data.csv -rwx------ 1 admin admin 256 Nov 20 10:35 personal_script.sh

Question: Which file has the MOST dangerous permissions? (Just type the filename)

Task 5: Create and Configure (20 points)

Scenario: You need to create a new group called "developers" and add user "sarah" to it.

Write TWO commands (one per line):