Univention Bugzilla – Bug 40366
sudo: multiple issues (3.2)
Last modified: 2016-03-08 18:00:49 CET
+++ This bug was initially created as a clone of Bug #40365 +++ CVE-2015-5602: sudoedit in Sudo before 1.8.15 allows local users to gain privileges via a symlink attack on a file whose full path is defined using multiple wildcards in /etc/sudoers, as demonstrated by "/home/*/*/file.txt."
Upstream Debian package version 1.7.4p4-2.squeeze.6 fixes the issue above
The upstream package version has been imported and built in errata3.2-8. Advisory: sudo.yaml
OK: advisory OK: manual test of exploit: root@ucs32:~# dpkg -l sudo ii sudo 1.7.4p4-2.squeeze.5.38.2015 root@ucs32:~# echo 'test1 ALL=(root) NOPASSWD: sudoedit /home/*/*/test.txt' >> /etc/sudoers root@ucs32:~# su - test1 test1@ucs32:~$ mkdir testdir test1@ucs32:~$ ln -s /etc/shadow testdir/test.txt test1@ucs32:~$ sudoedit /home/test1/testdir/test.txt sudoedit: /home/test1/testdir/test.txt unchanged root@ucs32:~# apt-get update root@ucs32:~# DEBIAN_FRONTEND=noninteractive apt-get install sudo root@ucs32:~# dpkg -l sudo ii sudo 1.7.4p4-2.squeeze.6.43.2016 root@ucs32:~# su - test1 test1@ucs32:~$ sudoedit /home/test1/testdir/test.txt sudoedit: /home/test1/testdir/test.txt: editing files in a writable directory is not permitted
<http://errata.software-univention.de/ucs/3.2/409.html>