vendor:
sudo
by:
Daniel Svartman
7.2
CVSS
HIGH
Unauthorized privilege escalation
264
CWE
Product Name: sudo
Affected Version From: Sudo <=1.8.14
Affected Version To: Sudo <=1.8.14
Patch Exists: YES
Related CWE: CVE-2015-5602
CPE: a:sudo:sudo
Metasploit:
https://www.rapid7.com/db/vulnerabilities/freebsd-vid-2e8cdd36-c3cc-11e5-b5fe-002590263bf5/, https://www.rapid7.com/db/vulnerabilities/alpine-linux-cve-2015-5602/, https://www.rapid7.com/db/vulnerabilities/gentoo-linux-cve-2015-5602/, https://www.rapid7.com/db/vulnerabilities/oracle-solaris-cve-2015-5602/, https://www.rapid7.com/db/vulnerabilities/debian-cve-2015-5602/
Other Scripts:
N/A
Tags: N/A
CVSS Metrics: N/A
Nuclei References:
N/A
Nuclei Metadata: N/A
Platforms Tested: RHEL 5/6/7 and Ubuntu (all versions)
2015
sudo -e – a.k.a. sudoedit – unauthorized privilege escalation
I found a security bug in sudo (checked in the latest versions of sudo running on RHEL and ubuntu) when a user is granted with root access to modify a particular file that could be located in a subset of directories. It seems that sudoedit does not check the full path if a wildcard is used twice (e.g. /home/*/*/file.txt), allowing a malicious user to replace the file.txt real file with a symbolic link to a different location (e.g. /etc/shadow). I was able to perform such redirect and retrieve the data from the /etc/shadow file.
Mitigation:
Ensure that the sudoers file is configured correctly and that users are not granted access to files or directories that they should not have access to.