TartarSauce
Executive summary — TartarSauce is a Medium Linux box where the real vector hides two levels below the web root: a nested WordPress at
/webservices/wprunning thegwolle-gbplugin, vulnerable to unauthenticated Remote File Inclusion (CVE-2015-8351) → shell aswww-data. Asudopermission overtarescalates toonuma(user flag) via a documented GTFOBins abuse. Root comes from manipulating a periodic root backup script (backuperer): replacing a file with a symlink toroot.txtduring the race window between packaging and validation forces itsdiffcomparison to fail and leak the flag's content into a readable error log.
| Platform | Hack The Box |
| Operating system | Linux |
| Difficulty | Medium |
| Status | Retired |
| Target IP | <TARGET_IP> |
Attack map
[1] Recon -- 80/tcp http (only vector)
|
[2] gobuster (two rounds) -- /webservices -> /webservices/wp (nested WordPress)
|
[3] gwolle-gb plugin -- unauthenticated Remote File Inclusion (RFI) via ajaxresponse.php?abspath=
+-> PHP reverse shell hosted on our own server, remotely included
+-> shell as www-data
|
[4] sudo -l -- (onuma) NOPASSWD: /bin/tar
GTFOBins: tar --checkpoint-action=exec -> arbitrary execution
+-> shell as onuma -> user.txt
|
[5] Periodic root process: /usr/sbin/backuperer -- backup at /var/tmp/.random,
sleep 30, decompresses, diff, error log if differences found
|
[6] Replace the backup's robots.txt with a symlink to /root/root.txt before
backuperer processes it -> repack -> diff fails -> the error log
leaks root.txt's content
1. Reconnaissance
As with any assessment, the first step is finding out which services the box exposes before deciding where to attack.
nmap -p- --min-rate 5000 <TARGET_IP>
80/tcp open http
-p-scans all 65535 ports (not just the default top 1000) and--min-rate 5000speeds things up by forcing a more aggressive packet rate — essential so a service on a non-standard port doesn't slip through. The result here is blunt: a single open port, 80. With no SSH exposed and nothing else listening, the entire initial compromise has to go through the web application.
Root Access unlocks the content you can't see — everything else on the site is already open.
See Root Access plansNo account? Create one free then upgrade from your console.