1️⃣ 1⃣ 1⃣ Exploiting Setuid Programs
Vulnerable setuid programs on Linux systems could lead to privilege escalation attacks.In this lab, you are provided a regular user account and need to escalate your privileges to become root. There are 2 programs in your home directory welcome and greetings which might be vulnerable.
Your mission:
Get as root shell on the system
View /etc/shadow
Retrieve the flag.
Note: Development tools e.g. gcc is installed on the system already.
Check for Setuid bit
ls -laCheck for strings in welcome binary
strings welcomeTry to overwrite greetings binary with /bin/bash
cp /bin/bash greetingsRemove greetings binary
Copy bash to current directory with name "greetings"
Execute the welcome binary
Retrieve the flag
Last updated
Was this helpful?